org.logicblaze.lingo.jms.impl
Class ResultJoinHandler

java.lang.Object
  extended by org.logicblaze.lingo.jms.impl.ResultJoinHandler
All Implemented Interfaces:
ReplyHandler

public class ResultJoinHandler
extends Object
implements ReplyHandler

A ReplyHandler which can handle join multiple results to the same request which are then aggregated together into a single value.

Version:
$Revision$

Constructor Summary
ResultJoinHandler(Marshaller marshaller, ResultJoinStrategy joinStrategy)
           
 
Method Summary
 int getResponseCount()
           
 long getTimeout()
           
 boolean handle(javax.jms.Message message)
          Processes the message, returning true if this is the last method of a lifecycle so that the handler can be discarded
 org.springframework.remoting.support.RemoteInvocationResult pollResult()
           
 void setTimeout(long timeout)
          Sets the Object.wait(long) method timeout period before resuming the wait.
 org.springframework.remoting.support.RemoteInvocationResult waitForResult()
          This method will block the calling thread until the result is available.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ResultJoinHandler

public ResultJoinHandler(Marshaller marshaller,
                         ResultJoinStrategy joinStrategy)
Method Detail

handle

public boolean handle(javax.jms.Message message)
               throws javax.jms.JMSException
Description copied from interface: ReplyHandler
Processes the message, returning true if this is the last method of a lifecycle so that the handler can be discarded

Specified by:
handle in interface ReplyHandler
Throws:
javax.jms.JMSException

waitForResult

public org.springframework.remoting.support.RemoteInvocationResult waitForResult()
This method will block the calling thread until the result is available.


pollResult

public org.springframework.remoting.support.RemoteInvocationResult pollResult()

getResponseCount

public int getResponseCount()

getTimeout

public long getTimeout()

setTimeout

public void setTimeout(long timeout)
Sets the Object.wait(long) method timeout period before resuming the wait.



Copyright © 2012 LogicBlaze, Inc.. All Rights Reserved.