OPC Historian .NET Server Toolkit Reference
PlaybackProcessed Method (IAppPlugin)

An identifier created by the client and passed to the server in this call. The server shall return this identifier along with the results of this call.
The beginning of the history period to be read.
The end of the history period to be read.
Time between return values.
The number of ResampleIntervals in an update.
The interval to send data for updates.
The list of processed server items to be retrieved.
The list of processed values to be returned.
Place to return a Server generated ID to be used in case the operation needs to be canceled.
Array of HRESULTs indicating whether the corresponding server handle was valid.
Professional Edition only.
This method initially retrieves data from the start time to the end time. After the initial response it periodically (every updateInterval) responds with an updateDuration amount of data. The time of the last value returned in the initial response is used as the start time for the first update. After that, the time of the last value returned in an update is used as the start time for the next update. The results are returned via the client's OnPlayback method. The domain of the initial request is defined by startTime, endTime, and resampleInterval. All three must be specified. endTime must be greater than startTime. The resampleInterval determines how many subintervals the complete interval is divided into. The specified function is calculated at each subinterval beginning with htStartTime and selecting the data within the next resampleInterval, a value will be calculated according to the aggregate at each subinterval. For MinimumActualTime and MaximumActualTime used with aggregate values, if more than one instance of the value exists within a time range, which instance (time stamp) of the value is returned is server dependent. In any case, the server may set the OPCHDA_EXTRADATA quality flag to let the caller know that there are other timestamps with that value. A resampleInterval of 0 is illegal resulting in a return status of E_INVALIDARG. If only an initial set of data is desired, the dwNumIntervals should be set to 0 The request must still be cancelled. The updateInterval can not be less than the resampleInterval. The order of the data returned will match the order of the ItemIDs in the request.
Syntax
'Usage
 
Dim instance As IAppPlugin
Dim transactionID As Integer
Dim startTime As Date
Dim endTime As Date
Dim resampleInterval As TimeSpan
Dim numIntervals As Integer
Dim updateInterval As TimeSpan
Dim serverHandles() As Integer
Dim aggregate() As Integer
Dim cancelID As Integer
Dim errors As Integer()
Dim value As Integer
 
value = instance.PlaybackProcessed(transactionID, startTime, endTime, resampleInterval, numIntervals, updateInterval, serverHandles, aggregate, cancelID, errors)
int PlaybackProcessed( 
   int transactionID,
   DateTime startTime,
   DateTime endTime,
   TimeSpan resampleInterval,
   int numIntervals,
   TimeSpan updateInterval,
   int[] serverHandles,
   int[] aggregate,
   out int cancelID,
   out int[] errors
)

Parameters

transactionID
An identifier created by the client and passed to the server in this call. The server shall return this identifier along with the results of this call.
startTime
The beginning of the history period to be read.
endTime
The end of the history period to be read.
resampleInterval
Time between return values.
numIntervals
The number of ResampleIntervals in an update.
updateInterval
The interval to send data for updates.
serverHandles
The list of processed server items to be retrieved.
aggregate
The list of processed values to be returned.
cancelID
Place to return a Server generated ID to be used in case the operation needs to be canceled.
errors
Array of HRESULTs indicating whether the corresponding server handle was valid.

Return Value

HRESULTS success/error code.
Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also

Reference

IAppPlugin Interface
IAppPlugin Members

 

 


Copyright © 2004-2019 Advosol Inc. All rights reserved

Send Feedback