C# Class Opc.Ua.Server.SamplingGroup

An object which periodically reads the items and updates the cache.
Inheritance: IDisposable
显示文件 Open project: OPCFoundation/UA-.NET Class Usage Examples

Public Methods

Method Description
ApplyChanges ( ) : bool

Updates the group by apply any pending changes.

Dispose ( ) : void

Frees any unmanaged resources.

ModifyMonitoring ( OperationContext context, ISampledDataChangeMonitoredItem monitoredItem ) : bool

Checks if the monitored item can still be handled by the group.

The ApplyChanges() method must be called to actually stop sampling the item.

SamplingGroup ( IServerInternal server, INodeManager nodeManager, List samplingRates, OperationContext context, double samplingInterval ) : System

Creates a new instance of a sampling group.

Shutdown ( ) : void

Stops the sampling thread.

StartMonitoring ( OperationContext context, ISampledDataChangeMonitoredItem monitoredItem ) : bool

Checks if the monitored item can be handled by the group.

The ApplyChanges() method must be called to actually start sampling the item.

Startup ( ) : void

Starts the sampling thread which periodically reads the items in the group.

StopMonitoring ( ISampledDataChangeMonitoredItem monitoredItem ) : bool

Stops monitoring the item.

Protected Methods

Method Description
Dispose ( bool disposing ) : void

An overrideable version of the Dispose.

Private Methods

Method Description
AdjustSamplingInterval ( double samplingInterval ) : double

Ensures the requested sampling interval lines up with one of the supported sampling rates.

DoSample ( object state ) : void

Samples the values of the items.

MeetsGroupCriteria ( OperationContext context, ISampledDataChangeMonitoredItem monitoredItem ) : bool

Checks if the item meets the group's criteria.

SampleMonitoredItems ( object data ) : void

Periodically checks if the sessions have timed out.

Method Details

ApplyChanges() public method

Updates the group by apply any pending changes.
public ApplyChanges ( ) : bool
return bool

Dispose() public method

Frees any unmanaged resources.
public Dispose ( ) : void
return void

Dispose() protected method

An overrideable version of the Dispose.
protected Dispose ( bool disposing ) : void
disposing bool
return void

ModifyMonitoring() public method

Checks if the monitored item can still be handled by the group.
The ApplyChanges() method must be called to actually stop sampling the item.
public ModifyMonitoring ( OperationContext context, ISampledDataChangeMonitoredItem monitoredItem ) : bool
context OperationContext
monitoredItem ISampledDataChangeMonitoredItem
return bool

SamplingGroup() public method

Creates a new instance of a sampling group.
public SamplingGroup ( IServerInternal server, INodeManager nodeManager, List samplingRates, OperationContext context, double samplingInterval ) : System
server IServerInternal
nodeManager INodeManager
samplingRates List
context OperationContext
samplingInterval double
return System

Shutdown() public method

Stops the sampling thread.
public Shutdown ( ) : void
return void

StartMonitoring() public method

Checks if the monitored item can be handled by the group.
The ApplyChanges() method must be called to actually start sampling the item.
public StartMonitoring ( OperationContext context, ISampledDataChangeMonitoredItem monitoredItem ) : bool
context OperationContext
monitoredItem ISampledDataChangeMonitoredItem
return bool

Startup() public method

Starts the sampling thread which periodically reads the items in the group.
public Startup ( ) : void
return void

StopMonitoring() public method

Stops monitoring the item.
public StopMonitoring ( ISampledDataChangeMonitoredItem monitoredItem ) : bool
monitoredItem ISampledDataChangeMonitoredItem
return bool