Click or drag to resize

DetachedDeviceLink Class

Defines helper functions for managing connection string based parent / child device linkage used by concentrator style device connections whose child devices have been "detached" from the data model, i.e., child device records with a null ParentID so that the children appear as standalone devices while stream parsing still maps data to them through the parent connection.
Inheritance Hierarchy
SystemObject
  GSF.PhasorProtocolsDetachedDeviceLink

Namespace: GSF.PhasorProtocols
Assembly: GSF.PhasorProtocols (in GSF.PhasorProtocols.dll) Version: 2.4.318-beta
Syntax
public static class DetachedDeviceLink
View Source

The DetachedDeviceLink type exposes the following members.

Methods
 NameDescription
Public methodStatic memberBuildChildConnectionString Builds a connection string for a detached child device that links the child to its parent concentrator device.
Public methodStatic memberClearChildLink Removes any detached child linkage keys, i.e., ParentIDKey and StationNameKey, from the specified connection string.
Public methodStatic memberGetDatabaseID Gets the device database ID, i.e., the DatabaseIDKey value, defined in the specified connection string, if any.
Public methodStatic memberGetEffectiveParentID Gets the effective parent device database ID for a device, i.e., the defined database parentID field value, when not null, falling back on any numeric ParentIDKey value defined in the device connectionString.
Public methodStatic memberGetParentIdentifier Gets the raw parent identifier, i.e., the ParentIDKey value, defined in the specified connection string, if any.
Public methodStatic memberGetStationName Gets the station name, i.e., the StationNameKey value, defined in the specified connection string, if any.
Public methodStatic memberHasDetachedChildren Gets flag that determines if the specified connection string identifies a parent concentrator device with detached, i.e., standalone modeled, child devices.
Public methodStatic memberIsDetachedChild Gets flag that determines if the specified connection string identifies a detached child device, i.e., connection string defines a ParentIDKey value.
Public methodStatic memberSetDetachedChildren Adds or removes the detached children flag, i.e., DetachedChildrenKey along with its companion DatabaseIDKey stamp, on the specified parent concentrator device connection string.
Public methodStatic memberTryParseParentID Attempts to parse the numeric parent device database ID defined in the specified connection string.
Top
Fields
 NameDescription
Public fieldStatic memberDatabaseIDKey Connection string key, applied to a parent concentrator device, whose value is the database ID of the parent device itself. Allows the runtime to match detached children, whose ParentIDKey values are database IDs, without requiring database access.
Public fieldStatic memberDetachedChildrenKey Connection string key, applied to a parent concentrator device, that flags the connection as having detached, i.e., standalone modeled, child devices.
Public fieldStatic memberParentIDKey Connection string key, applied to a detached child device, whose value is the database ID of its parent concentrator device. Acts as a proxy for the database ParentID field.
Public fieldStatic memberStationNameKey Connection string key, applied to a detached child device, whose value is the station name, i.e., Device.Name, of the child device. Used to preserve label based cell mapping since detached children are not exposed through the runtime input stream devices table.
Top
Remarks
A detached child device carries parentID=<parent Device.ID> (and typically stationName=<Device.Name>) in its connection string as a proxy for the database ParentID field. The parent concentrator device carries detachedChildren=true along with databaseID=<its own Device.ID> so the runtime can match children to the parent without requiring database access, e.g., when operating from cached configuration.
See Also