PreEmptive Analytics .NET API  1.3
 All Classes Namespaces Functions Variables Enumerations Enumerator Properties Events
Public Member Functions | List of all members
PreEmptive.Analytics.Common.OfflineStorageThread Class Reference

Class that manages the offline storage of messages. More...

Inherits PreEmptive.Analytics.Common.MessageQueueProcessor, and PreEmptive.Analytics.Common.IQueuePersister.

Public Member Functions

 OfflineStorageThread (IOfflineDataStore offlineDataStore, IFlowController flowController, IQueueTransmitter transmitterThread, IAttributeLimiter attributeLimiter, ILogger logger, IAsyncProvider asyncprovider)
 Constructor for OfflineStorageThread. More...
 
override void ProcessBatch (MessageBatch batch)
 Handles the transmission of a MessageBatch. More...
 
override MessageBatch GetMessageBatch ()
 Retrieves a saved MessageBatch. More...
 
void SaveDataOffline (MessageBatch batch)
 Stores a MessageBatch for later transmission. More...
 
- Public Member Functions inherited from PreEmptive.Analytics.Common.MessageQueueProcessor
void ProcessQueue ()
 Signals that the queue processor should immediately stop waiting and process the queue If the queue is in the middle of being processed, then it will be processed once more afterwards with no delay If the queue is not yet running, it is processed on the current thread(ie, it blocks) More...
 
void ProcessQueueBatches ()
 Creates and sends a message batch based on what messages have been queued. More...
 
virtual void Start ()
 Begins the automatic processing of the message queue. (not blocking, creates it's own thread) More...
 
void Stop ()
 Halts the automatic processing of the message queue. More...
 
void ProcessQueueNow ()
 Processes the queue if the message queue processor is currently running. More...
 

Additional Inherited Members

- Protected Member Functions inherited from PreEmptive.Analytics.Common.MessageQueueProcessor
 MessageQueueProcessor (IFlowController flowController, ILogger logger, IAsyncProvider asyncprovider)
 Constructor for the MessageQueueProcessor. More...
 
- Protected Attributes inherited from PreEmptive.Analytics.Common.MessageQueueProcessor
IFlowController flowController
 IFlowController that determines the behavior of the MessageQueueProcessor. More...
 
ILogger logger
 The Logger instance available for debug and error messages More...
 
IAsyncProvider AsyncProvider
 The asynchronous mechanism provider More...
 
- Properties inherited from PreEmptive.Analytics.Common.MessageQueueProcessor
bool Running [get, set]
 If the MessageQueueProcessor is currently running. More...
 
- Properties inherited from PreEmptive.Analytics.Common.IQueueProcessor
bool Running [get, set]
 If the MessageQueueProcessor is currently running. More...
 

Detailed Description

Class that manages the offline storage of messages.

Constructor & Destructor Documentation

PreEmptive.Analytics.Common.OfflineStorageThread.OfflineStorageThread ( IOfflineDataStore  offlineDataStore,
IFlowController  flowController,
IQueueTransmitter  transmitterThread,
IAttributeLimiter  attributeLimiter,
ILogger  logger,
IAsyncProvider  asyncprovider 
)

Constructor for OfflineStorageThread.

Parameters
offlineDataStoreInterface that defines how offline messages should be stored.
flowControllerInterface that defines the behaior of the message queue.
transmitterThreadTransmitterThread object that handles the sending of messages.
attributeLimiterThe field size limits of the upstream server
loggerAn ILogger instance for reporting information about the offline storage thread.
asyncproviderThe provider of the asynchronous execution functionality

Member Function Documentation

override MessageBatch PreEmptive.Analytics.Common.OfflineStorageThread.GetMessageBatch ( )
virtual

Retrieves a saved MessageBatch.

Returns
The retrieved MessageBatch.

Reimplemented from PreEmptive.Analytics.Common.MessageQueueProcessor.

override void PreEmptive.Analytics.Common.OfflineStorageThread.ProcessBatch ( MessageBatch  batch)
virtual

Handles the transmission of a MessageBatch.

Parameters
batchThe MessageBatch object to process.

Reimplemented from PreEmptive.Analytics.Common.MessageQueueProcessor.

void PreEmptive.Analytics.Common.OfflineStorageThread.SaveDataOffline ( MessageBatch  batch)

Stores a MessageBatch for later transmission.

Parameters
batchThe MessageBatch object to save.

Implements PreEmptive.Analytics.Common.IQueuePersister.


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