C# Class ServerSentEvent4Net.ServerSentEvent

Inheritance: IServerSentEvent
Afficher le fichier Open project: erizet/ServerSentEvent4Net

Protected Properties

Свойство Type Description
_logger slf4net.ILogger
mClients List
mHeartbeatInterval int
mHeartbeatTimer System.Threading.Timer
mIdGenerator IMessageIdGenerator
mLock object
mMessageHistory IMessageHistory

Méthodes publiques

Méthode Description
AddSubscriber ( HttpRequestMessage request ) : HttpResponseMessage
Send ( string data ) : void
Send ( string data, string eventType ) : void
Send ( string data, string eventType, string messageId ) : void
ServerSentEvent ( IMessageHistory messageHistory, IMessageIdGenerator idGenerator, int heartbeatInterval ) : System
ServerSentEvent ( int noOfMessagesToRemember, bool generateMessageIds = false, int heartbeatInterval ) : System

Méthodes protégées

Méthode Description
AddClient ( Client client ) : void
CheckMessage ( Message msg ) : void
GetLastMessageId ( HttpContent content ) : string
OnStreamAvailable ( Stream stream, System content, System context ) : void
OnSubscriberAdded ( int subscriberCount ) : void
OnSubscriberRemoved ( int subscriberCount ) : void
SendAndRemoveDisconneced ( List clientsToSendTo, Message msg ) : void
SetupHeartbeat ( int heartbeatInterval ) : void

Private Methods

Méthode Description
Send ( Message msg ) : void
TimerCallback ( object state ) : void

Method Details

AddClient() protected méthode

protected AddClient ( Client client ) : void
client Client
Résultat void

AddSubscriber() public méthode

public AddSubscriber ( HttpRequestMessage request ) : HttpResponseMessage
request System.Net.Http.HttpRequestMessage
Résultat System.Net.Http.HttpResponseMessage

CheckMessage() protected méthode

protected CheckMessage ( Message msg ) : void
msg Message
Résultat void

GetLastMessageId() protected méthode

protected GetLastMessageId ( HttpContent content ) : string
content System.Net.Http.HttpContent
Résultat string

OnStreamAvailable() protected méthode

protected OnStreamAvailable ( Stream stream, System content, System context ) : void
stream Stream
content System
context System
Résultat void

OnSubscriberAdded() protected méthode

protected OnSubscriberAdded ( int subscriberCount ) : void
subscriberCount int
Résultat void

OnSubscriberRemoved() protected méthode

protected OnSubscriberRemoved ( int subscriberCount ) : void
subscriberCount int
Résultat void

Send() public méthode

public Send ( string data ) : void
data string
Résultat void

Send() public méthode

public Send ( string data, string eventType ) : void
data string
eventType string
Résultat void

Send() public méthode

public Send ( string data, string eventType, string messageId ) : void
data string
eventType string
messageId string
Résultat void

SendAndRemoveDisconneced() protected méthode

protected SendAndRemoveDisconneced ( List clientsToSendTo, Message msg ) : void
clientsToSendTo List
msg Message
Résultat void

ServerSentEvent() public méthode

public ServerSentEvent ( IMessageHistory messageHistory, IMessageIdGenerator idGenerator, int heartbeatInterval ) : System
messageHistory IMessageHistory
idGenerator IMessageIdGenerator
heartbeatInterval int
Résultat System

ServerSentEvent() public méthode

public ServerSentEvent ( int noOfMessagesToRemember, bool generateMessageIds = false, int heartbeatInterval ) : System
noOfMessagesToRemember int
generateMessageIds bool
heartbeatInterval int
Résultat System

SetupHeartbeat() protected méthode

protected SetupHeartbeat ( int heartbeatInterval ) : void
heartbeatInterval int
Résultat void

Property Details

_logger protected_oe static_oe property

protected static slf4net.ILogger _logger
Résultat slf4net.ILogger

mClients protected_oe property

protected List mClients
Résultat List

mHeartbeatInterval protected_oe property

protected int mHeartbeatInterval
Résultat int

mHeartbeatTimer protected_oe property

protected Timer,System.Threading mHeartbeatTimer
Résultat System.Threading.Timer

mIdGenerator protected_oe property

protected IMessageIdGenerator mIdGenerator
Résultat IMessageIdGenerator

mLock protected_oe property

protected object mLock
Résultat object

mMessageHistory protected_oe property

protected IMessageHistory mMessageHistory
Résultat IMessageHistory