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

Interface for defining a flow controller. More...

Inherited by PreEmptive.Analytics.Common.FlowController.

Public Member Functions

bool BatchHasExpired (MessageBatch batch)
 Determines if a Batch has expired and is eligible for deletion/dropping More...
 
bool CanStartClient ()
 Determines if the CoreClient instance should actually start queueing of messages More...
 
int GetInterval (int numberOfMessages)
 Calculates the time to wait until the next automatic batching and sending of messages. More...
 
int MessagesToDrop (int currentMessageCount)
 The number of messages to drop when QueueSize has been exceeded. More...
 
bool OkToTransmit ()
 Determines if messages sending is currently permitted. More...
 
bool ShouldSendNow (int messageCount)
 Determines if the queue should awaken the transmitter and start sending More...
 
void OnSend (bool sendSucceeded)
 Updates the flow controller based on the success or failure of a message transmission. More...
 
IFlowController Copy ()
 Creates a deep copy of the FlowController. More...
 

Properties

bool SupportOfflineStorage [get]
 Is offline storage of messages permitted. More...
 
bool SendDisabled [get, set]
 Is the transmission of messages temporarily disabled. More...
 
int MaximumBatchSize [get]
 The maximum size a message batch can be, in bytes. If a batch exceeds this size, it is split into multiple batches If a single message exceeds this size, it will be discarded if transmission fails at any time More...
 

Detailed Description

Interface for defining a flow controller.

Member Function Documentation

bool PreEmptive.Analytics.Common.IFlowController.BatchHasExpired ( MessageBatch  batch)

Determines if a Batch has expired and is eligible for deletion/dropping

Parameters
batchThe batch to check
Returns
True if the batch should be deleted. False if it should be kept and cached

Implemented in PreEmptive.Analytics.Common.FlowController.

bool PreEmptive.Analytics.Common.IFlowController.CanStartClient ( )

Determines if the CoreClient instance should actually start queueing of messages

Returns
True if it should start, false if not

Implemented in PreEmptive.Analytics.Common.FlowController.

IFlowController PreEmptive.Analytics.Common.IFlowController.Copy ( )

Creates a deep copy of the FlowController.

Returns
A new instance of IFlowController.

Implemented in PreEmptive.Analytics.Common.FlowController.

int PreEmptive.Analytics.Common.IFlowController.GetInterval ( int  numberOfMessages)

Calculates the time to wait until the next automatic batching and sending of messages.

Parameters
numberOfMessagesA count of the current number of queued messages.
Returns
The time interval to wait in milliseconds.

Implemented in PreEmptive.Analytics.Common.FlowController.

int PreEmptive.Analytics.Common.IFlowController.MessagesToDrop ( int  currentMessageCount)

The number of messages to drop when QueueSize has been exceeded.

Parameters
currentMessageCountThe current number of messages.
Returns
The number of messages to drop.

Implemented in PreEmptive.Analytics.Common.FlowController.

bool PreEmptive.Analytics.Common.IFlowController.OkToTransmit ( )

Determines if messages sending is currently permitted.

Returns

Implemented in PreEmptive.Analytics.Common.FlowController.

void PreEmptive.Analytics.Common.IFlowController.OnSend ( bool  sendSucceeded)

Updates the flow controller based on the success or failure of a message transmission.

Parameters
sendSucceededThe status of the message transmission.

Implemented in PreEmptive.Analytics.Common.FlowController.

bool PreEmptive.Analytics.Common.IFlowController.ShouldSendNow ( int  messageCount)

Determines if the queue should awaken the transmitter and start sending

Parameters
messageCount
Returns

Implemented in PreEmptive.Analytics.Common.FlowController.

Property Documentation

int PreEmptive.Analytics.Common.IFlowController.MaximumBatchSize
get

The maximum size a message batch can be, in bytes. If a batch exceeds this size, it is split into multiple batches If a single message exceeds this size, it will be discarded if transmission fails at any time

bool PreEmptive.Analytics.Common.IFlowController.SendDisabled
getset

Is the transmission of messages temporarily disabled.

bool PreEmptive.Analytics.Common.IFlowController.SupportOfflineStorage
get

Is offline storage of messages permitted.


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