org.objectweb.dream.queue.keyed
Class DoubleKeyedOutgoingHandlerBlockingImpl

java.lang.Object
  extended by org.objectweb.dream.AbstractComponent
      extended by org.objectweb.dream.queue.keyed.DoubleKeyedOutgoingHandlerBlockingImpl
All Implemented Interfaces:
ContextualBindingController, NeedAsyncStartController, PrepareStopLifeCycleController, Loggable, DoubleKeyedPull, BindingController, LifeCycleController

public class DoubleKeyedOutgoingHandlerBlockingImpl
extends AbstractComponent
implements DoubleKeyedPull

An outgoing handler that implements the DoubleKeyedPullinterface. It returnsmessages removed from a bufferbound to it. This component uses blocking calls for removing messages from the buffer.


Field Summary
protected static String[] CLIENT_INTERFACE_NAMES
          The names of client interfaces.
protected  DoubleKeyedBufferRemove doubleKeyedBufferRemoveItf
          The buffer from which pulled messages are removed.
 
Fields inherited from class org.objectweb.dream.AbstractComponent
bindingLogger, fcNeedAsyncStart, fcState, lifeCycleLogger, logger, weaveableC
 
Fields inherited from interface org.objectweb.dream.queue.keyed.DoubleKeyedPull
IN_DOUBLE_KEYED_PULL_ITF_NAME, OUT_DOUBLE_KEYED_PULL_ITF_NAME
 
Fields inherited from interface org.objectweb.fractal.api.control.LifeCycleController
STARTED, STOPPED
 
Constructor Summary
DoubleKeyedOutgoingHandlerBlockingImpl()
           
 
Method Summary
 void bindFc(String clientItfName, Object serverItf)
           
 String[] listFc()
           
 Message pull(Object key1, Object key2)
          Asks for a message matching the given keys.
 
Methods inherited from class org.objectweb.dream.AbstractComponent
beforeFirstStart, bindFc, getFcNeedAsyncStart, getFcState, initComponent, lookupFc, prepareStopFc, setLogger, startFc, stopFc, unbindFc
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

CLIENT_INTERFACE_NAMES

protected static final String[] CLIENT_INTERFACE_NAMES
The names of client interfaces.


doubleKeyedBufferRemoveItf

protected DoubleKeyedBufferRemove doubleKeyedBufferRemoveItf
The buffer from which pulled messages are removed.

Constructor Detail

DoubleKeyedOutgoingHandlerBlockingImpl

public DoubleKeyedOutgoingHandlerBlockingImpl()
Method Detail

pull

public Message pull(Object key1,
                    Object key2)
             throws PullException
Description copied from interface: DoubleKeyedPull
Asks for a message matching the given keys. If no message is available, the semantic of this method is left to the component implementing the interface. As an example, it can return null or block until a message is available.

Specified by:
pull in interface DoubleKeyedPull
Parameters:
key1 - the first key that is associated with the message to pull.
key2 - the second key that is associated with the message to pull.
Returns:
the pulled message, or null.
Throws:
PullException - if an exception occurs.
See Also:
DoubleKeyedPull.pull(Object, Object)

listFc

public String[] listFc()
Specified by:
listFc in interface BindingController
See Also:
BindingController.listFc()

bindFc

public void bindFc(String clientItfName,
                   Object serverItf)
            throws NoSuchInterfaceException,
                   IllegalBindingException,
                   IllegalLifeCycleException
Specified by:
bindFc in interface BindingController
Overrides:
bindFc in class AbstractComponent
Throws:
NoSuchInterfaceException
IllegalBindingException
IllegalLifeCycleException
See Also:
BindingController.bindFc(String, Object)


Copyright © 2003, 2005 - INRIA Rhone-Alpes - All Rights Reserved.