AMPS C# Client  5.3.3.4
AMPS C# Client for .NET
AMPS.Client.Client Class Reference
+ Inheritance diagram for AMPS.Client.Client:

Classes

class  Bookmarks
 
class  ConnectionStateChangedEventArgs
 
class  Version
 

Public Types

enum class  GlobalCommandTypeHandlers : int {
  Publish = 0 , SOW = 1 , GroupBegin = 2 , GroupEnd = 3 ,
  Heartbeat = 4 , OOF = 5 , Ack = 6 , LastChance = 7 ,
  DuplicateMessage = 8 , COUNT = 9
}
 Used to specify what type of command should be directed to a global handler when it is set. All messages of this type will be sent to the handler in addition to any handlers set for the specific command, subscription, or query id in the message. More...
 

Public Member Functions

delegate void ExceptionListener (Exception e)
 
 Client (String name)
 Creates a new AMPS client More...
 
 Client (String name, int version)
 Creates a new client More...
 
 Client (String name, Store store)
 Creates a client with a persistent store. More...
 
 Client (String name, Store store, int version)
 Creates a client with a persistent store. More...
 
 Client (String name, Transport transport)
 Creates a client with a transport. More...
 
 Client (String name, Transport transport, int version)
 Creates a client with a transport. More...
 
 Client (String name, Transport transport, Store store)
 Creates a client with a transport and persistent store. More...
 
 Client (String name, Transport transport, Store store, int version)
 Creates a client with a transport and persistent store. More...
 
String getName ()
 Return the name of the Client. More...
 
String getNameHash ()
 Return the name hash of the Client as returned by the server after logon. More...
 
int getServerVersion ()
 Return the server version retrieved during logon. If the client has not logged on or is connected to a server whose version is less than 3.8.0.0 this function will return 0. The version uses 2 digits each for major minor maintenance and hotfix i.e., 3.8.1.5 will return 3080105 Versions of AMPS prior to 3.8.0.0 did not return the server version to the client in the logon ack. More...
 
VersionInfo getServerVersionInfo ()
 Return the server version retrieved during logon. If the client has not logged on or is connected to a server whose version is less than 3.8.0.0 this function will return the latest release version. The version is returned as a VersionInfo. Versions of AMPS prior to 3.8.0.0 did not return the server version to the client in the logon ack. More...
 
Uri getURI ()
 Returns the URI the client is connected to. More...
 
Transport getTransport ()
 Return the underlying transport. For advanced users, this method provides direct access to the transport. Care needs to be taken to not modify the underlying transport in ways that are incompatible with the Client. More...
 
void setBookmarkStore (BookmarkStore val)
 
BookmarkStore getBookmarkStore ()
 
void setPublishStore (Store store)
 
Store getPublishStore ()
 
virtual void connect (string uri)
 Connects to the AMPS instance through the provided URI. The URI is a String with the format: More...
 
void setDisconnectHandler (ClientDisconnectHandler disconnectHandler)
 Sets the ClientDisconnectHandler . In the event that the Client is unintentionally disconnected from AMPS, the More...
 
void setDisconnectHandler (Action< Client > disconnectHandler)
 Sets the lambda function called in the event of client disconnect More...
 
ClientDisconnectHandler getDisconnectHandler ()
 Gets the currently configured ClientDisconnectHandler More...
 
void setLastChanceMessageHandler (MessageHandler messageHandler)
 Sets the MessageHandler instance used when no other handler matches. More...
 
void setLastChanceMessageHandler (Action< Message > messageHandler)
 Sets the MessageHandler instance used when no other handler matches. More...
 
void setUnhandledMessageHandler (MessageHandler messageHandler)
 Sets the MessageHandler instance used when no other handler matches. More...
 
void setUnhandledMessageHandler (Action< Message > messageHandler)
 Sets the lambda function used when no other handler matches. More...
 
void setExceptionListener (ExceptionListener exceptionListener)
 Sets the ExceptionListener instance used for communicating absorbed exceptions. More...
 
ExceptionListener getExceptionListener ()
 Gets the currently configured ExceptionListener More...
 
void setSubscriptionManager (SubscriptionManager subscriptionManager)
 Sets the SubscriptionManager instance used for recording active subscriptions. More...
 
SubscriptionManager getSubscriptionManager ()
 Gets the currently configured SubscriptionManager More...
 
void setGlobalCommandTypeMessageHandler (string command_, MessageHandler messageHandler_)
 Sets the MessageHandler that will be called in the event of a message of the given command type. More...
 
void setGlobalCommandTypeMessageHandler (Message.Commands command_, MessageHandler messageHandler_)
 Sets the MessageHandler that will be called in the event of a message of the given command type. More...
 
void setGlobalCommandTypeMessageHandler (GlobalCommandTypeHandlers command_, MessageHandler messageHandler_)
 Sets the MessageHandler that will be called in the event of a message of the given command type. More...
 
void setDuplicateMessageHandler (MessageHandler messageHandler)
 Sets the MessageHandler that will be called in the event of a duplicate message More...
 
MessageHandler getDuplicateMessageHandler ()
 Returns the MessageHandler that will be called in the event of a duplicate message More...
 
void setFailedWriteHandler (FailedWriteHandler handler_)
 Sets the FailedWriteHandler instance that will be called in the event that messages fail to be written More...
 
void setFailedWriteHandler (FailedWriteHandlerV4 handler_)
 Sets the FailedWriteHandlerV4 instance that will be called in the event that messages fail to be written More...
 
FailedWriteHandler getFailedWriteHandler ()
 Returns the the FailedWriteHandler instance that will be called in the event that messages fail to be written More...
 
virtual void disconnect ()
 Disconnect from the AMPS server. More...
 
void close ()
 Disconnect from the AMPS server. More...
 
Message allocateMessage ()
 Creates a new Message appropriate for this client. This function should be called rarely, since it does allocate a handful of small objects. Users sensitive to garbage collection delays should cache the message object for later usage. More...
 
virtual void setHeartbeat (int heartbeatInterval_, int readTimeout_)
 Sets a heartbeat on this connection. When a heartbeat is set, the client periodically sends a heartbeat message to AMPS. This helps the client more quickly detect disconnection from AMPS. More...
 
void setHeartbeat (int heartbeatInterval_)
 Sets a heartbeat on this connection. When a heartbeat is set, the client periodically sends a heartbeat message to AMPS. This helps the client more quickly detect disconnection from AMPS. More...
 
void send (Message m)
 Send a Message to AMPS via the Transport used in the Client. More...
 
void addMessageHandler (CommandId commandId_, MessageHandler messageHandler_, Message.AckTypes requestedAcks_, bool isSubscribe_)
 Adds a MessageHandler for a given CommandId to self. More...
 
bool removeMessageHandler (CommandId commandId_)
 
void setRetryOnDisconnect (bool isRetryOnDisconnect)
 Set whether or not messages being sent to the server should retry if the client is disconnected. This is most useful if you are publishing data that has a very short lifetime and so is no longer relevant after the time it takes to reconnect. More...
 
bool getRetryOnDisconnect ()
 Return whether or not messages being sent to the server will retry if the client is disconnected. More...
 
void setDefaultMaxDepth (int defaultMaxDepth)
 Set the default max depth to be used on all MessageStream results. More...
 
int getDefaultMaxDepth ()
 Return the current default max depth value set on MessageStream results. More...
 
CommandId send (MessageHandler messageHandler, Message message, long timeout)
 Send a Message to AMPS and register the messageHandler for any messages resulting from command execution. More...
 
CommandId send (Action< Message > messageHandler, Message message, long timeout)
 Send a Message to AMPS and register the messageHandler for any messages resulting from command execution. More...
 
ulong publish (byte[] topic, int topicOffset, int topicLength, byte[] data, int dataOffset, int dataLength, int expiration)
 Publish a message to an AMPS topic. If the client has a publish store set, More...
 
ulong publish (byte[] topic, int topicOffset, int topicLength, byte[] data, int dataOffset, int dataLength)
 Publish a message to an AMPS topic. If the client has a publish store set, More...
 
ulong publish (String topic, String data)
 Publish a message to an AMPS topic. If the client has a publish store set, More...
 
ulong publish (String topic, String data, int expiration)
 Publish a message to an AMPS topic. If the client has a publish store set, More...
 
ulong deltaPublish (byte[] topic, int topicOffset, int topicLength, byte[] data, int dataOffset, int dataLength)
 Delta publish a message to an AMPS topic. If the client has a publish store set, More...
 
ulong deltaPublish (byte[] topic, int topicOffset, int topicLength, byte[] data, int dataOffset, int dataLength, int expiration)
 Delta publish a message to an AMPS topic. If the client has a publish store set, More...
 
ulong deltaPublish (String topic, String data)
 Delta publish a message to an AMPS topic. If the client has a publish store set, More...
 
ulong deltaPublish (String topic, String data, int expiration)
 Delta publish a message to an AMPS topic. If the client has a publish store set, More...
 
virtual CommandId logon (long timeout)
 Logs into AMPS with the parameters provided in the connect method and the logon correlation data if set. More...
 
virtual CommandId logon (string options)
 Logs into AMPS with the parameters provided in the connect method and the logon correlation data if set. More...
 
virtual CommandId logon (long timeout, Authenticator authenticator)
 Logs into AMPS with the parameters provided in the connect method and the logon correlation data if set. More...
 
virtual CommandId logon (long timeout, string options)
 Logs into AMPS with the parameters provided in the connect method and the logon correlation data if set. More...
 
virtual CommandId logon (long timeout, Authenticator authenticator, string options)
 Logs into AMPS with the parameters provided in the connect method and the logon correlation data if set. More...
 
virtual CommandId logon ()
 Logs into AMPS with the parameters provided in the connect method. More...
 
CommandId bookmarkSubscribe (MessageHandler messageHandler, String topic, String filter=null, CommandId subId=null, String bookmark=null, string options=null, long timeout=0)
 Places a bookmark subscription with AMPS. Starts replay at the most recent message reported by the BookmarkStore. More...
 
CommandId subscribe (MessageHandler messageHandler, String topic, String filter, long timeout)
 Places a subscription with AMPS. More...
 
CommandId subscribe (Action< Message > messageHandler, String topic, String filter, long timeout)
 Places a subscription with AMPS. More...
 
MessageStream subscribe (string topic, string filter=null, string options=null, long timeout=0, string subid=null)
 Places a subscription with AMPS. More...
 
CommandId subscribe (MessageHandler messageHandler, String topic, String filter=null, string options=null, long timeout=0, String subId=null)
 Places a subscription with AMPS. More...
 
CommandId subscribe (Action< Message > messageHandler, String topic, String filter=null, String options=null, long timeout=0, string subid=null)
 Places a subscription with AMPS. More...
 
CommandId subscribe (MessageHandler messageHandler, String topic, long timeout)
 Places a subscription with AMPS. More...
 
CommandId subscribe (Action< Message > messageHandler, String topic, long timeout)
 Places a subscription with AMPS. More...
 
CommandId deltaSubscribe (MessageHandler messageHandler, String topic, String filter=null, String options=null, long timeout=0, String subId=null)
 Places a delta subscription with AMPS. More...
 
CommandId deltaSubscribe (Action< Message > messageHandler, String topic, String filter=null, String options=null, long timeout=0, String subId=null)
 Places a delta subscription with AMPS. More...
 
void unsubscribe (CommandId subscriptionId)
 Remove a subscription from AMPS. More...
 
void unsubscribe ()
 Remove all of the client's subscriptions from AMPS. More...
 
MessageStream sow (String topic, String filter=null, String orderBy=null, String bookmark=null, String options=null, int batchSize=10, int topN=-1, long timeout=0)
 Executes a SOW query. More...
 
CommandId sow (MessageHandler messageHandler, String topic, String filter=null, String orderBy=null, String bookmark=null, String options=null, int batchSize=10, int topN=-1, long timeout=0)
 Executes a SOW query. More...
 
CommandId sow (Action< Message > messageHandler, String topic, String filter=null, String orderBy=null, String bookmark=null, String options=null, int batchSize=10, int topN=-1, long timeout=0)
 Executes a SOW query. More...
 
