C# 클래스 PhasorProtocolAdapters.PhasorDataConcentratorBase

상속: GSF.TimeSeries.Adapters.ActionAdapterBase
파일 보기 프로젝트 열기: GridProtectionAlliance/gsf

공개 메소드들

메소드 설명
GetHashCode ( ) : int

Returns the hash code for this instance.

Initialize ( ) : void

Initializes PhasorDataConcentratorBase.

QueueMeasurementsForProcessing ( IEnumerable measurements ) : void

Queues a collection of measurements for processing.

ResetLatencyCounters ( ) : void

Resets counters related to latency calculations.

Start ( ) : void

Starts the PhasorDataConcentratorBase, if it is not already running.

Stop ( ) : void

Stops the PhasorDataConcentratorBase.

보호된 메소드들

메소드 설명
AssignMeasurementToFrame ( IFrame frame, IMeasurement measurement ) : void

Assign IMeasurement to its IFrame.

In simple concentration scenarios all you need to do is assign a measurement to its frame based on time. In the case of a phasor data concentrator you need to assign a measurement to its particular location in its IDataFrame - so this method overrides the default behavior in order to accomplish this task.

CacheConfigurationFrame ( IConfigurationFrame configurationFrame, string name ) : void

Serialize configuration frame to cache folder for later use (if needed).

Derived concentrators can call this method to manually serialize their protocol specific configuration frames. Note that after initial call to CreateNewConfigurationFrame this method will be call automatically.

CreateNewConfigurationFrame ( GSF.PhasorProtocols.Anonymous.ConfigurationFrame baseConfigurationFrame ) : IConfigurationFrame

Creates a new protocol specific IConfigurationFrame based on provided protocol independent baseConfigurationFrame.

Derived classes should notify consumers of change in configuration if system is active when new configuration frame is created if outgoing protocol allows such a notification.

DeviceCommandHandler ( System.Guid clientID, string connectionID, byte commandBuffer, int length ) : void

Handles incoming commands from devices connected over the command channel.

This method should be overridden by derived classes in order to handle incoming commands, specifically handling requests for configuration frames.

Dispose ( bool disposing ) : void

Releases the unmanaged resources used by the PhasorDataConcentratorBase object and optionally releases the managed resources.

GetConnectionID ( IServer server, System.Guid clientID ) : string

Gets connection ID (i.e., IP:Port) for specified clientID.

PhasorDataConcentratorBase ( ) : System

Creates a new PhasorDataConcentratorBase.

PublishFrame ( IFrame frame, int index ) : void

Publish IFrame of time-aligned collection of IMeasurement values that arrived within the concentrator's defined ConcentratorBase.LagTime.

비공개 메소드들

메소드 설명
DeviceCommandHandlerProc ( object state ) : void
EstablishPublicationChannel ( ) : void
GeneratePhasorLabel ( string phasorLabel, char phase, PhasorType type ) : string
LookupHostName ( object state ) : void
ReinitializeSocketLayer ( object state ) : void
ResetLifetimeCounters ( ) : void
ResetMeasurementsPerSecondCounters ( ) : void
StartDataChannel ( ) : void
StopDataChannel ( ) : void
UpdateConfiguration ( ) : void
UpdateMeasurementsPerSecond ( int measurementCount ) : void
m_commandChannelRestartTimer_Elapsed ( object sender, System.Timers.ElapsedEventArgs e ) : void
m_commandChannel_ClientConnected ( object sender, EventArgs e ) : void
m_commandChannel_ClientConnectingException ( object sender, EventArgs e ) : void
m_commandChannel_ClientDisconnected ( object sender, EventArgs e ) : void
m_commandChannel_ReceiveClientDataComplete ( object sender, EventArgs e ) : void
m_commandChannel_SendClientDataException ( object sender, Exception>.EventArgs e ) : void
m_commandChannel_ServerStarted ( object sender, EventArgs e ) : void
m_commandChannel_ServerStopped ( object sender, EventArgs e ) : void
m_dataChannel_ClientConnectingException ( object sender, EventArgs e ) : void
m_dataChannel_ReceiveClientDataComplete ( object sender, EventArgs e ) : void
m_dataChannel_SendClientDataException ( object sender, Exception>.EventArgs e ) : void
m_dataChannel_ServerStarted ( object sender, EventArgs e ) : void
m_dataChannel_ServerStopped ( object sender, EventArgs e ) : void

