com::pcbsys::nirvana::client::nQueueTransactionReader Class Referenceabstract

Provides the basic interface for transactional queue operations, used by the synchronous and asynchronous transactional queue readers. More...

#include <nQueueTransactionReader.h>

Inheritance diagram for com::pcbsys::nirvana::client::nQueueTransactionReader:
com::pcbsys::nirvana::client::nQueueAsyncTransactionReader com::pcbsys::nirvana::client::nQueueSyncTransactionReader

Public Member Functions

virtual void commit ()=0
 Commits all received events so far. More...
 
virtual void commit (longlong eventId)=0
 Commits all events up to the event id specified. More...
 
virtual void rollback ()=0
 Rolls back all received events that have not been committed or rolled back previously. More...
 
virtual void rollback (longlong eventId)=0
 Rolls back all events up to the specified event id that have not been committed or rolled back previously. More...
 

Detailed Description

Provides the basic interface for transactional queue operations, used by the synchronous and asynchronous transactional queue readers.

Member Function Documentation

virtual void com::pcbsys::nirvana::client::nQueueTransactionReader::commit ( )
pure virtual

Commits all received events so far.

Exceptions
nSessionNotConnectedExceptionClient is not currently connected to the server
nSessionPausedExceptionThe session is currently paused
nIllegalStateExceptionThe operation could not complete because of a session/connection error
nRequestTimedOutExceptionThe server failed to respond with the specified timeout

Implemented in com::pcbsys::nirvana::client::nQueueSyncTransactionReader, and com::pcbsys::nirvana::client::nQueueAsyncTransactionReader.

virtual void com::pcbsys::nirvana::client::nQueueTransactionReader::commit ( longlong  eventId)
pure virtual

Commits all events up to the event id specified.

This means you can partially commit received events.

Parameters
eventIdEvent ID to commit to, inclusive
Exceptions
nSessionNotConnectedExceptionClient is not currently connected to the server
nSessionPausedExceptionThe session is currently paused
nIllegalStateExceptionThe operation could not complete because of a session/connection error
nRequestTimedOutExceptionThe server failed to respond with the specified timeout

Implemented in com::pcbsys::nirvana::client::nQueueSyncTransactionReader, and com::pcbsys::nirvana::client::nQueueAsyncTransactionReader.

virtual void com::pcbsys::nirvana::client::nQueueTransactionReader::rollback ( )
pure virtual

Rolls back all received events that have not been committed or rolled back previously.

These events are then pushed back onto the queue for redelivery.

Exceptions
nSessionNotConnectedExceptionClient is not currently connected to the server
nSessionPausedExceptionThe session is currently paused
nIllegalStateExceptionThe operation could not complete because of a session/connection error
nRequestTimedOutExceptionThe server failed to respond with the specified timeout

Implemented in com::pcbsys::nirvana::client::nQueueSyncTransactionReader, and com::pcbsys::nirvana::client::nQueueAsyncTransactionReader.

virtual void com::pcbsys::nirvana::client::nQueueTransactionReader::rollback ( longlong  eventId)
pure virtual

Rolls back all events up to the specified event id that have not been committed or rolled back previously.

These events are then pushed back onto the queue for redelivery.

Parameters
eventIdEvent Id to rollback to, inclusive
Exceptions
nSessionNotConnectedExceptionClient is not currently connected to the server
nSessionPausedExceptionThe session is currently paused
nIllegalStateExceptionThe operation could not complete because of a session/connection error
nRequestTimedOutExceptionThe server failed to respond with the specified timeout

Implemented in com::pcbsys::nirvana::client::nQueueSyncTransactionReader, and com::pcbsys::nirvana::client::nQueueAsyncTransactionReader.