CommandId sow (MessageHandler messageHandler, String topic, String filter, int batchSize, long timeout)
 Executes a SOW query. More...
 
CommandId sow (MessageHandler messageHandler, String topic, int batchSize, long timeout)
 Executes a SOW query. More...
 
CommandId sow (Action< Message > messageHandler, String topic, int batchSize, long timeout)
 Executes a SOW query. More...
 
CommandId sow (MessageHandler messageHandler, String topic, long timeout)
 Executes a SOW query. More...
 
CommandId sow (Action< Message > messageHandler, String topic, long timeout)
 Executes a SOW query. More...
 
MessageStream sowAndSubscribe (String topic, String filter=null, String orderBy=null, String bookmark=null, String options=null, int batchSize=10, int topN=-1, long timeout=0)
 Executes a SOW query and places a subscription. More...
 
CommandId sowAndSubscribe (MessageHandler messageHandler, String topic, String filter=null, String orderBy=null, String bookmark=null, String options=null, int batchSize=10, int topN=-1, long timeout=0)
 Executes a SOW query and places a subscription. More...
 
CommandId sowAndSubscribe (Action< Message > messageHandler, String topic, String filter=null, String orderBy=null, String bookmark=null, String options=null, int batchSize=10, int topN=-1, long timeout=0)
 Executes a SOW query and places a subscription. More...
 
CommandId sowAndSubscribe (MessageHandler messageHandler, String topic, String filter, int batchSize, bool oofEnabled, long timeout)
 Executes a SOW query and places a subscription. More...
 
CommandId sowAndSubscribe (Action< Message > a, String topic, String filter, int batchSize, bool sendOOF, long timeout)
 Executes a SOW query and places a subscription. More...
 
CommandId sowAndSubscribe (MessageHandler messageHandler, String topic, int batchSize, long timeout)
 Executes a SOW query and places a subscription. More...
 
CommandId sowAndSubscribe (Action< Message > a, String topic, int batchSize, long timeout)
 Executes a SOW query and places a subscription. More...
 
CommandId sowAndSubscribe (MessageHandler messageHandler, String topic, long timeout)
 Executes a SOW query and places a subscription. More...
 
CommandId sowAndSubscribe (Action< Message > a, String topic, long timeout)
 Executes a SOW query and places a subscription. More...
 
CommandId sowAndDeltaSubscribe (MessageHandler messageHandler, String topic, String filter=null, String orderBy=null, String bookmark=null, String options=null, int batchSize=10, int topN=-1, long timeout=0)
 Executes a SOW query and places a delta subscription. More...
 
CommandId sowAndDeltaSubscribe (MessageHandler messageHandler, String topic, String filter, int batchSize, bool oofEnabled, bool sendEmpties, long timeout)
 Executes a SOW query and places a delta subscription. More...
 
CommandId sowAndDeltaSubscribe (Action< Message > messageHandler, String topic, String filter, int batchSize, bool oofEnabled, bool sendEmpties, long timeout)
 Executes a SOW query and places a delta subscription. More...
 
CommandId sowAndDeltaSubscribe (MessageHandler messageHandler, String topic, int batchSize, long timeout)
 Executes a SOW query and places a delta subscription. More...
 
CommandId sowAndDeltaSubscribe (Action< Message > messageHandler, String topic, int batchSize, long timeout)
 Executes a SOW query and places a delta subscription. More...
 
CommandId sowAndDeltaSubscribe (MessageHandler messageHandler, String topic, long timeout)
 Executes a SOW query and places a delta subscription. More...
 
CommandId sowAndDeltaSubscribe (Action< Message > messageHandler, String topic, long timeout)
 Executes a SOW query and places a delta subscription. More...
 
Message sowDelete (String topic, String filter, long timeout=0)
 Executes a SOW delete with filter. More...
 
CommandId sowDelete (MessageHandler messageHandler, String topic, String filter, long timeout=0)
 Executes a SOW delete with filter. More...
 
CommandId sowDelete (Action< Message > messageHandler, String topic, String filter, long timeout=0)
 Executes a SOW delete with filter. More...
 
void startTimer ()
 
CommandId stopTimer (MessageHandler messageHandler, long timeout)
 
void setLogonCorrelationData (String correlationData)
 Gets the uninterpreted logon correlation information currently set. More...
 
String getLogonCorrelationData ()
 Gets the uninterpreted logon correlation information currently set. More...
 
CommandId sowDeleteByKeys (MessageHandler messageHandler, String topic, String keys, long timeout=0)
 Executes a SOW delete by sow key. More...
 
CommandId sowDeleteByKeys (Action< Message > messageHandler, String topic, String keys, long timeout=0)
 Executes a SOW delete by sow key. More...
 
CommandId sowDeleteByData (MessageHandler messageHandler, String topic, String data, long timeout=0)
 Executes a SOW delete by data. AMPS uses key fields in the data to find and delete a message with the same keys. More...
 
CommandId sowDeleteByData (Action< Message > messageHandler, String topic, String data, long timeout=0)
 Executes a SOW delete by data. AMPS uses key fields in the data to find and delete a message with the same keys. More...
 
void publishFlush ()
 Ensures that AMPS messages are sent and have been processed by the AMPS server. The client issues a flush command and waits for an acknowledgement. This mehthod blocks until messages have been processed and is most useful when the application reaches a point at which it is acceptable to block to ensure that messages are delivered to the AMPS server. For example, an application might call publishFlush before exiting. One thing to note is that if AMPS is unavailable (HA Client), publishFlush needs to wait for a connection to come back up which may look like it's hanging.
 
void publishFlush (int timeout)
 Ensures that AMPS messages are sent and have been processed by the AMPS server. The client issues a flush command and waits for an acknowledgement or until the timeout expires. This mehthod blocks until messages have been processed and is most useful when the application reaches a point at which it is acceptable to block to ensure that messages are delivered to the AMPS server. For example, an application might call publishFlush before exiting. One thing to note is that if AMPS is unavailable (HA Client), publishFlush needs to wait for a connection to come back up which may look like it's hanging.

Parameters
timeoutNumber of milliseconds to wait for flush, where 0 indicates no timeout

 
void publishFlush (string ackType_)
 Ensures that AMPS messages are sent and have been processed by the AMPS server. The client issues a flush command and waits for an acknowledgement. This mehthod blocks until messages have been processed and is most useful when the application reaches a point at which it is acceptable to block to ensure that messages are delivered to the AMPS server. For example, an application might call publishFlush before exiting. One thing to note is that if AMPS is unavailable (HA Client), publishFlush needs to wait for a connection to come back up which may look like it's hanging.

Parameters
ackType_The acknowledgement type that the flush command should wait to receive, see Message.AckType. 'processed' matches the timeout only version of this function. persisted ensures all previous messages have been persisted.

 
void publishFlush (string ackType_, int timeout)
 Ensures that AMPS messages are sent and have been processed by the AMPS server. The client issues a flush command and waits for an acknowledgement or until the timeout expires. This mehthod blocks until messages have been processed and is most useful when the application reaches a point at which it is acceptable to block to ensure that messages are delivered to the AMPS server. For example, an application might call publishFlush before exiting. One thing to note is that if AMPS is unavailable (HA Client), publishFlush needs to wait for a connection to come back up which may look like it's hanging.

Parameters
ackType_The acknowledgement type that the flush command should wait to receive, see Message.AckType. 'processed' matches the timeout only version of this function. persisted ensures all previous messages have been persisted.
Parameters
timeoutNumber of milliseconds to wait for flush, where 0 indicates no timeout

 
long flush ()
 
long flush (long timeout)
 Clear the queued messages which may be waiting in the transport More...
 
void setThreadCreatedHandler (ThreadCreatedHandler handler_)
 Set a handler that is invoked immediately by any thread created by the transport. More...
 
void setThreadCreatedHandler (Action handler_)
 Set a handler that is invoked immediately by any thread created by the transport. More...
 
void setTransportFilter (TransportFilter filter_)
 Sets a TransportFilter that filters raw bytes bfeore send and after receive. More...
 
virtual ConnectionInfo getConnectionInfo ()
 Assembles a new ConnectionInfo with the state of this client and associated classes. More...
 
void ack (byte[] topic, int topicPos, int topicLen, byte[] bookmark, int bookmarkPos, int bookmarkLen, byte[] options=null, int optionsPos=0, int optionsLen=0)
 ACKs a message queue message. More...
 
void ack (Field topic, Field bookmark, Field options=null)
 ACKs a message queue message. More...
 
void ack (String topic, String bookmark, String options=null)
 ACKS a message queue message. More...
 
void setAutoAck (bool isAutoAckEnabled)
 Enables or disables auto-acking. When auto-acking is enabled any successful return from a message handler functiokn will result in an ACK (sow_delete) message sent to the server. Any thrown exception will result in a "cancel" ACK sent to the server. More...
 
bool getAutoAck ()
 Returns the current setting of auto-acking. More...
 
void setAckBatchSize (int batchSize)
 Sets the current ACK batch size.The ACK batch size controls how many successful ACKs (which are sow_delete messages) are batched together before sending to the server.When combined with the "max_backlog" and MaxPerSubscriptionBacklog server configuration parameter, greater network efficiency can be achieved when using message queues.Setting this parameter causes calls to "ack" and successful auto-acks to be batched; unsuccessful/cancel acks are sent immediately. More...
 
int getAckBatchSize ()
 Returns the current ACK batch size. See the documentation for setAckBatchSize(int). More...
 
void setAckTimeout (long ackTimeout)
 Sets the ack timeout – the maximum time to let a success ack be cached before sending. More...
 
long getAckTimeout ()
 Returns the queue ack timeout. More...
 
void flushAcks ()
 Sends any pending queue ACKs to the server. More...
 
CommandId executeAsync (Command command, MessageHandler handler=null)
 Execute the provided command and process responses on the client receive thread using the provided handler. More...
 
CommandId executeAsync (Command command, Action< Message > action)
 Execute the provided command on a background thread and provide messages received in response to the handler provided. More...
 
MessageStream execute (Command command)
 Execute the provided command and return messages received in response in a MessageStream. More...
 
void Dispose ()
 

Static Public Member Functions

static int getVersionAsInt (String version)
 Return the numeric value for the given version string with the pattern: Major.Minor.Maintenance.Hotfix The version uses 2 digits each for major minor maintenance and hotfix i.e., 3.8.1.5 will return 3080105 Version strings passed in can be shortened to not include all levels so 3.8 will return 3080000. More...
 
static String getVersion ()
 Return the build number for the client that is stored in the Manifest.mf of the jar file. More...
 

Static Public Attributes

const int MIN_MULTI_BOOKMARK_VERSION = 4000000
 
const int MIN_QUEUE_VERSION = 5000000
 

Protected Member Functions

void broadcastConnectionStateChangedEvent (ConnectionStateChangedEventArgs args)
 

Protected Attributes

ExceptionListener _exceptionListener = null
 
Object internalLock = new Object()
 
volatile int _lastFailedConnectionVersion = -1
 

Properties

bool AutoAck [get, set]
 The AutoAck property enables or disables auto-acking. When auto-acking is enabled any successful return from a message handler function will result in an ACK (sow_delete) message sent to the server. Any thrown exception will result in a "cancel" ACK sent to the server. More...
 
int AckBatchSize [get, set]
 The ACK batch size controls how many successful ACKs (which are sow_delete messages) are batched together before sending to the server.When combined with the "max_backlog" and MaxPerSubscriptionBacklog server configuration parameter, greater network efficiency can be achieved when using message queues.Setting this parameter causes calls to "ack" and successful auto-acks to be batched; unsuccessful/cancel acks are sent immediately. More...
 

Events

EventHandler< ConnectionStateChangedEventArgsConnectionStateChanged
 

Member Enumeration Documentation

◆ GlobalCommandTypeHandlers

Used to specify what type of command should be directed to a global handler when it is set. All messages of this type will be sent to the handler in addition to any handlers set for the specific command, subscription, or query id in the message.

Constructor & Destructor Documentation

◆ Client() [1/8]

AMPS.Client.Client.Client ( String  name)
inline

