| de.danet.an.workflow.api.Channel
All known Subclasses: de.danet.an.workflow.ejbs.client.ChannelImpl,
Channel | public interface Channel extends WfObject(Code) | | This interface defines a named connection with a process that can
be used to receive messages from activities and send messages to
activities.
Note that messages sent from the workflow engine to clients on a
channel may be lost when no client has opened the channel.
author: Michael Lipp version: $Revision: 1.3 $ |
Method Summary | |
String | name() Return the channel name. | Process | process() Return the process this channel belongs to. | Map | receiveMessage() Wait for the next message from the process on this channel. | Map | receiveMessage(long timeout) Wait for the next message from the process on this channel within
the specified timeout interval. | void | sendMessage(Map msg) Send a message on this channel to the process. |
receiveMessage | Map receiveMessage() throws RemoteException(Code) | | Wait for the next message from the process on this channel. The
message consists of all IN or INOUT
parameters of the sender tool, stored in the
Map object by formal parameter name.
the message or null if the process hasbeen closed or removed throws: RemoteException - if a system-level error occurs |
receiveMessage | Map receiveMessage(long timeout) throws RemoteException(Code) | | Wait for the next message from the process on this channel within
the specified timeout interval. The
message consists of all IN or INOUT
parameters of the sender tool, stored in the
Map object by formal parameter name.
Parameters: timeout - the timeout value in milliseconds. A timeoutof zero never expires. the message or null if the process hasbeen closed or removed or the timeout expires throws: RemoteException - if a system-level error occurs |
sendMessage | void sendMessage(Map msg) throws InvalidKeyException, InvalidDataException, RemoteException(Code) | | Send a message on this channel to the process. The message will
be received by an active or subsequently activated receiver
tool listening on this channel. If two or more receiver tools
listen on the same channel concurrently, the message delivery
(only to one or to every receiver) is undefined.
The message sent is mapped to the formal OUT
parameters of the receiver tool by matching the parameter names
with the data entry names in the message.
Parameters: msg - the message throws: InvalidKeyException - if the process no longer exists throws: InvalidDataException - if the message contains invalid data, i.e.entries that do not match the name of a formal parameter throws: RemoteException - if a system-level error occurs |
|
|