Creates a connection consumer for this connection (optional operation).
This is an expert facility not used by regular JMS clients.
Namespace:
Kaazing.JMSAssembly: Kaazing.JMS (in Kaazing.JMS.dll)
Syntax
| Visual Basic |
|---|
Function CreateConnectionConsumer ( _ topic As ITopic, _ messageSelector As String, _ sessionPool As IServerSessionPool, _ maxMessages As Integer _ ) As IConnectionConsumer |
| C# |
|---|
IConnectionConsumer CreateConnectionConsumer( ITopic topic, string messageSelector, IServerSessionPool sessionPool, int maxMessages ) |
| Visual C++ |
|---|
IConnectionConsumer^ CreateConnectionConsumer( ITopic^ topic, String^ messageSelector, IServerSessionPool^ sessionPool, int maxMessages ) |
Parameters
- topic
- Type: Kaazing.JMS..::..ITopic
the topic to access
- messageSelector
- Type: System..::..String
only messages with properties matching the message selector expression are delivered. A value of null or an empty string indicates that there is no message selector for the message consumer.
- sessionPool
- Type: Kaazing.JMS..::..IServerSessionPool
the server session pool to associate with this connection consumer
- maxMessages
- Type: System..::..Int32
the maximum number of messages that can be assigned to a server session at one time
Return Value
the connection consumer
Exceptions
| Exception | Condition |
|---|---|
| Kaazing.JMS..::..JMSException | if the TopicConnection object fails to create a connection consumer due to some internal error or invalid arguments for sessionPool and messageSelector. |
| Kaazing.JMS..::..InvalidDestinationException | if an invalid topic is specified. |
| Kaazing.JMS..::..InvalidSelectorException | if the message selector is invalid. |