Creates a new AMPS client

Parameters
nameA name to identify this client. This name is used for duplicate message detection and should be unique. AMPS does not enforce specific restrictions on the character set used, however some protocols (for example, XML) may not allow specific characters. 60East recommends that the client name be meaningful, short, human readable, and avoid using control characters, newline characters, or square brackets.

◆ Client() [2/8]

AMPS.Client.Client.Client ( String  name,
int  version 
)
inline

Creates a new client

Parameters
nameA name to identify this client. This name is used for duplicate message detection and should be unique. AMPS does not enforce specific restrictions on the character set used, however some protocols (for example, XML) may not allow specific characters. 60East recommends that the client name be meaningful, short, human readable, and avoid using control characters, newline characters, or square brackets.
versionThe AMPS server version to connect to

◆ Client() [3/8]

AMPS.Client.Client.Client ( String  name,
Store  store 
)
inline

Creates a client with a persistent store.

Parameters
nameA name to identify this client. This name is used for duplicate message detection and should be unique. AMPS does not enforce specific restrictions on the character set used, however some protocols (for example, XML) may not allow specific characters. 60East recommends that the client name be meaningful, short, human readable, and avoid using control characters, newline characters, or square brackets.
storeStore to use for the client

◆ Client() [4/8]

AMPS.Client.Client.Client ( String  name,
Store  store,
int  version 
)
inline

Creates a client with a persistent store.

Parameters
nameA name to identify this client. This name is used for duplicate message detection and should be unique. AMPS does not enforce specific restrictions on the character set used, however some protocols (for example, XML) may not allow specific characters. 60East recommends that the client name be meaningful, short, human readable, and avoid using control characters, newline characters, or square brackets.
storeStore to use for the client
versionServer version connecting to

◆ Client() [5/8]

AMPS.Client.Client.Client ( String  name,
Transport  transport 
)
inline

Creates a client with a transport.

Parameters
nameA name to identify this client. This name is used for duplicate message detection and should be unique. AMPS does not enforce specific restrictions on the character set used, however some protocols (for example, XML) may not allow specific characters. 60East recommends that the client name be meaningful, short, human readable, and avoid using control characters, newline characters, or square brackets.
transportTransport to use with the client

◆ Client() [6/8]

AMPS.Client.Client.Client ( String  name,
Transport  transport,
int  version 
)
inline

Creates a client with a transport.

Parameters
nameA name to identify this client. This name is used for duplicate message detection and should be unique. AMPS does not enforce specific restrictions on the character set used, however some protocols (for example, XML) may not allow specific characters. 60East recommends that the client name be meaningful, short, human readable, and avoid using control characters, newline characters, or square brackets.
transportTransport to use with the client
versionServer version connecting to

◆ Client() [7/8]

AMPS.Client.Client.Client ( String  name,
Transport  transport,
Store  store 
)
inline

Creates a client with a transport and persistent store.

Parameters
nameA name to identify this client. This name is used for duplicate message detection and should be unique. AMPS does not enforce specific restrictions on the character set used, however some protocols (for example, XML) may not allow specific characters. 60East recommends that the client name be meaningful, short, human readable, and avoid using control characters, newline characters, or square brackets.
transportTransport to use with the client
storeStore to use for the client

◆ Client() [8/8]

AMPS.Client.Client.Client ( String  name,
Transport  transport,
Store  store,
int  version 
)
inline

Creates a client with a transport and persistent store.

Parameters
nameA name to identify this client. This name is used for duplicate message detection and should be unique. AMPS does not enforce specific restrictions on the character set used, however some protocols (for example, XML) may not allow specific characters. 60East recommends that the client name be meaningful, short, human readable, and avoid using control characters, newline characters, or square brackets.
transportTransport to use with the client
storeStore to use for the client
versionServer version connecting to

Member Function Documentation

◆ ack() [1/3]

void AMPS.Client.Client.ack ( byte[]  topic,
int  topicPos,
int  topicLen,
byte[]  bookmark,
int  bookmarkPos,
int  bookmarkLen,
byte[]  options = null,
int  optionsPos = 0,
int  optionsLen = 0 
)
inline

ACKs a message queue message.

Parameters
topicThe message topic
topicPosThe starting index of the topic name
topicLenThe length of the topic name
bookmarkThe message bookmark
bookmarkPosThe starting index of the message bookmark
bookmarkLenThe length of the messasge bookmark
optionsAn options string for the ack, such as 'cancel'
optionsPosThe starting index of the options
optionsLenThe length of the options

◆ ack() [2/3]

void AMPS.Client.Client.ack ( Field  topic,
Field  bookmark,
Field  options = null 
)
inline

ACKs a message queue message.

Parameters
topicThe topic of the message
bookmarkThe bookmark of the message
optionsThe options for the ack, such as 'cancel'

◆ ack() [3/3]

void AMPS.Client.Client.ack ( String  topic,
String  bookmark,
String  options = null 
)
inline

ACKS a message queue message.

Parameters
topicThe topic of the message.
bookmarkThe bookmark of the message.

◆ addMessageHandler()

void AMPS.Client.Client.addMessageHandler ( CommandId  commandId_,
MessageHandler  messageHandler_,
Message.AckTypes  requestedAcks_,
bool  isSubscribe_ 
)
inline

Adds a MessageHandler for a given CommandId to self.

Parameters
commandId_The command, query, or subid used for this route.
messageHandler_The message handler to route to
requestedAcks_The acks requested to be sent to the handler
isSubscribe_True if this route is for an ongoing subscription

◆ allocateMessage()

Message AMPS.Client.Client.allocateMessage ( )
inline

Creates a new Message appropriate for this client. This function should be called rarely, since it does allocate a handful of small objects. Users sensitive to garbage collection delays should cache the message object for later usage.

Returns
A new Message instance

◆ bookmarkSubscribe()

CommandId AMPS.Client.Client.bookmarkSubscribe ( MessageHandler  messageHandler,
String  topic,
String  filter = null,
CommandId  subId = null,
String  bookmark = null,
string  options = null,
long  timeout = 0 
)
inline

Places a bookmark subscription with AMPS. Starts replay at the most recent message reported by the BookmarkStore.

Parameters
messageHandlerThe message handler to invoke with matching messages
topicThe topic to subscribe to
filterOnly messages with data that match this filter will be received
subIdYou may optionally provide a subscription ID to ease recovery scenarios, instead of having the system automatically generate one for you. When used with the 'replace' option, this is the subscription to be replaced. With a bookmark store, this is the subscription ID used for recovery. So, when using a persistent bookmark store, provide an explicit subscription ID that is consistent across application restarts.
bookmarkA bookmark identifer, one of the constants from Client.Bookmarks, or a timestamp of the form YYYYmmddTHHMMSS, as described in the AMPS User's Guide.
optionsA Message.Options> value indicating desired options for this subscription. Use Message.Options.None if no options are desired.
timeoutThe maximum time to wait for the subscription to be placed (milliseconds), where 0 indicates no timeout
Returns
The universally unique CommandId assigned to this command
Exceptions
SubscriptionAlreadyExistsExceptionA subscription with this subId is already registered
BadFilterExceptionThe provided filter is invalid
BadRegexTopicExceptionThe topic specified was an invalid regular expression
TimedOutExceptionThe operation took longer than the timeout to execute
DisconnectedExceptionThe client wasn't connected when the operation was executed

◆ close()

void AMPS.Client.Client.close ( )
inline

Disconnect from the AMPS server.

◆ connect()

virtual void AMPS.Client.Client.connect ( string  uri)
inlinevirtual

Connects to the AMPS instance through the provided URI. The URI is a String with the format:

transport://user:password@host:port/protocol

The elements in the URI string are as follows:

  • transport – the network transport used for the connection
  • user(optional) the userId used to authenticate the connection
  • password(optional) the password used to authenticate the connection
  • host – the hostname or IP address of the host where AMPS is running
  • port – the port to connect to
  • protocol – the protocol used for the connection
Parameters
uriThe URI string to connect to
Exceptions
ConnectionRefusedExceptionThe connection could not be established
AlreadyConnectedExceptionThe connection is already connected
InvalidURIExceptionThe specified URI is invalid
ProtocolExceptionThe protocol is invalid
TransportTypeExceptionThe transport type is invalid

Reimplemented in AMPS.Client.HAClient.

◆ deltaPublish() [1/4]

ulong AMPS.Client.Client.deltaPublish ( byte[]  topic,
int  topicOffset,
int  topicLength,
byte[]  data,
int  dataOffset,
int  dataLength 
)
inline

Delta publish a message to an AMPS topic. If the client has a publish store set,

then the client will store the message before forwarding the message to AMPS. This method does not wait for a response from the AMPS server. To detect failure, install a failed write handler. If a DisconnectException occurs, the message is still stored in the publish store.

Parameters
topicarray containing the topic to publish the data to
topicOffsetoffset into topic array where the topic name begins
topicLengthlength of topic in topic array
dataarray containing the data to publish
dataOffsetoffset into the data array where the data begins
dataLengthlength of the data in data array
Returns
The sequence number for the message when a persisten store is configured for the client, 0 if no store is configured.

◆ deltaPublish() [2/4]

ulong AMPS.Client.Client.deltaPublish ( byte[]  topic,
int  topicOffset,
int  topicLength,
byte[]  data,
int  dataOffset,
int  dataLength,
int  expiration 
)
inline

Delta publish a message to an AMPS topic. If the client has a publish store set,

then the client will store the message before forwarding the message to AMPS. This method does not wait for a response from the AMPS server. To detect failure, install a failed write handler. If a DisconnectException occurs, the message is still stored in the publish store.

Parameters
topicarray containing the topic to publish the data to
topicOffsetoffset into topic array where the topic name begins
topicLengthlength of topic in topic array
dataarray containing the data to publish
dataOffsetoffset into the data array where the data begins
expirationThe number of seconds until the message expires.
dataLengthlength of the data in data array
Returns
The sequence number for the message when a persisten store is configured for the client, 0 if no store is configured.

◆ deltaPublish() [3/4]

ulong AMPS.Client.Client.deltaPublish ( String  topic,
String  data 
)
inline

Delta publish a message to an AMPS topic. If the client has a publish store set,

then the client will store the message before forwarding the message to AMPS. This method does not wait for a response from the AMPS server. To detect failure, install a failed write handler. If a DisconnectException occurs, the message is still stored in the publish store.

Parameters
topicTopic to publish the data to
dataData to publish to the topic
Returns
The sequence number for the message when a persisten store is configured for the client, 0 if no store is configured.
Exceptions
DisconnectedExceptionThe client was disconnected at time of publish

◆ deltaPublish() [4/4]

ulong AMPS.Client.Client.deltaPublish ( String  topic,
String  data,
int  expiration 
)
inline

Delta publish a message to an AMPS topic. If the client has a publish store set,

then the client will store the message before forwarding the message to AMPS. This method does not wait for a response from the AMPS server. To detect failure, install a failed write handler. If a DisconnectException occurs, the message is still stored in the publish store.

Parameters
topicTopic to publish the data to
dataData to publish to the topic
expirationThe number of seconds until the message expires.
Returns
The sequence number for the message when a persisten store is configured for the client, 0 if no store is configured.
Exceptions
DisconnectedExceptionThe client was disconnected at time of publish

◆ deltaSubscribe() [1/2]

CommandId AMPS.Client.Client.deltaSubscribe ( Action< Message messageHandler,
String  topic,
String  filter = null,
String  options = null,
long  timeout = 0,
String  subId = null 
)
inline

Places a delta subscription with AMPS.

Parameters
messageHandlerThe lambda function to invoke with matching messages
topicThe topic to subscribe to
filterThe filter
timeoutThe maximum time to wait for the subscription to be placed (milliseconds), where 0 indicates no timeout
Returns
The command identifier assigned to this command
Exceptions
TimedOutExceptionThe command execution exceeded the timeout value
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.
NotEntitledExceptionAn entitlement error occured on this topic.
BadFilterExceptionThe specified filter was invalid.
BadRegexTopicExceptionThe specified regex topic was invalid.
SubscriptionAlreadyExistsExceptionThe specified subscription ID already exists.

