Click or drag to resize
OSIsoft, LLC

AFCaseSearch Constructor (AFDatabase, String, AFEventFrameSearchMode, AFTime, String)

Creates an instance of an AFCaseSearch to search for AFCase objects using the specified AFEventFrameSearchMode, time and optional search query string.

Namespace:  OSIsoft.AF.Search
Assembly:  OSIsoft.AFSDK (in OSIsoft.AFSDK.dll) Version: 2.10.8.440
Syntax
public AFCaseSearch(
	AFDatabase database,
	string name,
	AFEventFrameSearchMode searchMode,
	AFTime startTime,
	string query = null
)

Parameters

database
Type: OSIsoft.AFAFDatabase
The AFDatabase to be searched by the query. This parameter will initialize the Database property.
name
Type: SystemString
The SearchName associated with the created search object. This is only informational and does not affect the searches.
searchMode
Type: OSIsoft.AF.EventFrameAFEventFrameSearchMode
The AFEventFrameSearchMode to be converted into a search query which indicates the direction in time from the StartTime or EndTime to proceed when returning cases.
startTime
Type: OSIsoft.AF.TimeAFTime
The starting time to be used in the generated search query. The search may compare against either the StartTime or EndTime of the case based on the searchMode parameter.
query (Optional)
Type: SystemString
The optional search query string. If specified, this will add additional search filters to the generated search query in addition to the ones for the specified mode and times. Strings will be interpreted with the Parse(String, AFTime, IFormatProvider) method so that relative formats with intervals ("*", "T+3h", etc.) are also supported. Relative time intervals are based on the database's QueryDate.
Remarks
This constructor will create a search query based upon the specified searchMode and time. The times in the query string will have the correct operators specified for the Start and/or End filters. The optional query will be used to add additional search filters to the search query. These parameters will be used to create tokens and initialize the TokenCollection property.
Version Information

AFSDK

Supported in: 2.10.5, 2.10, 2.9.5, 2.9, 2.8.5
See Also
Enabling Operational Intelligence