메소드 상세

AssignMeasurementToFrame() 보호된 메소드

Assign IMeasurement to its IFrame.
In simple concentration scenarios all you need to do is assign a measurement to its frame based on time. In the case of a phasor data concentrator you need to assign a measurement to its particular location in its IDataFrame - so this method overrides the default behavior in order to accomplish this task.
protected AssignMeasurementToFrame ( IFrame frame, IMeasurement measurement ) : void
frame IFrame to assign to.
measurement IMeasurement to assign to .
리턴 void

CacheConfigurationFrame() 보호된 메소드

Serialize configuration frame to cache folder for later use (if needed).
Derived concentrators can call this method to manually serialize their protocol specific configuration frames. Note that after initial call to CreateNewConfigurationFrame this method will be call automatically.
protected CacheConfigurationFrame ( IConfigurationFrame configurationFrame, string name ) : void
configurationFrame IConfigurationFrame New to cache.
name string Name to use when caching the .
리턴 void

CreateNewConfigurationFrame() 보호된 추상적인 메소드

Creates a new protocol specific IConfigurationFrame based on provided protocol independent baseConfigurationFrame.
Derived classes should notify consumers of change in configuration if system is active when new configuration frame is created if outgoing protocol allows such a notification.
protected abstract CreateNewConfigurationFrame ( GSF.PhasorProtocols.Anonymous.ConfigurationFrame baseConfigurationFrame ) : IConfigurationFrame
baseConfigurationFrame GSF.PhasorProtocols.Anonymous.ConfigurationFrame Protocol independent .
리턴 IConfigurationFrame

DeviceCommandHandler() 보호된 메소드

Handles incoming commands from devices connected over the command channel.
This method should be overridden by derived classes in order to handle incoming commands, specifically handling requests for configuration frames.
protected DeviceCommandHandler ( System.Guid clientID, string connectionID, byte commandBuffer, int length ) : void
clientID System.Guid Guid of client that sent the command.
connectionID string Remote client connection identification (i.e., IP:Port).
commandBuffer byte Data buffer received from connected client device.
length int Valid length of data within the buffer.
리턴 void

Dispose() 보호된 메소드

Releases the unmanaged resources used by the PhasorDataConcentratorBase object and optionally releases the managed resources.
protected Dispose ( bool disposing ) : void
disposing bool true to release both managed and unmanaged resources; false to release only unmanaged resources.
리턴 void

GetConnectionID() 보호된 메소드

Gets connection ID (i.e., IP:Port) for specified clientID.
protected GetConnectionID ( IServer server, System.Guid clientID ) : string
server IServer Server connection of associated .
clientID System.Guid Guid of client for ID lookup.
리턴 string

GetHashCode() 공개 메소드

Returns the hash code for this instance.
public GetHashCode ( ) : int
리턴 int

Initialize() 공개 메소드

Initializes PhasorDataConcentratorBase.
public Initialize ( ) : void
리턴 void

PhasorDataConcentratorBase() 보호된 메소드

Creates a new PhasorDataConcentratorBase.
protected PhasorDataConcentratorBase ( ) : System
리턴 System

PublishFrame() 보호된 메소드

Publish IFrame of time-aligned collection of IMeasurement values that arrived within the concentrator's defined ConcentratorBase.LagTime.
protected PublishFrame ( IFrame frame, int index ) : void
frame IFrame of measurements with the same timestamp that arrived within that are ready for processing.
index int Index of within a second ranging from zero to - 1.
리턴 void

QueueMeasurementsForProcessing() 공개 메소드

Queues a collection of measurements for processing.
public QueueMeasurementsForProcessing ( IEnumerable measurements ) : void
measurements IEnumerable Collection of measurements to queue for processing.
리턴 void

ResetLatencyCounters() 공개 메소드

Resets counters related to latency calculations.
public ResetLatencyCounters ( ) : void
리턴 void

Start() 공개 메소드

Starts the PhasorDataConcentratorBase, if it is not already running.
public Start ( ) : void
리턴 void

Stop() 공개 메소드

Stops the PhasorDataConcentratorBase.
public Stop ( ) : void
리턴 void