◆ deltaSubscribe() [2/2]

CommandId AMPS.Client.Client.deltaSubscribe ( MessageHandler  messageHandler,
String  topic,
String  filter = null,
String  options = null,
long  timeout = 0,
String  subId = null 
)
inline

Places a delta subscription with AMPS.

Parameters
messageHandlerThe message handler to invoke with matching messages
topicThe topic to subscribe to
filterThe filter
timeoutThe maximum time to wait for the subscription to be placed (milliseconds), where 0 indicates no timeout
Returns
The command identifier assigned to this command
Exceptions
TimedOutExceptionThe command execution exceeded the timeout value
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.
NotEntitledExceptionAn entitlement error occured on this topic.
BadFilterExceptionThe specified filter was invalid.
BadRegexTopicExceptionThe specified regex topic was invalid.
SubscriptionAlreadyExistsExceptionThe specified subscription ID already exists.

◆ disconnect()

virtual void AMPS.Client.Client.disconnect ( )
inlinevirtual

Disconnect from the AMPS server.

Reimplemented in AMPS.Client.HAClient.

◆ execute()

MessageStream AMPS.Client.Client.execute ( Command  command)
inline

Execute the provided command and return messages received in response in a MessageStream.

This method creates a message based on the provided Command, sends the message to AMPS, and receives the results. AMPS sends the message and receives the results on a background thread. That thread populates the MessageStream returned by this method.

Parameters
commandThe Command object containing the command to send to AMPS
Returns
A MessageStream that provides message received in response to the command

◆ executeAsync() [1/2]

CommandId AMPS.Client.Client.executeAsync ( Command  command,
Action< Message action 
)
inline

Execute the provided command on a background thread and provide messages received in response to the handler provided.

This method creates a message based on the provided Command, sends the message to AMPS, and invokes the provided Action to process messages returned in response to the command. AMPS sends the message and receives the results on a background thread. The MessageHandler runs on the background thread.

Parameters
commandThe Command object containing the command to send to AMPS
actionThe Action to invoke to process messages received
Returns
the CommandId for the command

◆ executeAsync() [2/2]

CommandId AMPS.Client.Client.executeAsync ( Command  command,
MessageHandler  handler = null 
)
inline

Execute the provided command and process responses on the client receive thread using the provided handler.

This method creates a message based on the provided Command, sends the message to AMPS, and invokes the provided MessageHandler to process messages returned in response to the command. Rather than providing messages on the calling thread, the Client runs the message handler directly on the client receive thread.

When the provided MessageHandler is not null, this method blocks until AMPS acknowledges that the command has been processed. The results of the command after that acknowledgement are provided to the MessageHandler.

Parameters
commandThe Command object containing the command to send to AMPS
handlerThe MessageHandler to invoke to process messages received
Returns
the CommandId for the command

◆ flush() [1/2]

long AMPS.Client.Client.flush ( )
inline

Clear the queued messages which may be waiting in the transport

Returns
long Number of messages or bytes queued after flush is completed or timed out

◆ flush() [2/2]

long AMPS.Client.Client.flush ( long  timeout)
inline

Clear the queued messages which may be waiting in the transport

Parameters
timeoutNumber of milliseconds to wait for flush, where 0 indicates no timeout
Returns
long Number of messages or bytes queued after flush is completed or timed out

◆ flushAcks()

void AMPS.Client.Client.flushAcks ( )
inline

Sends any pending queue ACKs to the server.

◆ getAckBatchSize()

int AMPS.Client.Client.getAckBatchSize ( )
inline

Returns the current ACK batch size. See the documentation for setAckBatchSize(int).

Returns
The current batch size.

◆ getAckTimeout()

long AMPS.Client.Client.getAckTimeout ( )
inline

Returns the queue ack timeout.

Returns
the ack timeout in milliseconds

◆ getAutoAck()

bool AMPS.Client.Client.getAutoAck ( )
inline

Returns the current setting of auto-acking.

Returns
true if enabled, false if disabled

◆ getConnectionInfo()

virtual ConnectionInfo AMPS.Client.Client.getConnectionInfo ( )
inlinevirtual

Assembles a new ConnectionInfo with the state of this client and associated classes.

Returns
A > ConnectionInfo object.

Reimplemented in AMPS.Client.HAClient.

◆ getDefaultMaxDepth()

int AMPS.Client.Client.getDefaultMaxDepth ( )
inline

Return the current default max depth value set on MessageStream results.

Returns
The current default max depth value set on MessageStream results.

◆ getDisconnectHandler()

ClientDisconnectHandler AMPS.Client.Client.getDisconnectHandler ( )
inline

Gets the currently configured ClientDisconnectHandler

Returns
returns the currently configured ClientDisconnectHandler

◆ getDuplicateMessageHandler()

MessageHandler AMPS.Client.Client.getDuplicateMessageHandler ( )
inline

Returns the MessageHandler that will be called in the event of a duplicate message

Returns
MessageHandler to invoke in the event of duplicate messages

◆ getExceptionListener()

ExceptionListener AMPS.Client.Client.getExceptionListener ( )
inline

Gets the currently configured ExceptionListener

Returns
returns the currently configured ExceptionListener

◆ getFailedWriteHandler()

FailedWriteHandler AMPS.Client.Client.getFailedWriteHandler ( )
inline

Returns the the FailedWriteHandler instance that will be called in the event that messages fail to be written

Returns
FailedWriteHandler to invoke for failed writes.

◆ getLogonCorrelationData()

String AMPS.Client.Client.getLogonCorrelationData ( )
inline

Gets the uninterpreted logon correlation information currently set.

Returns
The base64 data to be used for logon correlation.

◆ getName()

String AMPS.Client.Client.getName ( )
inline

Return the name of the Client.

Returns
String Client name

◆ getNameHash()

String AMPS.Client.Client.getNameHash ( )
inline

Return the name hash of the Client as returned by the server after logon.

Returns
String Client name hash

◆ getRetryOnDisconnect()

bool AMPS.Client.Client.getRetryOnDisconnect ( )
inline

Return whether or not messages being sent to the server will retry if the client is disconnected.

Returns
true if it will retry, false if not.

◆ getServerVersion()

int AMPS.Client.Client.getServerVersion ( )
inline

Return the server version retrieved during logon. If the client has not logged on or is connected to a server whose version is less than 3.8.0.0 this function will return 0. The version uses 2 digits each for major minor maintenance and hotfix i.e., 3.8.1.5 will return 3080105 Versions of AMPS prior to 3.8.0.0 did not return the server version to the client in the logon ack.

Returns
The version of the server as a long.

◆ getServerVersionInfo()

VersionInfo AMPS.Client.Client.getServerVersionInfo ( )
inline

Return the server version retrieved during logon. If the client has not logged on or is connected to a server whose version is less than 3.8.0.0 this function will return the latest release version. The version is returned as a VersionInfo. Versions of AMPS prior to 3.8.0.0 did not return the server version to the client in the logon ack.

Returns
VersionInfo the version of the server.

◆ getSubscriptionManager()

SubscriptionManager AMPS.Client.Client.getSubscriptionManager ( )
inline

Gets the currently configured SubscriptionManager

Returns
returns the currently configured SubscriptionManager

◆ getTransport()

Transport AMPS.Client.Client.getTransport ( )
inline

Return the underlying transport. For advanced users, this method provides direct access to the transport. Care needs to be taken to not modify the underlying transport in ways that are incompatible with the Client.

Returns
Transport Underlying transport instance

◆ getURI()

Uri AMPS.Client.Client.getURI ( )
inline

Returns the URI the client is connected to.

Returns
Uri the URI the client is configured to connect to

◆ getVersion()

static String AMPS.Client.Client.getVersion ( )
inlinestatic

Return the build number for the client that is stored in the Manifest.mf of the jar file.

Returns
String Build version number.

◆ getVersionAsInt()

static int AMPS.Client.Client.getVersionAsInt ( String  version)
inlinestatic

Return the numeric value for the given version string with the pattern: Major.Minor.Maintenance.Hotfix The version uses 2 digits each for major minor maintenance and hotfix i.e., 3.8.1.5 will return 3080105 Version strings passed in can be shortened to not include all levels so 3.8 will return 3080000.

Parameters
versionThe version string to convert.
Returns
The version as a int.
Exceptions
CommandExceptionThe string doesn't represent a valid version.

◆ logon() [1/6]

virtual CommandId AMPS.Client.Client.logon ( )
inlinevirtual

Logs into AMPS with the parameters provided in the connect method.

Returns
The command identifier
Exceptions
TimedOutExceptionThe command execution exceeded the timeout value
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.

Reimplemented in AMPS.Client.HAClient.

◆ logon() [2/6]

virtual CommandId AMPS.Client.Client.logon ( long  timeout)
inlinevirtual

Logs into AMPS with the parameters provided in the connect method and the logon correlation data if set.

Parameters
timeoutThe number of milliseconds to wait for the command to execute, where 0 indicates no timeout
Returns
The command identifier
Exceptions
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.

Reimplemented in AMPS.Client.HAClient.

◆ logon() [3/6]

virtual CommandId AMPS.Client.Client.logon ( long  timeout,
Authenticator  authenticator 
)
inlinevirtual

Logs into AMPS with the parameters provided in the connect method and the logon correlation data if set.

Parameters
timeoutThe number of milliseconds to wait for the command to execute, where 0 indicates no timeout
authenticatorThe authenticator to use for logging in.
Returns
The command identifier
Exceptions
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.

Reimplemented in AMPS.Client.HAClient.

◆ logon() [4/6]

virtual CommandId AMPS.Client.Client.logon ( long  timeout,
Authenticator  authenticator,
string  options 
)
inlinevirtual

Logs into AMPS with the parameters provided in the connect method and the logon correlation data if set.

Parameters
timeoutThe number of milliseconds to wait for the command to execute, where 0 indicates no timeout
authenticatorThe authenticator to use for logging in.
optionsThe options string to pass on to the server during logon.
Returns
The command identifier
Exceptions
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.

Reimplemented in AMPS.Client.HAClient.

◆ logon() [5/6]

virtual CommandId AMPS.Client.Client.logon ( long  timeout,
string  options 
)
inlinevirtual

Logs into AMPS with the parameters provided in the connect method and the logon correlation data if set.

Parameters
timeoutThe number of milliseconds to wait for the command to execute, where 0 indicates no timeout
optionsThe options string to pass on to the server during logon.
Returns
The command identifier
Exceptions
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.

Reimplemented in AMPS.Client.HAClient.

◆ logon() [6/6]

virtual CommandId AMPS.Client.Client.logon ( string  options)
inlinevirtual

Logs into AMPS with the parameters provided in the connect method and the logon correlation data if set.

Parameters
optionsThe options string to pass on to the server during logon.
Returns
The command identifier
Exceptions
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.

Reimplemented in AMPS.Client.HAClient.

◆ publish() [1/4]

ulong AMPS.Client.Client.publish ( byte[]  topic,
int  topicOffset,
int  topicLength,
byte[]  data,
int  dataOffset,
int  dataLength 
)
inline

Publish a message to an AMPS topic. If the client has a publish store set,

then the client will store the message before forwarding the message to AMPS. This method does not wait for a response from the AMPS server. To detect failure, install a failed write handler. If a DisconnectException occurs, the message is still stored in the publish store.

Parameters
topicarray containing the topic to publish the data to
topicOffsetoffset into topic array where the topic name begins
topicLengthlength of topic in topic array
dataarray containing the data to publish
dataOffsetoffset into the data array where the data begins
dataLengthlength of the data in data array
Returns
The sequence number for the message when a persisten store is configured for the client, 0 if no store is configured.
Exceptions
DisconnectedExceptionThe client is not connected; the program needs to call connect()
StoreExceptionAn error occurred writing to the local HA store

◆ publish() [2/4]

ulong AMPS.Client.Client.publish ( byte[]  topic,
int  topicOffset,
int  topicLength,
byte[]  data,
int  dataOffset,
int  dataLength,
int  expiration 
)
inline

Publish a message to an AMPS topic. If the client has a publish store set,

