ITransactedSession.CreateFlow Method (FlowProperties, IEndpoint, ISubscription, EventHandler(MessageEventArgs), EventHandler(FlowEventArgs), EndpointProperties)

Solclient

ITransactedSessionCreateFlow Method (FlowProperties, IEndpoint, ISubscription, EventHandlerMessageEventArgs, EventHandlerFlowEventArgs, EndpointProperties)
version: 7.2.1.27
Creates a consumer flow IFlow on the given transacted session. If messageEventHandler delegate is provided, messages received on the flow are dispatched to the message callback delegate in the context of the message dispatcher thread (CreateMessageDispatcher), otherwise messages received on this consumer flow are queued internally; in this case client applications must call ReceiveMsg(Int32) directly to retrieve any internally queued messages. Unlike other (or non-transacted) flows, events and messages received on a transacted flow are delivered in the contexts of two different threads. Events received on flows are still delivered in the context of the IContext thread (IContext). Messages received on flows are dispatched to the messageEventHandler delegate in the context of the message dispatcher thread or retrieved by calling ReceiveMsg(Int32) directly in the context of an application thread. The following flow properties are not supported: AckModeAutoAck

Namespace: SolaceSystems.Solclient.Messaging
Assembly: SolaceSystems.Solclient.Messaging (in SolaceSystems.Solclient.Messaging.dll) Version: 7.2.1.27 (7.2.1.27)
Syntax
IFlow CreateFlow(
	FlowProperties flowProperties,
	IEndpoint endpoint,
	ISubscription subscription,
	EventHandler<MessageEventArgs> messageEventHandler,
	EventHandler<FlowEventArgs> flowEventHandler,
	EndpointProperties endpointProperties
)
Function CreateFlow ( 
	flowProperties As FlowProperties,
	endpoint As IEndpoint,
	subscription As ISubscription,
	messageEventHandler As EventHandler(Of MessageEventArgs),
	flowEventHandler As EventHandler(Of FlowEventArgs),
	endpointProperties As EndpointProperties
) As IFlow
IFlow^ CreateFlow(
	FlowProperties^ flowProperties, 
	IEndpoint^ endpoint, 
	ISubscription^ subscription, 
	EventHandler<MessageEventArgs^>^ messageEventHandler, 
	EventHandler<FlowEventArgs^>^ flowEventHandler, 
	EndpointProperties^ endpointProperties
)

Parameters

flowProperties
Type: SolaceSystems.Solclient.MessagingFlowProperties
The flow properties FlowProperties
endpoint
Type: SolaceSystems.Solclient.MessagingIEndpoint
The IEndpoint instance to bind the new IFlow to
subscription
Type: SolaceSystems.Solclient.MessagingISubscription
Only valid if the endpoint is of type ISubscriberEndpoint
messageEventHandler
Type: SystemEventHandlerMessageEventArgs
The message EventHandler delegate for receiving messages. May be set to null to receive messages synchronously
flowEventHandler
Type: SystemEventHandlerFlowEventArgs
The flow event EventHandler delegate
endpointProperties
Type: SolaceSystems.Solclient.MessagingEndpointProperties
Is endpoint is a non-durable endpoint, endpointProperties will allo the user to sepcify EndpointProperties of the implicitly created endpoint

Return Value

Type: IFlow
A newly created IFlow instance for the transacted session if successful.
Exceptions
ExceptionCondition
OperationErrorException Thrown when the operation fails. Possible sub-codes:
ObjectDisposedException Thrown when the session is already disposed (terminal state).
ArgumentNullException Thrown if any of the required parameters is null.
FatalErrorException Thrown when an unrecoverable error occurs.
ArgumentException Thrown if arguments fail validation.
See Also