|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.prosysopc.ua.server.ServiceManagerBase
com.prosysopc.ua.server.EventManager
com.prosysopc.ua.server.EventManagerUaNode
public class EventManagerUaNode
| Field Summary |
|---|
| Fields inherited from class com.prosysopc.ua.server.EventManager |
|---|
listener, RESULT_OK |
| Constructor Summary | |
|---|---|
EventManagerUaNode(NodeManager nodeManager)
|
|
| Method Summary | |
|---|---|
protected boolean |
acknowledge(ServiceContext serviceContext,
AcknowledgeableConditionTypeNode condition,
org.opcfoundation.ua.builtintypes.ByteString eventId,
org.opcfoundation.ua.builtintypes.LocalizedText comment)
|
protected boolean |
addComment(ServiceContext serviceContext,
ConditionTypeNode condition,
org.opcfoundation.ua.builtintypes.ByteString eventId,
org.opcfoundation.ua.builtintypes.LocalizedText comment)
|
protected void |
collectConditions(UaNode node,
Collection<ConditionTypeNode> conditions)
|
protected boolean |
confirm(ServiceContext serviceContext,
AcknowledgeableConditionTypeNode condition,
org.opcfoundation.ua.builtintypes.ByteString eventId,
org.opcfoundation.ua.builtintypes.LocalizedText comment)
|
protected boolean |
disable(ServiceContext serviceContext,
ConditionTypeNode condition)
|
protected boolean |
enable(ServiceContext serviceContext,
ConditionTypeNode condition)
|
Collection<ConditionTypeNode> |
getConditions()
Get a list of all Condition nodes in the server address space. |
Collection<ConditionTypeNode> |
getConditions(org.opcfoundation.ua.builtintypes.NodeId nodeId)
Get a list of all Condition nodes in the server address space that are listenable from the specified node. |
Collection<ConditionTypeNode> |
getConditions(UaNode node)
Get a list of all Condition nodes in the server address space that are listenable from the specified node. |
boolean |
onCall(ServiceContext serviceContext,
org.opcfoundation.ua.builtintypes.NodeId objectId,
UaNode object,
org.opcfoundation.ua.builtintypes.NodeId methodId,
UaMethod method,
org.opcfoundation.ua.builtintypes.Variant[] inputArguments,
org.opcfoundation.ua.builtintypes.StatusCode[] inputArgumentResults,
org.opcfoundation.ua.builtintypes.DiagnosticInfo[] inputArgumentDiagnosticInfos,
org.opcfoundation.ua.builtintypes.Variant[] output)
A method call notification. |
protected boolean |
oneshotshelve(ServiceContext serviceContext,
AlarmConditionTypeNode condition,
ShelvedStateMachineTypeNode stateMachine)
|
protected void |
refreshItem(MonitoredEventItem eventItem)
|
protected boolean |
requireUaNode()
|
protected boolean |
timedshelve(ServiceContext serviceContext,
AlarmConditionTypeNode condition,
ShelvedStateMachineTypeNode stateMachine,
double shelvingTime)
|
protected boolean |
unshelve(ServiceContext serviceContext,
AlarmConditionTypeNode condition,
ShelvedStateMachineTypeNode stateMachine)
|
| Methods inherited from class com.prosysopc.ua.server.ServiceManagerBase |
|---|
arrayDimensionsMatch, checkIsMethod, checkIsValueNode, checkIsVariable, checkIsVariableOrVariableType, dataTypeEquals, getNode, getNode, getNode, getNode, getNodeManagerTable, getServer, getSubscriptionManager, isValueNode, isVariable, listenerError |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public EventManagerUaNode(NodeManager nodeManager)
nodeManager - | Method Detail |
|---|
public Collection<ConditionTypeNode> getConditions()
The method will search for condition nodes that are connected to the Server object via HasCondition and HasEventSource/HasNotifier (forward) references.
public Collection<ConditionTypeNode> getConditions(org.opcfoundation.ua.builtintypes.NodeId nodeId)
throws StatusException
The method will search for condition nodes that are connected to the specified node via HasCondition and HasEventSource/HasNotifier (forward) references.
The method finds the node object corresponding to the nodeId and calls the corresponding method with the node.
nodeId - ID of the root node for the list
StatusException - if the nodeId does not correspond to a nodepublic Collection<ConditionTypeNode> getConditions(UaNode node)
The method will search for condition nodes that are connected to the specified node via HasCondition and HasEventSource/HasNotifier (forward) references.
node - Root node for the list
public boolean onCall(ServiceContext serviceContext,
org.opcfoundation.ua.builtintypes.NodeId objectId,
UaNode object,
org.opcfoundation.ua.builtintypes.NodeId methodId,
UaMethod method,
org.opcfoundation.ua.builtintypes.Variant[] inputArguments,
org.opcfoundation.ua.builtintypes.StatusCode[] inputArgumentResults,
org.opcfoundation.ua.builtintypes.DiagnosticInfo[] inputArgumentDiagnosticInfos,
org.opcfoundation.ua.builtintypes.Variant[] output)
throws StatusException
CallableListenerUse onCall to check whether the called method is the one that you handle. If so, return true, and set the outputs. Do not create a new array for the outputs, just assign your values in there - it is already created for the length defined by the OutputArguments of the UaMethod.
If you find errors in the inputArguments, fill in the inputArgumentResults and inputArgumentDiagnosticInfos respectively. They are also preallocated.
onCall in interface CallableListeneronCall in class EventManagerobjectId - the ID of the node whose method is being calledobject - the object node whose method is being called, if availablemethodId - the ID of the method being calledmethod - the method node being called, if availableinputArguments - input argument valuesinputArgumentResults - room for argument errors. Fill in the array if you encounter errors
in the values.inputArgumentDiagnosticInfos - room for diagnostic info, in case of errors.output - room for output values. The array is pre-created, so just fill in the values.
StatusException - if there are errors in the method handling. For example, if you set
inputArgumentResults, you should throw a StatusException with
StatusCodes.Bad_InvalidArgument
protected boolean acknowledge(ServiceContext serviceContext,
AcknowledgeableConditionTypeNode condition,
org.opcfoundation.ua.builtintypes.ByteString eventId,
org.opcfoundation.ua.builtintypes.LocalizedText comment)
throws StatusException
StatusException
protected boolean addComment(ServiceContext serviceContext,
ConditionTypeNode condition,
org.opcfoundation.ua.builtintypes.ByteString eventId,
org.opcfoundation.ua.builtintypes.LocalizedText comment)
throws StatusException
StatusException
protected void collectConditions(UaNode node,
Collection<ConditionTypeNode> conditions)
protected boolean confirm(ServiceContext serviceContext,
AcknowledgeableConditionTypeNode condition,
org.opcfoundation.ua.builtintypes.ByteString eventId,
org.opcfoundation.ua.builtintypes.LocalizedText comment)
throws StatusException
StatusException
protected boolean disable(ServiceContext serviceContext,
ConditionTypeNode condition)
throws StatusException
StatusException
protected boolean enable(ServiceContext serviceContext,
ConditionTypeNode condition)
throws StatusException
StatusException
protected boolean oneshotshelve(ServiceContext serviceContext,
AlarmConditionTypeNode condition,
ShelvedStateMachineTypeNode stateMachine)
throws StatusException
StatusExceptionprotected void refreshItem(MonitoredEventItem eventItem)
refreshItem in class EventManagereventItem - protected boolean requireUaNode()
requireUaNode in class ServiceManagerBase
protected boolean timedshelve(ServiceContext serviceContext,
AlarmConditionTypeNode condition,
ShelvedStateMachineTypeNode stateMachine,
double shelvingTime)
throws StatusException
StatusException
protected boolean unshelve(ServiceContext serviceContext,
AlarmConditionTypeNode condition,
ShelvedStateMachineTypeNode stateMachine)
throws StatusException
StatusException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||