then the client will store the message before forwarding the message to AMPS. This method does not wait for a response from the AMPS server. To detect failure, install a failed write handler. If a DisconnectException occurs, the message is still stored in the publish store.

Parameters
topicarray containing the topic to publish the data to
topicOffsetoffset into topic array where the topic name begins
topicLengthlength of topic in topic array
dataarray containing the data to publish
dataOffsetoffset into the data array where the data begins
dataLengthlength of the data in data array
expirationthe number of seconds until the message expires.
Returns
The sequence number for the message when a persisten store is configured for the client, 0 if no store is configured.
Exceptions
DisconnectedExceptionThe client is not connected; the program needs to call connect()
StoreExceptionAn error occurred writing to the local HA store

◆ publish() [3/4]

ulong AMPS.Client.Client.publish ( String  topic,
String  data 
)
inline

Publish a message to an AMPS topic. If the client has a publish store set,

then the client will store the message before forwarding the message to AMPS. This method does not wait for a response from the AMPS server. To detect failure, install a failed write handler. If a DisconnectException occurs, the message is still stored in the publish store.

Parameters
topicTopic to publish the data to
dataData to publish to the topic
Returns
The sequence number for the message when a persisten store is configured for the client, 0 if no store is configured.
Exceptions
DisconnectedExceptionThe client is disconnected; the program needs to call connect()

◆ publish() [4/4]

ulong AMPS.Client.Client.publish ( String  topic,
String  data,
int  expiration 
)
inline

Publish a message to an AMPS topic. If the client has a publish store set,

then the client will store the message before forwarding the message to AMPS. This method does not wait for a response from the AMPS server. To detect failure, install a failed write handler. If a DisconnectException occurs, the message is still stored in the publish store.

Parameters
topicTopic to publish the data to
dataData to publish to the topic
expirationThe number of seconds until the message expires.
Returns
The sequence number for the message when a persisten store is configured for the client, 0 if no store is configured.
Exceptions
DisconnectedExceptionThe client is not connected; the program needs to call connect()

◆ removeMessageHandler()

bool AMPS.Client.Client.removeMessageHandler ( CommandId  commandId_)
inline

Remove a route from self.

Parameters
commandId_The route to remove
Returns
true if the route was removed.

◆ send() [1/3]

CommandId AMPS.Client.Client.send ( Action< Message messageHandler,
Message  message,
long  timeout 
)
inline

Send a Message to AMPS and register the messageHandler for any messages resulting from command execution.

Parameters
messageHandlerThe message handler that'll receive messages for this command
messageThe message to send
timeoutThe number of milliseconds to wait for command acknowledgment, where 0 indicates no timeout
Returns
The command identifier assigned to this command
Exceptions
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.
NotEntitledExceptionAn entitlement error occured on this topic.
InvalidTopicExceptionThe specified topic was invalid.
BadFilterExceptionThe specified filter was invalid.
BadRegexTopicExceptionThe specified regex topic was invalid.
SubscriptionAlreadyExistsExceptionThe specified subscription ID already exists.

◆ send() [2/3]

void AMPS.Client.Client.send ( Message  m)
inline

Send a Message to AMPS via the Transport used in the Client.

Parameters
mThe message to send
Exceptions
DisconnectedExceptionThe connection was disconnected at time of send

◆ send() [3/3]

CommandId AMPS.Client.Client.send ( MessageHandler  messageHandler,
Message  message,
long  timeout 
)
inline

Send a Message to AMPS and register the messageHandler for any messages resulting from command execution.

Parameters
messageHandlerThe message handler that'll receive messages for this command
messageThe message to send
timeoutThe number of milliseconds to wait for command acknowledgment, where 0 indicates no timeout
Returns
The command identifier assigned to this command
Exceptions
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.
NotEntitledExceptionAn entitlement error occured on this topic.
InvalidTopicExceptionThe specified topic was invalid.
BadFilterExceptionThe specified filter was invalid.
BadRegexTopicExceptionThe specified regex topic was invalid.
SubscriptionAlreadyExistsExceptionThe specified subscription ID already exists.

◆ setAckBatchSize()

void AMPS.Client.Client.setAckBatchSize ( int  batchSize)
inline

Sets the current ACK batch size.The ACK batch size controls how many successful ACKs (which are sow_delete messages) are batched together before sending to the server.When combined with the "max_backlog" and MaxPerSubscriptionBacklog server configuration parameter, greater network efficiency can be achieved when using message queues.Setting this parameter causes calls to "ack" and successful auto-acks to be batched; unsuccessful/cancel acks are sent immediately.

Parameters
batchSizeThe batch size to use (default:1)

◆ setAckTimeout()

void AMPS.Client.Client.setAckTimeout ( long  ackTimeout)
inline

Sets the ack timeout – the maximum time to let a success ack be cached before sending.

Parameters
ackTimeoutthe ack timeout, in milliseconds

◆ setAutoAck()

void AMPS.Client.Client.setAutoAck ( bool  isAutoAckEnabled)
inline

Enables or disables auto-acking. When auto-acking is enabled any successful return from a message handler functiokn will result in an ACK (sow_delete) message sent to the server. Any thrown exception will result in a "cancel" ACK sent to the server.

Parameters
isAutoAckEnabledtrue to enable, false to disable

◆ setDefaultMaxDepth()

void AMPS.Client.Client.setDefaultMaxDepth ( int  defaultMaxDepth)
inline

Set the default max depth to be used on all MessageStream results.

Parameters
defaultMaxDepthThe new default value for max depth.

◆ setDisconnectHandler() [1/2]

void AMPS.Client.Client.setDisconnectHandler ( Action< Client disconnectHandler)
inline

Sets the lambda function called in the event of client disconnect

Parameters
disconnectHandler

◆ setDisconnectHandler() [2/2]

void AMPS.Client.Client.setDisconnectHandler ( ClientDisconnectHandler  disconnectHandler)
inline

Sets the ClientDisconnectHandler . In the event that the Client is unintentionally disconnected from AMPS, the

invoke method from the ClientDisconnectHandler will be invoked.

Parameters
disconnectHandlerThe disconnect handler

◆ setDuplicateMessageHandler()

void AMPS.Client.Client.setDuplicateMessageHandler ( MessageHandler  messageHandler)
inline

Sets the MessageHandler that will be called in the event of a duplicate message

Parameters
messageHandlerMessageHandler to invoke in the event of duplicate messages

◆ setExceptionListener()

void AMPS.Client.Client.setExceptionListener ( ExceptionListener  exceptionListener)
inline

Sets the ExceptionListener instance used for communicating absorbed exceptions.

Parameters
exceptionListenerThe exception listener instance to invoke for exceptions.

◆ setFailedWriteHandler() [1/2]

void AMPS.Client.Client.setFailedWriteHandler ( FailedWriteHandler  handler_)
inline

Sets the FailedWriteHandler instance that will be called in the event that messages fail to be written

Parameters
handler_FailedWriteHandler to invoke for failed writes.

◆ setFailedWriteHandler() [2/2]

void AMPS.Client.Client.setFailedWriteHandler ( FailedWriteHandlerV4  handler_)
inline

Sets the FailedWriteHandlerV4 instance that will be called in the event that messages fail to be written

Parameters
handler_FailedWriteHandlerV4 to invoke for failed writes.

◆ setGlobalCommandTypeMessageHandler() [1/3]

void AMPS.Client.Client.setGlobalCommandTypeMessageHandler ( GlobalCommandTypeHandlers  command_,
MessageHandler  messageHandler_ 
)
inline

Sets the MessageHandler that will be called in the event of a message of the given command type.

Parameters
command_GlobalCommandTypeHandlers type of command to send to messageHandler_
messageHandlerMessageHandler to invoke

◆ setGlobalCommandTypeMessageHandler() [2/3]

void AMPS.Client.Client.setGlobalCommandTypeMessageHandler ( Message.Commands  command_,
MessageHandler  messageHandler_ 
)
inline

Sets the MessageHandler that will be called in the event of a message of the given command type.

Parameters
command_Message.Commands type of command to send to messageHandler_
messageHandlerMessageHandler to invoke

◆ setGlobalCommandTypeMessageHandler() [3/3]

void AMPS.Client.Client.setGlobalCommandTypeMessageHandler ( string  command_,
MessageHandler  messageHandler_ 
)
inline

Sets the MessageHandler that will be called in the event of a message of the given command type.

Parameters
command_The type of command to send to messageHandler_
messageHandlerMessageHandler to invoke

◆ setHeartbeat() [1/2]

void AMPS.Client.Client.setHeartbeat ( int  heartbeatInterval_)
inline

Sets a heartbeat on this connection. When a heartbeat is set, the client periodically sends a heartbeat message to AMPS. This helps the client more quickly detect disconnection from AMPS.

Parameters
heartbeatInterval_the interval (in seconds) at which to send a heartbeat message

◆ setHeartbeat() [2/2]

virtual void AMPS.Client.Client.setHeartbeat ( int  heartbeatInterval_,
int  readTimeout_ 
)
inlinevirtual

Sets a heartbeat on this connection. When a heartbeat is set, the client periodically sends a heartbeat message to AMPS. This helps the client more quickly detect disconnection from AMPS.

Parameters
heartbeatInterval_the interval (in seconds) at which to send a heartbeat message
readTimeout_the length of time (in seconds) to wait for a response to a heartbeat message

◆ setLastChanceMessageHandler() [1/2]

void AMPS.Client.Client.setLastChanceMessageHandler ( Action< Message messageHandler)
inline

Sets the MessageHandler instance used when no other handler matches.

Parameters
messageHandlerThe message handler to invoke when no other handler matches.

◆ setLastChanceMessageHandler() [2/2]

void AMPS.Client.Client.setLastChanceMessageHandler ( MessageHandler  messageHandler)
inline

Sets the MessageHandler instance used when no other handler matches.

Parameters
messageHandlerThe message handler to invoke when no other handler matches.

◆ setLogonCorrelationData()

void AMPS.Client.Client.setLogonCorrelationData ( String  correlationData)
inline

Gets the uninterpreted logon correlation information currently set.

Parameters
correlationDataThe base64 data to be used for logon correlation.

◆ setRetryOnDisconnect()

void AMPS.Client.Client.setRetryOnDisconnect ( bool  isRetryOnDisconnect)
inline

Set whether or not messages being sent to the server should retry if the client is disconnected. This is most useful if you are publishing data that has a very short lifetime and so is no longer relevant after the time it takes to reconnect.

Parameters
isRetryOnDisconnectFalse to disable default behavior of autmatic retry.

◆ setSubscriptionManager()

void AMPS.Client.Client.setSubscriptionManager ( SubscriptionManager  subscriptionManager)
inline

Sets the SubscriptionManager instance used for recording active subscriptions.

Parameters
subscriptionManagerThe subscription manager invoked when there is a change to the subscriptions

◆ setThreadCreatedHandler() [1/2]

void AMPS.Client.Client.setThreadCreatedHandler ( Action  handler_)
inline

Set a handler that is invoked immediately by any thread created by the transport.

Action to be invoked by any new transport threads.

◆ setThreadCreatedHandler() [2/2]

void AMPS.Client.Client.setThreadCreatedHandler ( ThreadCreatedHandler  handler_)
inline

Set a handler that is invoked immediately by any thread created by the transport.

ThreadCreatedHandler to be invoked by any new transport threads.

◆ setTransportFilter()

void AMPS.Client.Client.setTransportFilter ( TransportFilter  filter_)
inline

Sets a TransportFilter that filters raw bytes bfeore send and after receive.

Parameters
filter_A TransportFilter such as AMPS.Client.TransportTraceFilter.

◆ setUnhandledMessageHandler() [1/2]

void AMPS.Client.Client.setUnhandledMessageHandler ( Action< Message messageHandler)
inline

Sets the lambda function used when no other handler matches.

Parameters
messageHandlerThe function to invoke when no other handler matches.

◆ setUnhandledMessageHandler() [2/2]

void AMPS.Client.Client.setUnhandledMessageHandler ( MessageHandler  messageHandler)
inline

Sets the MessageHandler instance used when no other handler matches.

Parameters
messageHandlerThe message handler to invoke when no other handler matches.

