AFTimeBasedEventSource Class
- Last UpdatedNov 18, 2025
- 3 minute read
- PI System
- AF SDK 2024 R2
- Developer
Inheritance Hierarchy
OSIsoft.AF.DataAFTimeBasedEventSource
Namespace: OSIsoft.AF.Data
Assembly: OSIsoft.AFSDK (in OSIsoft.AFSDK.dll) Version: 3.1.1.1182
Syntax
public class AFTimeBasedEventSource : IDisposable
Public Class AFTimeBasedEventSource Implements IDisposable Dim instance As AFTimeBasedEventSource
public ref class AFTimeBasedEventSource : IDisposable
type AFTimeBasedEventSource = class interface IDisposable end
The AFTimeBasedEventSource type exposes the following members.
Constructors
| Name | Description | |
|---|---|---|
| AFTimeBasedEventSource |
Creates a new event source
|
Methods
| Name | Description | |
|---|---|---|
| Dispose |
Cleans up resources
| |
| Equals | Determines whether the specified object is equal to the current object. (Inherited from Object.) | |
| GetHashCode | Serves as the default hash function. (Inherited from Object.) | |
| GetType | Gets the Type of the current instance. (Inherited from Object.) | |
| ToString | Returns a string that represents the current object. (Inherited from Object.) |
Remarks
Data Reference needs to provide a static method CreateDataPipe that returns an AFTimeBasedEventSource object. AFTimeBasedEventSource has the following virtual methods that the implementor can override: Dispose(bool), GetDataFromSource and ValidateStream. GetDataFromSource in the base class would enumerate through all the signup attributes and retrieve data into its cache. Implementor can override this method if there are more efficient way to retrieve data (like a list bulk call). After retrieved data for the AFAttributes, the GetDataFromSource method will need to call the protected PublishToCache method to save the result into AFTimeBasedEventSource's data cache. ValidateStream in the base class will check if the passed AFAttribute supports RecordedValues.
User of the AFTimeBasedEventSource can also adjust the data retrieval time span. Default time span is two minutes.