AMPS C# Client  5.3.5.0
AMPS C# Client for .NET
AMPS.Client.DefaultBookmarkStore Class Reference

A no-op default implementation of the BookmarkStore interface that does nothing. More...

+ Inheritance diagram for AMPS.Client.DefaultBookmarkStore:

Public Member Functions

 DefaultBookmarkStore ()
 Initializes a new instance of the DefaultBookmarkStore class. More...
 
void Dispose ()
 Disposes of any resources held by the bookmark store. More...
 
long log (Message message)
 Logs the bookmark associated with the given message. More...
 
void discard (Field topic, long bookmarkSequenceNumber)
 Discards a bookmark associated with the specified topic and bookmark sequence number. More...
 
void discard (Message message)
 Discards the bookmark associated with the given message. More...
 
Field getMostRecent (Field topic, bool useList)
 Retrieves the most recent bookmark for the specified topic. More...
 
bool isDiscarded (Message message)
 Determines whether the message should be discarded. More...
 
void purge (Field subId)
 Purges the bookmark associated with the specified subscription ID. More...
 
void purge ()
 Purges all bookmarks stored in memory. More...
 
void persisted (Field subId, BookmarkField bookmark)
 Marks a bookmark as persisted for the specified subscription ID. More...
 
void persisted (Field subId, long bookmark)
 Marks a bookmark as persisted for the specified subscription ID. More...
 
long getOldestBookmarkSeq (Field subId)
 Retrieves the oldest bookmark sequence number associated with the specified subscription ID. More...
 
void setResizeHandler (BookmarkStoreResizeHandler handler)
 Sets the resize handler for the bookmark store. More...
 
void setServerVersion (int version)
 Sets the version of the server. More...
 

Detailed Description

A no-op default implementation of the BookmarkStore interface that does nothing.

Constructor & Destructor Documentation

◆ DefaultBookmarkStore()

AMPS.Client.DefaultBookmarkStore.DefaultBookmarkStore ( )
inline

Initializes a new instance of the DefaultBookmarkStore class.

Member Function Documentation

◆ discard() [1/2]

void AMPS.Client.DefaultBookmarkStore.discard ( Field  topic,
long  bookmarkSequenceNumber 
)
inline

Discards a bookmark associated with the specified topic and bookmark sequence number.

Parameters
topicThe topic associated with the bookmark.
bookmarkSequenceNumberThe sequence number of the bookmark to discard.

Implements AMPS.Client.BookmarkStore.

◆ discard() [2/2]

void AMPS.Client.DefaultBookmarkStore.discard ( Message  message)
inline

Discards the bookmark associated with the given message.

Parameters
messageThe message containing the bookmark to discard.

Implements AMPS.Client.BookmarkStore.

◆ Dispose()

void AMPS.Client.DefaultBookmarkStore.Dispose ( )
inline

Disposes of any resources held by the bookmark store.

◆ getMostRecent()

Field AMPS.Client.DefaultBookmarkStore.getMostRecent ( Field  topic,
bool  useList 
)
inline

Retrieves the most recent bookmark for the specified topic.

Parameters
topicThe topic for which to retrieve the most recent bookmark.
useListSpecifies whether to use the bookmark list.
Returns
The most recent bookmark for the specified topic.

Implements AMPS.Client.BookmarkStore.

◆ getOldestBookmarkSeq()

long AMPS.Client.DefaultBookmarkStore.getOldestBookmarkSeq ( Field  subId)
inline

Retrieves the oldest bookmark sequence number associated with the specified subscription ID.

Parameters
subIdThe subscription ID.
Returns
The oldest bookmark sequence number.</returns

Implements AMPS.Client.BookmarkStore.

◆ isDiscarded()

bool AMPS.Client.DefaultBookmarkStore.isDiscarded ( Message  message)
inline

Determines whether the message should be discarded.

Parameters
messageThe message to check.
Returns
Always returns false.

Implements AMPS.Client.BookmarkStore.

◆ log()

long AMPS.Client.DefaultBookmarkStore.log ( Message  message)
inline

Logs the bookmark associated with the given message.

Parameters
messageThe message containing the bookmark.
Returns
Returns 0.

Implements AMPS.Client.BookmarkStore.

◆ persisted() [1/2]

void AMPS.Client.DefaultBookmarkStore.persisted ( Field  subId,
BookmarkField  bookmark 
)
inline

Marks a bookmark as persisted for the specified subscription ID.

Parameters
subIdThe subscription ID.
bookmarkThe bookmark to mark as persisted.

Implements AMPS.Client.BookmarkStore.

◆ persisted() [2/2]

void AMPS.Client.DefaultBookmarkStore.persisted ( Field  subId,
long  bookmark 
)
inline

Marks a bookmark as persisted for the specified subscription ID.

Parameters
subIdThe subscription ID.
bookmarkThe bookmark to mark as persisted.

Implements AMPS.Client.BookmarkStore.

◆ purge() [1/2]

void AMPS.Client.DefaultBookmarkStore.purge ( )
inline

Purges all bookmarks stored in memory.

Implements AMPS.Client.BookmarkStore.

◆ purge() [2/2]

void AMPS.Client.DefaultBookmarkStore.purge ( Field  subId)
inline

Purges the bookmark associated with the specified subscription ID.

Parameters
subIdThe subscription ID whose bookmark to purge.

Implements AMPS.Client.BookmarkStore.

◆ setResizeHandler()

void AMPS.Client.DefaultBookmarkStore.setResizeHandler ( BookmarkStoreResizeHandler  handler)
inline

Sets the resize handler for the bookmark store.

Parameters
handlerThe resize handler to set.

Implements AMPS.Client.BookmarkStore.

◆ setServerVersion()

void AMPS.Client.DefaultBookmarkStore.setServerVersion ( int  version)
inline

Sets the version of the server.

Implements AMPS.Client.BookmarkStore.


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