◆ sow() [1/8]

CommandId AMPS.Client.Client.sow ( Action< Message messageHandler,
String  topic,
int  batchSize,
long  timeout 
)
inline

Executes a SOW query.

Parameters
messageHandlerThe function to invoke with matching messages
topicThe topic to subscribe to
batchSizeThe batching parameter to use for the results
timeoutThe maximum time to wait for the subscription to be placed (milliseconds), where 0 indicates no timeout
Returns
Exceptions
TimedOutExceptionThe command execution exceeded the timeout value
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.
NotEntitledExceptionAn entitlement error occured on this topic.
InvalidTopicExceptionThe specified topic was invalid.
BadRegexTopicExceptionThe specified regex topic was invalid.

◆ sow() [2/8]

CommandId AMPS.Client.Client.sow ( Action< Message messageHandler,
String  topic,
long  timeout 
)
inline

Executes a SOW query.

Parameters
messageHandlerThe message handler to invoke with matching messages
topicThe topic to subscribe to
timeoutThe maximum time to wait for the subscription to be placed (milliseconds), where 0 indicates no timeout
Returns
Exceptions
TimedOutExceptionThe command execution exceeded the timeout value
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.
NotEntitledExceptionAn entitlement error occured on this topic.
InvalidTopicExceptionThe specified topic was invalid.
BadRegexTopicExceptionThe specified regex topic was invalid.

◆ sow() [3/8]

CommandId AMPS.Client.Client.sow ( Action< Message messageHandler,
String  topic,
String  filter = null,
String  orderBy = null,
String  bookmark = null,
String  options = null,
int  batchSize = 10,
int  topN = -1,
long  timeout = 0 
)
inline

Executes a SOW query.

Parameters
messageHandlerThe message handler to invoke with matching messages
topicThe topic to subscribe to
filterThe filter
orderByThe ordering property
bookmarkA bookmark identifer, one of the constants from Client.Bookmarks, or a timestamp of the form YYYYmmddTHHMMSS, as described in the AMPS User's Guide. This the point at which AMPS executes the historical query.
optionsA Message.Options> value indicating desired options for this query. Use Message.Options.None if no options are desired.
batchSizeThe batching parameter to use for the results
topNThe maximum number of records the server will return (default is all that match)
timeoutThe maximum time to wait for the subscription to be placed (milliseconds), where 0 indicates no timeout
Returns
The command identifier assigned to this command
Exceptions
TimedOutExceptionThe command execution exceeded the timeout value
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.
NotEntitledExceptionAn entitlement error occured on this topic.
InvalidTopicExceptionThe specified topic was invalid.
BadFilterExceptionThe specified filter was invalid.
BadRegexTopicExceptionThe specified regex topic was invalid.

◆ sow() [4/8]

CommandId AMPS.Client.Client.sow ( MessageHandler  messageHandler,
String  topic,
int  batchSize,
long  timeout 
)
inline

Executes a SOW query.

Parameters
messageHandlerThe message handler to invoke with matching messages
topicThe topic to subscribe to
batchSizeThe batching parameter to use for the results
timeoutThe maximum time to wait for the subscription to be placed (milliseconds), where 0 indicates no timeout
Returns
Exceptions
TimedOutExceptionThe command execution exceeded the timeout value
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.
NotEntitledExceptionAn entitlement error occured on this topic.
InvalidTopicExceptionThe specified topic was invalid.
BadRegexTopicExceptionThe specified regex topic was invalid.

◆ sow() [5/8]

CommandId AMPS.Client.Client.sow ( MessageHandler  messageHandler,
String  topic,
long  timeout 
)
inline

Executes a SOW query.

Parameters
messageHandlerThe message handler to invoke with matching messages
topicThe topic to subscribe to
timeoutThe maximum time to wait for the subscription to be placed (milliseconds), where 0 indicates no timeout
Returns
Exceptions
TimedOutExceptionThe command execution exceeded the timeout value
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.
NotEntitledExceptionAn entitlement error occured on this topic.
InvalidTopicExceptionThe specified topic was invalid.
BadRegexTopicExceptionThe specified regex topic was invalid.

◆ sow() [6/8]

CommandId AMPS.Client.Client.sow ( MessageHandler  messageHandler,
String  topic,
String  filter,
int  batchSize,
long  timeout 
)
inline

Executes a SOW query.

Parameters
messageHandlerThe message handler to invoke with matching messages
topicThe topic to subscribe to
filterThe filter
batchSizeThe batching parameter to use for the results
timeoutThe maximum time to wait for the subscription to be placed (milliseconds), where 0 indicates no timeout
Returns
The command identifier assigned to this command
Exceptions
TimedOutExceptionThe command execution exceeded the timeout value
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.
NotEntitledExceptionAn entitlement error occured on this topic.
InvalidTopicExceptionThe specified topic was invalid.
BadFilterExceptionThe specified filter was invalid.
BadRegexTopicExceptionThe specified regex topic was invalid.

◆ sow() [7/8]

CommandId AMPS.Client.Client.sow ( MessageHandler  messageHandler,
String  topic,
String  filter = null,
String  orderBy = null,
String  bookmark = null,
String  options = null,
int  batchSize = 10,
int  topN = -1,
long  timeout = 0 
)
inline

Executes a SOW query.

Parameters
messageHandlerThe message handler to invoke with matching messages
topicThe topic to subscribe to
filterThe filter
orderByThe ordering property
bookmarkA bookmark identifer, one of the constants from Client.Bookmarks, or a timestamp of the form YYYYmmddTHHMMSS, as described in the AMPS User's Guide. This the point at which AMPS executes the historical query.
optionsA Message.Options> value indicating desired options for this query. Use Message.Options.None if no options are desired.
batchSizeThe batching parameter to use for the results
topNThe maximum number of records the server will return (default is all that match)
timeoutThe maximum time to wait for the subscription to be placed (milliseconds), where 0 indicates no timeout
Returns
The command identifier assigned to this command
Exceptions
TimedOutExceptionThe command execution exceeded the timeout value
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.
NotEntitledExceptionAn entitlement error occured on this topic.
InvalidTopicExceptionThe specified topic was invalid.
BadFilterExceptionThe specified filter was invalid.
BadRegexTopicExceptionThe specified regex topic was invalid.

◆ sow() [8/8]

MessageStream AMPS.Client.Client.sow ( String  topic,
String  filter = null,
String  orderBy = null,
String  bookmark = null,
String  options = null,
int  batchSize = 10,
int  topN = -1,
long  timeout = 0 
)
inline

Executes a SOW query.

Parameters
topicThe topic to subscribe to
filterThe filter
orderByThe ordering property
bookmarkA bookmark identifer, one of the constants from Client.Bookmarks, or a timestamp of the form YYYYmmddTHHMMSS, as described in the AMPS User's Guide. This the point at which AMPS executes the historical query.
optionsA Message.Options> value indicating desired options for this query. Use Message.Options.None if no options are desired.
batchSizeThe batching parameter to use for the results
topNThe maximum number of records the server will return (default is all that match)
timeoutThe maximum time to wait for the subscription to be placed (milliseconds), where 0 indicates no timeout
Returns
A MessageStream to iterate over
Exceptions
TimedOutExceptionThe command execution exceeded the timeout value
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.
NotEntitledExceptionAn entitlement error occured on this topic.
InvalidTopicExceptionThe specified topic was invalid.
BadFilterExceptionThe specified filter was invalid.
BadRegexTopicExceptionThe specified regex topic was invalid.

◆ sowAndDeltaSubscribe() [1/7]

CommandId AMPS.Client.Client.sowAndDeltaSubscribe ( Action< Message messageHandler,
String  topic,
int  batchSize,
long  timeout 
)
inline

Executes a SOW query and places a delta subscription.

Parameters
messageHandlerThe message handler to invoke with matching messages
topicThe topic to subscribe to
batchSizeThe batching parameter to use for the SOW query results
timeoutThe maximum time to wait for the subscription to be placed (milliseconds), where 0 indicates no timeout
Returns
The command identifier assigned to this command
Exceptions
TimedOutExceptionThe command execution exceeded the timeout value
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.
NotEntitledExceptionAn entitlement error occured on this topic.
InvalidTopicExceptionThe specified topic was invalid.
BadRegexTopicExceptionThe specified regex topic was invalid.

◆ sowAndDeltaSubscribe() [2/7]

CommandId AMPS.Client.Client.sowAndDeltaSubscribe ( Action< Message messageHandler,
String  topic,
long  timeout 
)
inline

Executes a SOW query and places a delta subscription.

Parameters
messageHandlerThe message handler to invoke with matching messages
topicThe topic to subscribe to
timeoutThe maximum time to wait for the subscription to be placed (milliseconds), where 0 indicates no timeout
Returns
The command identifier assigned to this command
Exceptions
TimedOutExceptionThe command execution exceeded the timeout value
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.
NotEntitledExceptionAn entitlement error occured on this topic.
InvalidTopicExceptionThe specified topic was invalid.
BadRegexTopicExceptionThe specified regex topic was invalid.

◆ sowAndDeltaSubscribe() [3/7]

CommandId AMPS.Client.Client.sowAndDeltaSubscribe ( Action< Message messageHandler,
String  topic,
String  filter,
int  batchSize,
bool  oofEnabled,
bool  sendEmpties,
long  timeout 
)
inline

Executes a SOW query and places a delta subscription.

Parameters
messageHandlerThe message handler to invoke with matching messages
topicThe topic to subscribe to
filterThe filter
batchSizeThe batching parameter to use for the SOW query results
oofEnabledSpecifies whether or not Out-of-Focus processing is enabled
sendEmptiesSpecifies whether or not unchanged records are received on the delta subscription
timeoutThe maximum time to wait for the subscription to be placed (milliseconds), where 0 indicates no timeout
Returns
The command identifier assigned to this command
Exceptions
TimedOutExceptionThe command execution exceeded the timeout value
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.
NotEntitledExceptionAn entitlement error occured on this topic.
InvalidTopicExceptionThe specified topic was invalid.
BadFilterExceptionThe specified filter was invalid.
BadRegexTopicExceptionThe specified regex topic was invalid.

◆ sowAndDeltaSubscribe() [4/7]

CommandId AMPS.Client.Client.sowAndDeltaSubscribe ( MessageHandler  messageHandler,
String  topic,
int  batchSize,
long  timeout 
)
inline

Executes a SOW query and places a delta subscription.

Parameters
messageHandlerThe message handler to invoke with matching messages
topicThe topic to subscribe to
batchSizeThe batching parameter to use for the SOW query results
timeoutThe maximum time to wait for the subscription to be placed (milliseconds), where 0 indicates no timeout
Returns
The command identifier assigned to this command
Exceptions
TimedOutExceptionThe command execution exceeded the timeout value
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.
NotEntitledExceptionAn entitlement error occured on this topic.
InvalidTopicExceptionThe specified topic was invalid.
BadRegexTopicExceptionThe specified regex topic was invalid.

◆ sowAndDeltaSubscribe() [5/7]

CommandId AMPS.Client.Client.sowAndDeltaSubscribe ( MessageHandler  messageHandler,
String  topic,
long  timeout 
)
inline

Executes a SOW query and places a delta subscription.

Parameters
messageHandlerThe message handler to invoke with matching messages
topicThe topic to subscribe to
timeoutThe maximum time to wait for the subscription to be placed (milliseconds), where 0 indicates no timeout
Returns
The command identifier assigned to this command
Exceptions
TimedOutExceptionThe command execution exceeded the timeout value
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.
NotEntitledExceptionAn entitlement error occured on this topic.
InvalidTopicExceptionThe specified topic was invalid.
BadRegexTopicExceptionThe specified regex topic was invalid.

◆ sowAndDeltaSubscribe() [6/7]

CommandId AMPS.Client.Client.sowAndDeltaSubscribe ( MessageHandler  messageHandler,
String  topic,
String  filter,
int  batchSize,
bool  oofEnabled,
bool  sendEmpties,
long  timeout 
)
inline

Executes a SOW query and places a delta subscription.

Parameters
messageHandlerThe message handler to invoke with matching messages
topicThe topic to subscribe to
filterThe filter
batchSizeThe batching parameter to use for the SOW query results
oofEnabledSpecifies whether or not Out-of-Focus processing is enabled
sendEmptiesSpecifies whether or not unchanged records are received on the delta subscription
timeoutThe maximum time to wait for the subscription to be placed (milliseconds), where 0 indicates no timeout
Returns
The command identifier assigned to this command
Exceptions
TimedOutExceptionThe command execution exceeded the timeout value
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.
NotEntitledExceptionAn entitlement error occured on this topic.
InvalidTopicExceptionThe specified topic was invalid.
BadFilterExceptionThe specified filter was invalid.
BadRegexTopicExceptionThe specified regex topic was invalid.

◆ sowAndDeltaSubscribe() [7/7]

CommandId AMPS.Client.Client.sowAndDeltaSubscribe ( MessageHandler  messageHandler,
String  topic,
String  filter = null,
String  orderBy = null,
String  bookmark = null,
String  options = null,
int  batchSize = 10,
int  topN = -1,
long  timeout = 0 
)
inline

Executes a SOW query and places a delta subscription.

Parameters
messageHandlerThe message handler to invoke with matching messages
topicThe topic to subscribe to
filterThe filter
orderByThe ordering property
bookmarkA bookmark identifer, one of the constants from Client.Bookmarks, or a timestamp of the form YYYYmmddTHHMMSS, as described in the AMPS User's Guide. This the point at which AMPS executes the historical query.
optionsA Message.Options> value indicating desired options for this query. Use Message.Options.None if no options are desired.
batchSizeThe batching parameter to use for the results
topNThe maximum number of records the server will return (default is all that match)
timeoutThe maximum time to wait for the subscription to be placed (milliseconds), where 0 indicates no timeout
Returns
The command identifier assigned to this command
Exceptions
TimedOutExceptionThe command execution exceeded the timeout value
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.
NotEntitledExceptionAn entitlement error occured on this topic.
InvalidTopicExceptionThe specified topic was invalid.
BadFilterExceptionThe specified filter was invalid.
BadRegexTopicExceptionThe specified regex topic was invalid.

◆ sowAndSubscribe() [1/9]

CommandId AMPS.Client.Client.sowAndSubscribe ( Action< Message a,
String  topic,
int  batchSize,
long  timeout 
)
inline

Executes a SOW query and places a subscription.

Parameters
aThe function to invoke with matching messages
topicThe topic to subscribe to
batchSizeThe batching parameter to use for the SOW query results
timeoutThe maximum time to wait for the subscription to be placed (milliseconds), where 0 indicates no timeout
Returns
The command identifier assigned to this command
Exceptions
TimedOutExceptionThe command execution exceeded the timeout value
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.
NotEntitledExceptionAn entitlement error occured on this topic.
InvalidTopicExceptionThe specified topic was invalid.
BadRegexTopicExceptionThe specified regex topic was invalid.

◆ sowAndSubscribe() [2/9]

CommandId AMPS.Client.Client.sowAndSubscribe ( Action< Message a,
String  topic,
long  timeout 
)
inline

Executes a SOW query and places a subscription.

Parameters
aThe function to invoke with matching messages
topicThe topic to subscribe to
timeoutThe maximum time to wait for the subscription to be placed (milliseconds), where 0 indicates no timeout
Returns
The command identifier assigned to this command
Exceptions
TimedOutExceptionThe command execution exceeded the timeout value
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.
NotEntitledExceptionAn entitlement error occured on this topic.
InvalidTopicExceptionThe specified topic was invalid.
BadRegexTopicExceptionThe specified regex topic was invalid.

◆ sowAndSubscribe() [3/9]

CommandId AMPS.Client.Client.sowAndSubscribe ( Action< Message a,
String  topic,
String  filter,
int  batchSize,
bool  sendOOF,
long  timeout 
)
inline

Executes a SOW query and places a subscription.

Parameters
aThe function to invoke with matching messages
topicThe topic to subscribe to
filterThe filter
batchSizeThe batching parameter to use for the SOW query results
sendOOFTrue if out-of-focus ("OOF") messages are desired.
timeoutThe maximum time to wait for the subscription to be placed (milliseconds), where 0 indicates no timeout
Returns
The command identifier assigned to this command
Exceptions
TimedOutExceptionThe command execution exceeded the timeout value
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.
NotEntitledExceptionAn entitlement error occured on this topic.
InvalidTopicExceptionThe specified topic was invalid.
BadFilterExceptionThe specified filter was invalid.
BadRegexTopicExceptionThe specified regex topic was invalid.

◆ sowAndSubscribe() [4/9]

CommandId AMPS.Client.Client.sowAndSubscribe ( Action< Message messageHandler,
String  topic,
String  filter = null,
String  orderBy = null,
String  bookmark = null,
String  options = null,
int  batchSize = 10,
int  topN = -1,
long  timeout = 0 
)
inline

Executes a SOW query and places a subscription.

Parameters
messageHandlerThe message handler to invoke with matching messages
topicThe topic to subscribe to
filterThe filter
orderByThe ordering property
bookmarkA bookmark identifer, one of the constants from Client.Bookmarks, or a timestamp of the form YYYYmmddTHHMMSS, as described in the AMPS User's Guide. This the point at which AMPS executes the historical query.
optionsA Message.Options> value indicating desired options for this query. Use Message.Options.None if no options are desired.
batchSizeThe batching parameter to use for the results
topNThe maximum number of records the server will return (default is all that match)
timeoutThe maximum time to wait for the subscription to be placed (milliseconds), where 0 indicates no timeout
Returns
The command identifier assigned to this command
Exceptions
TimedOutExceptionThe command execution exceeded the timeout value
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.
NotEntitledExceptionAn entitlement error occured on this topic.
InvalidTopicExceptionThe specified topic was invalid.
BadFilterExceptionThe specified filter was invalid.
BadRegexTopicExceptionThe specified regex topic was invalid.

◆ sowAndSubscribe() [5/9]

CommandId AMPS.Client.Client.sowAndSubscribe ( MessageHandler  messageHandler,
String  topic,
int  batchSize,
long  timeout 
)
inline

Executes a SOW query and places a subscription.

Parameters
messageHandlerThe message handler to invoke with matching messages
topicThe topic to subscribe to
batchSizeThe batching parameter to use for the SOW query results
timeoutThe maximum time to wait for the subscription to be placed (milliseconds), where 0 indicates no timeout
Returns
The command identifier assigned to this command
Exceptions
TimedOutExceptionThe command execution exceeded the timeout value
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.
NotEntitledExceptionAn entitlement error occured on this topic.
InvalidTopicExceptionThe specified topic was invalid.
BadRegexTopicExceptionThe specified regex topic was invalid.

◆ sowAndSubscribe() [6/9]

CommandId AMPS.Client.Client.sowAndSubscribe ( MessageHandler  messageHandler,
String  topic,
long  timeout 
)
inline

Executes a SOW query and places a subscription.

Parameters
messageHandlerThe message handler to invoke with matching messages
topicThe topic to subscribe to
timeoutThe maximum time to wait for the subscription to be placed (milliseconds), where 0 indicates no timeout
Returns
The command identifier assigned to this command
Exceptions
TimedOutExceptionThe command execution exceeded the timeout value
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.
NotEntitledExceptionAn entitlement error occured on this topic.
InvalidTopicExceptionThe specified topic was invalid.
BadRegexTopicExceptionThe specified regex topic was invalid.

◆ sowAndSubscribe() [7/9]

CommandId AMPS.Client.Client.sowAndSubscribe ( MessageHandler  messageHandler,
String  topic,
String  filter,
int  batchSize,
bool  oofEnabled,
long  timeout 
)
inline

Executes a SOW query and places a subscription.

Parameters
messageHandlerThe message handler to invoke with matching messages
topicThe topic to subscribe to
filterThe filter
batchSizeThe batching parameter to use for the SOW query results
oofEnabledTrue if out-of-focus ("OOF") messages are desired.
timeoutThe maximum time to wait for the subscription to be placed (milliseconds), where 0 indicates no timeout
Returns
The command identifier assigned to this command
Exceptions
TimedOutExceptionThe command execution exceeded the timeout value
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.
NotEntitledExceptionAn entitlement error occured on this topic.
InvalidTopicExceptionThe specified topic was invalid.
BadFilterExceptionThe specified filter was invalid.
BadRegexTopicExceptionThe specified regex topic was invalid.

◆ sowAndSubscribe() [8/9]

CommandId AMPS.Client.Client.sowAndSubscribe ( MessageHandler  messageHandler,
String  topic,
String  filter = null,
String  orderBy = null,
String  bookmark = null,
String  options = null,
int  batchSize = 10,
int  topN = -1,
long  timeout = 0 
)
inline

Executes a SOW query and places a subscription.

Parameters
messageHandlerThe message handler to invoke with matching messages
topicThe topic to subscribe to
filterThe filter
orderByThe ordering property
bookmarkA bookmark identifer, one of the constants from Client.Bookmarks, or a timestamp of the form YYYYmmddTHHMMSS, as described in the AMPS User's Guide. This the point at which AMPS executes the historical query.
optionsA Message.Options> value indicating desired options for this query. Use Message.Options.None if no options are desired.
batchSizeThe batching parameter to use for the results
topNThe maximum number of records the server will return (default is all that match)
timeoutThe maximum time to wait for the subscription to be placed (milliseconds), where 0 indicates no timeout
Returns
The command identifier assigned to this command
Exceptions
TimedOutExceptionThe command execution exceeded the timeout value
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.
NotEntitledExceptionAn entitlement error occured on this topic.
InvalidTopicExceptionThe specified topic was invalid.
BadFilterExceptionThe specified filter was invalid.
BadRegexTopicExceptionThe specified regex topic was invalid.

◆ sowAndSubscribe() [9/9]

MessageStream AMPS.Client.Client.sowAndSubscribe ( String  topic,
String  filter = null,
String  orderBy = null,
String  bookmark = null,
String  options = null,
int  batchSize = 10,
int  topN = -1,
long  timeout = 0 
)
inline

Executes a SOW query and places a subscription.

Parameters
topicThe topic to subscribe to
filterThe filter
orderByThe ordering property
bookmarkA bookmark identifer, one of the constants from Client.Bookmarks, or a timestamp of the form YYYYmmddTHHMMSS, as described in the AMPS User's Guide. This the point at which AMPS executes the historical query.
optionsA Message.Options> value indicating desired options for this query. Use Message.Options.None if no options are desired.
batchSizeThe batching parameter to use for the results
topNThe maximum number of records the server will return (default is all that match)
timeoutThe maximum time to wait for the subscription to be placed (milliseconds), where 0 indicates no timeout
Returns
A MessageStream to iterate over.
Exceptions
TimedOutExceptionThe command execution exceeded the timeout value
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.
NotEntitledExceptionAn entitlement error occured on this topic.
InvalidTopicExceptionThe specified topic was invalid.
BadFilterExceptionThe specified filter was invalid.
BadRegexTopicExceptionThe specified regex topic was invalid.

◆ sowDelete() [1/3]

CommandId AMPS.Client.Client.sowDelete ( Action< Message messageHandler,
String  topic,
String  filter,
long  timeout = 0 
)
inline

Executes a SOW delete with filter.

Parameters
messageHandlerThe message handler to invoke with stats and completed acknowledgements
topicThe topic to subscribe to
filterThe filter. To delete all records, set a filter that is always true ('1=1')
timeoutThe maximum time to wait for the SOW delete to be started to be placed (milliseconds), where 0 indicates no timeout
Returns
The command identifier assigned to this command
Exceptions
TimedOutExceptionThe command execution exceeded the timeout value
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.
NotEntitledExceptionAn entitlement error occured on this topic.
InvalidTopicExceptionThe specified topic was invalid.
BadFilterExceptionThe specified filter was invalid.

◆ sowDelete() [2/3]

CommandId AMPS.Client.Client.sowDelete ( MessageHandler  messageHandler,
String  topic,
String  filter,
long  timeout = 0 
)
inline

Executes a SOW delete with filter.

