Click or drag to resize
OSIsoft, LLC

PICollective Class

The PICollective object is used to provide the information and status about the PIServer collective.

Inheritance Hierarchy

Namespace:  OSIsoft.AF.PI
Assembly:  OSIsoft.AFSDK (in OSIsoft.AFSDK.dll) Version: 2.10.6.195
Syntax
[SerializableAttribute]
public sealed class PICollective : AFObject, 
	IAFChangedEvent, IEquatable<PICollective>

The PICollective type exposes the following members.

Properties
  NameDescription
Public propertyAllowWriteValues
Indicates whether values are allowed to be written to the currently active collective member.
Public propertyConnectedMemberType
Indicates the role of the currently connected collective member.
Public propertyCurrentMember
The current active collective member.
Public propertyID
Read-only property that provides a unique identifier for the object to be used for quick access that is not dependent upon the index.
(Inherited from AFObject.)
Public propertyIdentity
This read-only property contains identity of the object.
(Inherited from AFObject.)
Public propertyIsDeleted
This read-only property indicates whether the object has been deleted.
(Inherited from AFObject.)
Public propertyMembers
The collection of PICollectiveMember objects that are configured for the PICollective.
Public propertyPIServer
This read-only property allows access to the PIServer associated with this object.
Public propertyPISystem
This read-only property allows access to the PISystem associated with this object.
(Inherited from AFObject.)
Public propertyUniqueID
Read-only property that provides the collective's unique identifier as a String.
(Overrides AFObjectUniqueID.)
Top
Methods
  NameDescription
Public methodCompareTo(Object)
Compares this instance with a specified Object.
(Inherited from AFObject.)
Public methodCompareTo(AFObject)
Compares this instance with a specified AFObject.
(Inherited from AFObject.)
Public methodEquals(Object)
Determines whether the specified Object is equal to the current object.
(Inherited from AFObject.)
Public methodEquals(AFObject)
Indicates whether the current object is equal to another object of the same type.
(Inherited from AFObject.)
Public methodEquals(PICollective)
Indicates whether the current object is equal to another object of the same type.
Public methodFindPrimary
Finds the primary member of the collective.
Public methodGetHashCode
Gets the hash code for this instance of the object which is suitable for use in hashing algorithms and data structures like a hash table.
(Inherited from AFObject.)
Public methodGetPath
Returns the full path to the object, using just the names.
(Inherited from AFObject.)
Public methodGetPath(AFObject)
Returns the path to the object relative from another object.
(Inherited from AFObject.)
Public methodGetPath(AFEncodeType, AFObject)
Returns the path to the object relative from another object, using the name and/or id as specified by encodeType.
(Inherited from AFObject.)
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Public methodPersist
This method returns the persistence string for the object.
(Inherited from AFObject.)
Public methodSwitchMember(AFConnectionPreference)
The SwitchMember method is used to change the currently connected member of the collective using default credentials.
Public methodSwitchMember(PICollectiveMember)
The SwitchMember method is used to change to the specified member of the collective using default credentials.
Public methodSwitchMember(NetworkCredential, AFConnectionPreference)
The SwitchMember method is used to change the currently connected member of the collective using the specified PI User credentials.
Public methodSwitchMember(NetworkCredential, PICollectiveMember)
The SwitchMember method is used to change to the specified member of the collective using the specified PI User credentials.
Public methodSwitchMember(Boolean, IWin32Window, AFConnectionPreference)
The SwitchMember method is used to change the currently connected member of the collective with a credential prompt if necessary.
Public methodSwitchMember(Boolean, IWin32Window, PICollectiveMember)
The SwitchMember method is used to change to the specified member of the collective with a credential prompt if necessary.
Public methodSwitchMember(NetworkCredential, PIAuthenticationMode, AFConnectionPreference)
The SwitchMember method is used to change the currently connected member of the collective using the specified credentials.
Public methodSwitchMember(NetworkCredential, PIAuthenticationMode, PICollectiveMember)
The SwitchMember method is used to change to the specified member of the collective using the specified credentials.
Public methodToString
Returns a String that represents the current object.
(Overrides AFObjectToString.)
Top
Events
  NameDescription
Public eventCode exampleChanged
Event is raised when the object or one of its sub-objects is changed.
Top
Remarks

A PIServer collective is a group of physical PIServers (member servers) that maintain consistent configuration. A collective is accessed by a PIServer object that represents the entire collective. When a program is connected to a collective and its connection to a particular member is lost, the AF SDK will failover to another member in the collective. This behavior supports high availability of data stored in AF.

PIServer access functions are intended to work seamlessly between server collectives and single servers. However, the PIServer collective members have some behaviors that may vary between the members. The choice of member server during a connection may be influenced through the AFConnectionInfo.Preference property and properties of the PICollectiveMember. If a call is made to a method which is only supported on the primary, and the current member is a secondary, the AF SDK will attempt to open a connection to the primary for the duration of the call. The connected member will not be switched, however.

A connection to a specific server can be created using one of the PICollectiveMember.Connect Overload methods. In this case, the AF SDK will not dynamically switch the connection if a call is made to a method not supported on the member (for example, creating or modifying a point definition on a secondary)..

Note Notes to Callers
This method, property, or class is only available in the .NET 4 version of the SDK.

Version Information

AFSDK

Supported in: 2.10.5, 2.10, 2.9.5, 2.9, 2.8.5, 2.8, 2.7.5, 2.7, 2.6, 2.5
See Also
Enabling Operational Intelligence