Reference
OpcSession Members
Represents a session which a client has created on the server.
Reference
OpcSession Members
- Type
- OpcSession
- Namespace
- Opc.UaFx.Server
- Assembly
- Opc.UaFx.Advanced.dll
- Package
- Opc.UaFx.Advanced v2.59.0
Properties
Certificate
Gets the certificate of the client.
public X509Certificate2 Certificate { get; }Public ReadOnly Property Certificate As X509Certificate2Property value
The X509Certificate2 the client has provided when it created the session or a null reference (Nothing in Visual Basic) if it has provided none.
ConnectTime
Gets the time at which the client has created the session.
public DateTime ConnectTime { get; }Public ReadOnly Property ConnectTime As DateProperty value
The DateTime in UTC at which the session has been created.
Diagnostics
Gets the diagnostic information about the session.
public OpcSessionDiagnostics Diagnostics { get; }Public ReadOnly Property Diagnostics As OpcSessionDiagnosticsProperty value
The OpcSessionDiagnostics of the session or a null reference (Nothing in Visual Basic) if there is none.
EndpointUrl
Gets the URL of the endpoint through which the client has created the session.
public Uri EndpointUrl { get; }Public ReadOnly Property EndpointUrl As UriProperty value
The Uri of the endpoint or a null reference (Nothing in Visual Basic) if the URL is not an absolute URI.
Id
Gets the identifier of the session.
public OpcNodeId Id { get; }Public ReadOnly Property Id As OpcNodeIdProperty value
The OpcNodeId which identifies the session on the server.
IsActive
Gets a value indicating whether the session has been activated.
public bool IsActive { get; }Public ReadOnly Property IsActive As BooleanProperty value
The value true if the client has activated the session; otherwise the value false.
IsExpired
Gets a value indicating whether the session has expired.
public bool IsExpired { get; }Public ReadOnly Property IsExpired As BooleanProperty value
The value true if the time since the LastContactTime exceeds the timeout of the session; otherwise the value false.
LastContactTime
Gets the time of the last contact with the client.
public DateTime LastContactTime { get; }Public ReadOnly Property LastContactTime As DateProperty value
The DateTime in UTC at which the server has received the last request of the session.
Name
Gets the name of the session.
public string Name { get; }Public ReadOnly Property Name As StringProperty value
The name of the session as specified by the client.
PreferredLocales
Gets a collection of preferred locales (see Name) to use to localize data and information.
public OpcLocaleCollection PreferredLocales { get; }Public ReadOnly Property PreferredLocales As OpcLocaleCollectionProperty value
An instance of the OpcLocaleCollection class with Names of the cultures to use to localize data and information for this OpcSession.
ServerUri
Gets the URI of the server recorded in the diagnostic information about the session.
public Uri ServerUri { get; }Public ReadOnly Property ServerUri As UriProperty value
The recorded URI as an absolute Uri; otherwise a null reference (Nothing in Visual Basic). The server does not record a URI for its sessions, therefore the value is currently always a null reference.
Socket
Gets the identity of the socket through which the client has created the session.
public OpcSocketIdentity Socket { get; }Public ReadOnly Property Socket As OpcSocketIdentityProperty value
The OpcSocketIdentity of the socket or a null reference (Nothing in Visual Basic) if it is not known.
SuppliedIdentity
Gets the user identity which the client has supplied.
public OpcUserIdentity SuppliedIdentity { get; }Public ReadOnly Property SuppliedIdentity As OpcUserIdentityProperty value
The OpcUserIdentity supplied by the client or a null reference (Nothing in Visual Basic) if there is none.
UsedIdentity
Gets the user identity which the server uses for the session.
public OpcUserIdentity UsedIdentity { get; }Public ReadOnly Property UsedIdentity As OpcUserIdentityProperty value
The OpcUserIdentity which the server has mapped the SuppliedIdentity to or a null reference (Nothing in Visual Basic) if there is none.
Methods
Close
Closes the session.
public void Close()Public Sub Close()Dispose
| Overload | Description |
|---|---|
| Dispose() | Releases all resources used by the OpcSession. |
| Dispose( | Releases the unmanaged resources used by the OpcSession and optionally releases the managed resources. |
Dispose()
Releases all resources used by the OpcSession.
public void Dispose()Public Sub Dispose()Implements
Dispose(bool)
Releases the unmanaged resources used by the OpcSession and optionally releases the managed resources.
protected virtual void Dispose(bool disposing)Protected Overridable Sub Dispose(disposing As Boolean)Parameters
| Name | Type | Description |
|---|---|---|
disposing | Boolean | The value true to release both managed and unmanaged resources; otherwise the value false to release only unmanaged resources. |
GetSubscriptions
Provides a sequence of OpcSubscription instances associated with this OpcSession.
public IEnumerable<OpcSubscription> GetSubscriptions()Public Function GetSubscriptions() As IEnumerable(Of OpcSubscription)Returns
An IEnumerable<T> of OpcSubscription instances.