Parameters
messageHandlerThe message handler to invoke with stats and completed acknowledgements
topicThe topic to subscribe to
filterThe filter. To delete all records, set a filter that is always true ('1=1')
timeoutThe maximum time to wait for the SOW delete to be started to be placed (milliseconds), where 0 indicates no timeout
Returns
The command identifier assigned to this command
Exceptions
TimedOutExceptionThe command execution exceeded the timeout value
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.
NotEntitledExceptionAn entitlement error occured on this topic.
InvalidTopicExceptionThe specified topic was invalid.
BadFilterExceptionThe specified filter was invalid.

◆ sowDelete() [3/3]

Message AMPS.Client.Client.sowDelete ( String  topic,
String  filter,
long  timeout = 0 
)
inline

Executes a SOW delete with filter.

Parameters
topicThe topic to subscribe to
filterThe filter. To delete all records, set a filter that is always true ('1=1')
timeoutThe maximum time to wait for the SOW delete to be started to be placed (milliseconds), where 0 indicates no timeout
Returns
The stats message returned from the sow_delete.
Exceptions
TimedOutExceptionThe command execution exceeded the timeout value
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.
NotEntitledExceptionAn entitlement error occured on this topic.
InvalidTopicExceptionThe specified topic was invalid.
BadFilterExceptionThe specified filter was invalid.

◆ sowDeleteByData() [1/2]

CommandId AMPS.Client.Client.sowDeleteByData ( Action< Message messageHandler,
String  topic,
String  data,
long  timeout = 0 
)
inline

Executes a SOW delete by data. AMPS uses key fields in the data to find and delete a message with the same keys.

Parameters
messageHandlerThe message handler to invoke with stats and completed acknowledgements
topicThe topic to delete from
dataThe message to match and delete in the SOW cache.
timeoutThe maximum time to wait for the SOW delete to be started to be placed (milliseconds), where 0 indicates no timeout
Returns
The command identifier assigned to this command
Exceptions
TimedOutExceptionThe command execution exceeded the timeout value
DisconnectedExceptionThe connection was disconnected at time of send
NotEntitledExceptionAn entitlement error occured on this topic.
InvalidTopicExceptionThe specified topic was invalid.

◆ sowDeleteByData() [2/2]

CommandId AMPS.Client.Client.sowDeleteByData ( MessageHandler  messageHandler,
String  topic,
String  data,
long  timeout = 0 
)
inline

Executes a SOW delete by data. AMPS uses key fields in the data to find and delete a message with the same keys.

Parameters
messageHandlerThe message handler to invoke with stats and completed acknowledgements
topicThe topic to delete from
dataThe message to match and delete in the SOW cache.
timeoutThe maximum time to wait for the SOW delete to be started to be placed (milliseconds), where 0 indicates no timeout
Returns
The command identifier assigned to this command
Exceptions
TimedOutExceptionThe command execution exceeded the timeout value
DisconnectedExceptionThe connection was disconnected at time of send
NotEntitledExceptionAn entitlement error occured on this topic.
InvalidTopicExceptionThe specified topic was invalid.

◆ sowDeleteByKeys() [1/2]

CommandId AMPS.Client.Client.sowDeleteByKeys ( Action< Message messageHandler,
String  topic,
String  keys,
long  timeout = 0 
)
inline

Executes a SOW delete by sow key.

Parameters
messageHandlerThe message handler to invoke with stats and completed acknowledgements
topicThe topic to delete from
keysThe keys to delete
timeoutThe maximum time to wait for the SOW delete to be started to be placed (milliseconds), where 0 indicates no timeout
Returns
The command identifier assigned to this command
Exceptions
TimedOutExceptionThe command execution exceeded the timeout value
DisconnectedExceptionThe connection was disconnected at time of send
NotEntitledExceptionAn entitlement error occured on this topic.
InvalidTopicExceptionThe specified topic was invalid.

◆ sowDeleteByKeys() [2/2]

CommandId AMPS.Client.Client.sowDeleteByKeys ( MessageHandler  messageHandler,
String  topic,
String  keys,
long  timeout = 0 
)
inline

Executes a SOW delete by sow key.

Parameters
messageHandlerThe message handler to invoke with stats and completed acknowledgements
topicThe topic to delete from
keysThe keys to delete
timeoutThe maximum time to wait for the SOW delete to be started to be placed (milliseconds), where 0 indicates no timeout
Returns
The command identifier assigned to this command
Exceptions
TimedOutExceptionThe command execution exceeded the timeout value
DisconnectedExceptionThe connection was disconnected at time of send
NotEntitledExceptionAn entitlement error occured on this topic.
InvalidTopicExceptionThe specified topic was invalid.

◆ subscribe() [1/7]

CommandId AMPS.Client.Client.subscribe ( Action< Message messageHandler,
String  topic,
long  timeout 
)
inline

Places a subscription with AMPS.

Parameters
messageHandlerThe message handler to invoke with matching messages
topicThe topic to subscribe to
timeoutThe maximum time to wait for the subscription to be placed (milliseconds), where 0 indicates no timeout
Returns
The command identifier assigned to this command
Exceptions
TimedOutExceptionThe command execution exceeded the timeout value
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.
NotEntitledExceptionAn entitlement error occured on this topic.
BadRegexTopicExceptionThe specified regex topic was invalid.
SubscriptionAlreadyExistsExceptionThe specified subscription ID already exists.

◆ subscribe() [2/7]

CommandId AMPS.Client.Client.subscribe ( Action< Message messageHandler,
String  topic,
String  filter,
long  timeout 
)
inline

Places a subscription with AMPS.

Parameters
messageHandlerThe message handler to invoke with matching messages
topicThe topic to subscribe to
filterThe filter
timeoutThe maximum time to wait for the subscription to be placed (milliseconds), where 0 indicates no timeout
Returns
The command identifier assigned to this command
Exceptions
TimedOutExceptionThe command execution exceeded the timeout value
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.
NotEntitledExceptionAn entitlement error occured on this topic.
BadFilterExceptionThe specified filter was invalid.
BadRegexTopicExceptionThe specified regex topic was invalid.
SubscriptionAlreadyExistsExceptionThe specified subscription ID already exists.

◆ subscribe() [3/7]

CommandId AMPS.Client.Client.subscribe ( Action< Message messageHandler,
String  topic,
String  filter = null,
String  options = null,
long  timeout = 0,
string  subid = null 
)
inline

Places a subscription with AMPS.

Parameters
messageHandlerThe message handler to invoke with matching messages
topicThe topic to subscribe to
filterThe filter
optionsA value from Message.Options indicating additional processing options.
timeoutThe maximum time to wait for the subscription to be placed (milliseconds), where 0 indicates no timeout
Returns
The command identifier assigned to this command
Exceptions
TimedOutExceptionThe command execution exceeded the timeout value
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.
NotEntitledExceptionAn entitlement error occured on this topic.
BadFilterExceptionThe specified filter was invalid.
BadRegexTopicExceptionThe specified regex topic was invalid.

◆ subscribe() [4/7]

CommandId AMPS.Client.Client.subscribe ( MessageHandler  messageHandler,
String  topic,
long  timeout 
)
inline

Places a subscription with AMPS.

Parameters
messageHandlerThe message handler to invoke with matching messages
topicThe topic to subscribe to
timeoutThe maximum time to wait for the subscription to be placed (milliseconds), where 0 indicates no timeout
Returns
The command identifier assigned to this command
Exceptions
TimedOutExceptionThe command execution exceeded the timeout value
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.
NotEntitledExceptionAn entitlement error occured on this topic.
BadRegexTopicExceptionThe specified regex topic was invalid.
SubscriptionAlreadyExistsExceptionThe specified subscription ID already exists.

◆ subscribe() [5/7]

CommandId AMPS.Client.Client.subscribe ( MessageHandler  messageHandler,
String  topic,
String  filter,
long  timeout 
)
inline

Places a subscription with AMPS.

Parameters
messageHandlerThe message handler to invoke with matching messages
topicThe topic to subscribe to
filterThe filter
timeoutThe maximum time to wait for the subscription to be placed (milliseconds), where 0 indicates no timeout
Returns
The command identifier assigned to this command
Exceptions
TimedOutExceptionThe command execution exceeded the timeout value
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.
NotEntitledExceptionAn entitlement error occured on this topic.
BadFilterExceptionThe specified filter was invalid.
BadRegexTopicExceptionThe specified regex topic was invalid.
SubscriptionAlreadyExistsExceptionThe specified subscription ID already exists.

◆ subscribe() [6/7]

CommandId AMPS.Client.Client.subscribe ( MessageHandler  messageHandler,
String  topic,
String  filter = null,
string  options = null,
long  timeout = 0,
String  subId = null 
)
inline

Places a subscription with AMPS.

Parameters
messageHandlerThe message handler to invoke with matching messages
topicThe topic to subscribe to
filterThe filter
optionsA value from Message.Options indicating additional processing options.
timeoutThe maximum time to wait for the subscription to be placed (milliseconds), where 0 indicates no timeout
subIdThe subscription id to use for the subscription.
Returns
The command identifier assigned to this command
Exceptions
TimedOutExceptionThe command execution exceeded the timeout value
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.
NotEntitledExceptionAn entitlement error occured on this topic.
BadFilterExceptionThe specified filter was invalid.
BadRegexTopicExceptionThe specified regex topic was invalid.
SubscriptionAlreadyExistsExceptionThe specified subscription ID already exists.

◆ subscribe() [7/7]

MessageStream AMPS.Client.Client.subscribe ( string  topic,
string  filter = null,
string  options = null,
long  timeout = 0,
string  subid = null 
)
inline

Places a subscription with AMPS.

Parameters
topicThe topic to subscribe to
filterThe filter
optionsA value from Message.Options indicating additional processing options.
timeoutThe maximum time to wait for the subscription to be placed (milliseconds), where 0 indicates no timeout
subIdThe subscription id to use for the subscription.
Returns
A MessageStream to iterate over
Exceptions
TimedOutExceptionThe command execution exceeded the timeout value
DisconnectedExceptionThe connection was disconnected at time of send
AuthenticationExceptionAn authentication exception occured while logging on.
NotEntitledExceptionAn entitlement error occured on this topic.
BadFilterExceptionThe specified filter was invalid.
BadRegexTopicExceptionThe specified regex topic was invalid.
SubscriptionAlreadyExistsExceptionThe specified subscription ID already exists.

◆ unsubscribe() [1/2]

void AMPS.Client.Client.unsubscribe ( )
inline

Remove all of the client's subscriptions from AMPS.

Exceptions
DisconnectedExceptionThe client was disconnected at the time of execution

◆ unsubscribe() [2/2]

void AMPS.Client.Client.unsubscribe ( CommandId  subscriptionId)
inline

Remove a subscription from AMPS.

Parameters
subscriptionIdThe subscription identifier to remove
Exceptions
DisconnectedExceptionThe client was disconnected at the time of execution

Property Documentation

◆ AckBatchSize

int AMPS.Client.Client.AckBatchSize
getset

The ACK batch size controls how many successful ACKs (which are sow_delete messages) are batched together before sending to the server.When combined with the "max_backlog" and MaxPerSubscriptionBacklog server configuration parameter, greater network efficiency can be achieved when using message queues.Setting this parameter causes calls to "ack" and successful auto-acks to be batched; unsuccessful/cancel acks are sent immediately.

◆ AutoAck

bool AMPS.Client.Client.AutoAck
getset

The AutoAck property enables or disables auto-acking. When auto-acking is enabled any successful return from a message handler function will result in an ACK (sow_delete) message sent to the server. Any thrown exception will result in a "cancel" ACK sent to the server.

Event Documentation

◆ ConnectionStateChanged

EventHandler<ConnectionStateChangedEventArgs> AMPS.Client.Client.ConnectionStateChanged

Represents the method to be called when the connection state for this client changes. Notice that this event is raised as soon as the client detects the change of state. This means that, when the event is raised because the client is connected, the client has not yet logged on or completed any recovery (such as replaying the publish store, re-entering subscriptions,and so on). The event handler should not issue commands on the client while recovery is in progress.


The documentation for this class was generated from the following file: