C++ Based OPC UA Client/Server/PubSub SDK  1.7.6.537
UaEventData Class Referenceabstract

Represents the event field data for an event fired by the server application. More...

#include <uaeventdata.h>

Inherited by BaseEventTypeData.

Public Member Functions

 UaEventData ()
 construction
 
virtual ~UaEventData ()
 destruction
 
virtual void getFieldData (OpcUa_UInt32 index, Session *pSession, OpcUa_Variant &data)=0
 Get the field value for the passed index. More...
 
virtual UaNodeId getConditionNodeId ()
 Returns the condition NodeId if the event data is related to a condition object. More...
 
virtual UaNodeId getConditionBranchNodeId ()
 Returns the condition branch NodeId if the event data is related to a condition object. More...
 
virtual OpcUa_Boolean getConditionRetain ()
 Returns the Retain flag if the event data is related to a condition object. More...
 
virtual void lockEventData ()
 Lock the event data for data update and event handling. More...
 
virtual void unlockEventData ()
 Unlock the event data after data update or event handling. More...
 
void setEventUserData (OpcUa_Handle pEventUserData)
 Sets the user specific event data to the EventData object. More...
 
OpcUa_Handle getEventUserData () const
 Returns the user specific event data.
 
const NodeAccessInfogetEventAccessInfo () const
 Returns the access info associated with this UaEventData. More...
 
void useEventAccessInfoFrom (const UaEventData *pOther)
 Set the access info from another node to this node. More...
 
void setEventAccessInfo (NodeAccessInfo *pAccessInfo)
 Set access info for this UaEventData. More...
 
void attachEventAccessInfo (NodeAccessInfo *pAccessInfo)
 Set access info for this UaEventData. More...
 
virtual ReferenceCountergetConditionDataReferenceCounter ()
 Get the ReferenceCounter interface necessary for condition event data classes.
 

Static Public Member Functions

static void registerEventFields ()
 Registers all event type fields with the EventManagerBase.
 

Detailed Description

Represents the event field data for an event fired by the server application.

This interface is used to pass an event to EventManagerBase::fireEvent() for distribution to interested clients. It provides access to the event field data used for filtering and event data delivery.

The method getFieldData() is used by the EventManagerBase to access the event field data within a Session context. Therefore it can be used to provide language specific strings or to limit access to certain fields based on the user rights of the Session.

Implementation classes like BaseEventTypeData normally provide convenience functions like BaseEventTypeData::getMessageValue() to allow Session specific access to localized text values.

See also
BaseEventTypeData for an event creation example

Member Function Documentation

void UaEventData::attachEventAccessInfo ( NodeAccessInfo pAccessInfo)

Set access info for this UaEventData.

Does not increase the reference counter on the NodeAccessInfo argument.

virtual UaNodeId UaEventData::getConditionBranchNodeId ( )
inlinevirtual

Returns the condition branch NodeId if the event data is related to a condition object.

Returns a null NodeId if the event data is related to a simple event.

Reimplemented in OpcUa::ConditionType, and OpcUa::ConditionTypeData.

virtual UaNodeId UaEventData::getConditionNodeId ( )
inlinevirtual

Returns the condition NodeId if the event data is related to a condition object.

Returns a null NodeId if the event data is related to a simple event.

Reimplemented in OpcUa::ConditionType, and OpcUa::ConditionTypeData.

virtual OpcUa_Boolean UaEventData::getConditionRetain ( )
inlinevirtual

Returns the Retain flag if the event data is related to a condition object.

Returns a OpcUa_False if the event data is related to a simple event.

Reimplemented in OpcUa::ConditionType, and OpcUa::ConditionTypeData.

const NodeAccessInfo * UaEventData::getEventAccessInfo ( ) const

Returns the access info associated with this UaEventData.

Node access info is used for user authorization. Returning NULL means no access permission is configured.

virtual void UaEventData::getFieldData ( OpcUa_UInt32  index,
Session pSession,
OpcUa_Variant data 
)
pure virtual

Get the field value for the passed index.

Parameters
indexThe index of the selected field. The index is provided by the server application when the event field is registered with EventManagerBase::registerEventField().
pSessionThe session context for the field access
dataThe data for the selected field.

Implemented in OpcUa::TrustListUpdatedAuditEventTypeData, OpcUa::RoleMappingRuleChangedAuditEventTypeData, OpcUa::KeyCredentialUpdatedAuditEventTypeData, OpcUa::KeyCredentialDeletedAuditEventTypeData, OpcUa::KeyCredentialAuditEventTypeData, OpcUa::CertificateUpdatedAuditEventTypeData, OpcUa::ProgramTransitionAuditEventTypeData, OpcUa::AuditProgramTransitionEventTypeData, OpcUa::AuditUpdateStateEventTypeData, OpcUa::AuditConditionSuppressionEventTypeData, OpcUa::AuditConditionSilenceEventTypeData, OpcUa::AuditConditionShelvingEventTypeData, OpcUa::AuditConditionRespondEventTypeData, OpcUa::AuditConditionResetEventTypeData, OpcUa::AuditConditionOutOfServiceEventTypeData, OpcUa::AuditConditionEnableEventTypeData, OpcUa::AuditConditionConfirmEventTypeData, OpcUa::AuditConditionCommentEventTypeData, OpcUa::AuditConditionAcknowledgeEventTypeData, OpcUa::AuditConditionEventTypeData, OpcUa::AuditUpdateMethodEventTypeData, OpcUa::AuditWriteUpdateEventTypeData, OpcUa::AuditHistoryValueUpdateEventTypeData, OpcUa::AuditHistoryEventUpdateEventTypeData, OpcUa::AuditHistoryRawModifyDeleteEventTypeData, OpcUa::AuditHistoryEventDeleteEventTypeData, OpcUa::AuditHistoryAtTimeDeleteEventTypeData, OpcUa::AuditHistoryDeleteEventTypeData, OpcUa::AuditHistoryAnnotationUpdateEventTypeData, OpcUa::AuditHistoryUpdateEventTypeData, OpcUa::AuditUpdateEventTypeData, OpcUa::AuditUrlMismatchEventTypeData, OpcUa::AuditCreateSessionEventTypeData, OpcUa::AuditCancelEventTypeData, OpcUa::AuditActivateSessionEventTypeData, OpcUa::AuditSessionEventTypeData, OpcUa::AuditOpenSecureChannelEventTypeData, OpcUa::AuditChannelEventTypeData, OpcUa::AuditCertificateUntrustedEventTypeData, OpcUa::AuditCertificateRevokedEventTypeData, OpcUa::AuditCertificateMismatchEventTypeData, OpcUa::AuditCertificateInvalidEventTypeData, OpcUa::AuditCertificateExpiredEventTypeData, OpcUa::AuditCertificateDataMismatchEventTypeData, OpcUa::AuditCertificateEventTypeData, OpcUa::AuditSecurityEventTypeData, OpcUa::AuditDeleteReferencesEventTypeData, OpcUa::ConditionTypeBase, OpcUa::AuditDeleteNodesEventTypeData, OpcUa::AlarmConditionTypeBase, OpcUa::ProgressEventTypeData, OpcUa::AuditAddReferencesEventTypeData, OpcUa::SemanticChangeEventTypeData, OpcUa::AcknowledgeableConditionTypeBase, OpcUa::LimitAlarmTypeBase, OpcUa::AuditAddNodesEventTypeData, OpcUa::NonExclusiveLimitAlarmTypeBase, OpcUa::DialogConditionTypeBase, BaseEventTypeData, OpcUa::AuditNodeManagementEventTypeData, OpcUa::GeneralModelChangeEventTypeData, OpcUa::NonExclusiveDeviationAlarmType, OpcUa::NonExclusiveRateOfChangeAlarmType, OpcUa::ExclusiveDeviationAlarmType, OpcUa::CertificateExpirationAlarmType, OpcUa::ExclusiveLimitAlarmTypeBase, OpcUa::SystemStatusChangeEventTypeData, OpcUa::OffNormalAlarmTypeBase, OpcUa::ConditionTypeData, OpcUa::DiscrepancyAlarmType, OpcUa::TrustListOutOfDateAlarmType, OpcUa::ExclusiveRateOfChangeAlarmType, OpcUa::NonExclusiveLevelAlarmType, OpcUa::ExclusiveLevelAlarmType, OpcUa::TripAlarmType, OpcUa::DiscreteAlarmTypeBase, OpcUa::AuditEventTypeData, OpcUa::AcknowledgeableConditionTypeData, OpcUa::SystemOffNormalAlarmType, OpcUaDi::CheckFunctionAlarmTypeBase, OpcUaDi::DeviceHealthDiagnosticAlarmTypeBase, OpcUaDi::FailureAlarmTypeBase, OpcUaDi::MaintenanceRequiredAlarmTypeBase, OpcUaDi::OffSpecAlarmTypeBase, OpcUa::SystemDiagnosticAlarmType, OpcUa::BaseModelChangeEventTypeData, OpcUa::InstrumentDiagnosticAlarmType, OpcUa::AlarmConditionTypeData, OpcUa::LimitAlarmTypeData, OpcUa::DeviceFailureEventTypeData, OpcUa::NonExclusiveRateOfChangeAlarmTypeData, OpcUa::NonExclusiveDeviationAlarmTypeData, OpcUa::NonExclusiveLimitAlarmTypeData, OpcUa::ExclusiveDeviationAlarmTypeData, OpcUa::DialogConditionTypeData, OpcUa::CertificateExpirationAlarmTypeData, OpcUa::OffNormalAlarmTypeData, OpcUa::ExclusiveRateOfChangeAlarmTypeData, OpcUa::ExclusiveLimitAlarmTypeData, OpcUa::NonExclusiveLevelAlarmTypeData, OpcUa::DiscrepancyAlarmTypeData, OpcUa::TransitionEventTypeData, OpcUa::TrustListOutOfDateAlarmTypeData, OpcUa::ExclusiveLevelAlarmTypeData, OpcUa::TripAlarmTypeData, OpcUa::ProgramTransitionEventTypeData, OpcUa::DiscreteAlarmTypeData, OpcUa::SystemEventTypeData, OpcUa::SystemOffNormalAlarmTypeData, OpcUaDi::CheckFunctionAlarmTypeData, OpcUaDi::DeviceHealthDiagnosticAlarmTypeData, OpcUaDi::FailureAlarmTypeData, OpcUaDi::MaintenanceRequiredAlarmTypeData, OpcUaDi::OffSpecAlarmTypeData, OpcUa::SystemDiagnosticAlarmTypeData, and OpcUa::InstrumentDiagnosticAlarmTypeData.

virtual void UaEventData::lockEventData ( )
inlinevirtual

Lock the event data for data update and event handling.

This method is used for event data objects maintaining a state for conditions since there may be concurrent access to the condition data by a condition update and a condition refresh triggered by a client. This method is also used during the event processing in the SDK. The method is implemented by condition related event data classes.

Reimplemented in OpcUa::ConditionTypeBase, and OpcUa::ConditionTypeData.

void UaEventData::setEventAccessInfo ( NodeAccessInfo pAccessInfo)

Set access info for this UaEventData.

The UaEventData increases the reference counter on the NodeAccessInfo argument.

void UaEventData::setEventUserData ( OpcUa_Handle  pEventUserData)

Sets the user specific event data to the EventData object.

This data is not used by the SDK

virtual void UaEventData::unlockEventData ( )
inlinevirtual

Unlock the event data after data update or event handling.

This method is used for event data objects maintaining a state for conditions since there may be concurrent access to the condition data by a condition update and a condition refresh triggered by a client. This method is also used during the event processing in the SDK. The method is implemented by condition related event data classes.

Reimplemented in OpcUa::ConditionTypeBase, and OpcUa::ConditionTypeData.

void UaEventData::useEventAccessInfoFrom ( const UaEventData pOther)

Set the access info from another node to this node.

This does not copy the access info, instead both nodes share the same access info.


The documentation for this class was generated from the following files: