Click or drag to resize
ProviderSession Constructor (SessionOptions, ProviderEventHandler, EventDispatcher)
Constructs a Session using the optionally specified 'options', the optionally specified 'eventHandler' and the optionally specified 'eventDispatcher'.

See the SessionOptions documentation for details on what can be specified in the 'options'.

If 'eventHandler' is not null then this Session will operation in asynchronous mode, otherwise the Session will operate in synchronous mode.

If 'eventDispatcher' is null then the Session will create a default EventDispatcher for this Session which will use a single thread for dispatching events. For more control over event dispatching a specific instance of EventDispatcher can be supplied. This can be used to share a single EventDispatcher amongst multiple Session objects.

If an 'eventDispatcher' is supplied which uses more than one thread the Session will ensure that events which should be ordered are passed to callbacks in a correct order. For example, partial response to a request or updates to a single subscription. If 'eventHandler' is null and the 'eventDispatcher' is not null an exception is thrown. Each EventDispatcher uses its own thread or pool of threads so if you want to ensure that a session which receives very large messages and takes a long time to process them does not delay a session that receives small messages and processes each one very quickly then give each one a separate EventDispatcher.

Namespace:  Bloomberglp.Blpapi
Assembly:  Bloomberglp.Blpapi (in Bloomberglp.Blpapi.dll) Version: 3.24.10.1
Syntax
public ProviderSession(
	SessionOptions options,
	ProviderEventHandler eventHandler,
	EventDispatcher dispatcher
)

Parameters

options
Type: Bloomberglp.BlpapiSessionOptions
eventHandler
Type: Bloomberglp.BlpapiProviderEventHandler
dispatcher
Type: Bloomberglp.BlpapiEventDispatcher
See Also