All Implemented Interfaces:
BaseDataVariableType, BaseVariableType, DataItemType, org.eclipse.milo.opcua.sdk.core.nodes.Node, org.eclipse.milo.opcua.sdk.core.nodes.VariableNode
Direct Known Subclasses:
ArrayItemTypeNode, BaseAnalogTypeNode, DiscreteItemTypeNode

public class DataItemTypeNode extends BaseDataVariableTypeNode implements DataItemType
  • Constructor Details

    • DataItemTypeNode

      public DataItemTypeNode(OpcUaClient client, org.eclipse.milo.opcua.stack.core.types.builtin.NodeId nodeId, org.eclipse.milo.opcua.stack.core.types.enumerated.NodeClass nodeClass, org.eclipse.milo.opcua.stack.core.types.builtin.QualifiedName browseName, org.eclipse.milo.opcua.stack.core.types.builtin.LocalizedText displayName, org.eclipse.milo.opcua.stack.core.types.builtin.LocalizedText description, org.eclipse.milo.opcua.stack.core.types.builtin.unsigned.UInteger writeMask, org.eclipse.milo.opcua.stack.core.types.builtin.unsigned.UInteger userWriteMask, org.eclipse.milo.opcua.stack.core.types.structured.RolePermissionType[] rolePermissions, org.eclipse.milo.opcua.stack.core.types.structured.RolePermissionType[] userRolePermissions, org.eclipse.milo.opcua.stack.core.types.structured.AccessRestrictionType accessRestrictions, org.eclipse.milo.opcua.stack.core.types.builtin.DataValue value, org.eclipse.milo.opcua.stack.core.types.builtin.NodeId dataType, Integer valueRank, org.eclipse.milo.opcua.stack.core.types.builtin.unsigned.UInteger[] arrayDimensions, org.eclipse.milo.opcua.stack.core.types.builtin.unsigned.UByte accessLevel, org.eclipse.milo.opcua.stack.core.types.builtin.unsigned.UByte userAccessLevel, Double minimumSamplingInterval, Boolean historizing, org.eclipse.milo.opcua.stack.core.types.structured.AccessLevelExType accessLevelEx)
  • Method Details

    • getDefinition

      public String getDefinition() throws org.eclipse.milo.opcua.stack.core.UaException
      Description copied from interface: DataItemType
      Get the local value of the Definition Node.

      The returned value is the last seen; it is not read live from the server.

      Specified by:
      getDefinition in interface DataItemType
      Returns:
      the local value of the Definition Node.
      Throws:
      org.eclipse.milo.opcua.stack.core.UaException - if an error occurs creating or getting the Definition Node.
    • setDefinition

      public void setDefinition(String value) throws org.eclipse.milo.opcua.stack.core.UaException
      Description copied from interface: DataItemType
      Set the local value of the Definition Node.

      The value is only updated locally; it is not written to the server.

      Specified by:
      setDefinition in interface DataItemType
      Parameters:
      value - the local value to set for the Definition Node.
      Throws:
      org.eclipse.milo.opcua.stack.core.UaException - if an error occurs creating or getting the Definition Node.
    • readDefinition

      public String readDefinition() throws org.eclipse.milo.opcua.stack.core.UaException
      Description copied from interface: DataItemType
      Read the value of the Definition Node from the server and update the local value if the operation succeeds.
      Specified by:
      readDefinition in interface DataItemType
      Returns:
      the String value read from the server.
      Throws:
      org.eclipse.milo.opcua.stack.core.UaException - if a service- or operation-level error occurs.
    • writeDefinition

      public void writeDefinition(String value) throws org.eclipse.milo.opcua.stack.core.UaException
      Description copied from interface: DataItemType
      Write a new value for the Definition Node to the server and update the local value if the operation succeeds.
      Specified by:
      writeDefinition in interface DataItemType
      Parameters:
      value - the String value to write to the server.
      Throws:
      org.eclipse.milo.opcua.stack.core.UaException - if a service- or operation-level error occurs.
    • readDefinitionAsync

      public CompletableFuture<? extends String> readDefinitionAsync()
      Description copied from interface: DataItemType
      An asynchronous implementation of DataItemType.readDefinition().
      Specified by:
      readDefinitionAsync in interface DataItemType
      Returns:
      a CompletableFuture that completes successfully with the value or completes exceptionally if an operation- or service-level error occurs.
    • writeDefinitionAsync

      public CompletableFuture<org.eclipse.milo.opcua.stack.core.types.builtin.StatusCode> writeDefinitionAsync(String definition)
      Description copied from interface: DataItemType
      An asynchronous implementation of DataItemType.writeDefinition(java.lang.String).
      Specified by:
      writeDefinitionAsync in interface DataItemType
      Returns:
      a CompletableFuture that completes successfully with the operation result or completes exceptionally if a service-level error occurs.
    • getDefinitionNode

      public PropertyTypeNode getDefinitionNode() throws org.eclipse.milo.opcua.stack.core.UaException
      Description copied from interface: DataItemType
      Get the Definition PropertyType Node, or null if it does not exist.

      The Node is created when first accessed and cached for subsequent calls.

      Specified by:
      getDefinitionNode in interface DataItemType
      Returns:
      the Definition PropertyType Node, or null if it does not exist.
      Throws:
      org.eclipse.milo.opcua.stack.core.UaException - if an error occurs creating or getting the Node.
    • getDefinitionNodeAsync

      public CompletableFuture<? extends PropertyTypeNode> getDefinitionNodeAsync()
      Description copied from interface: DataItemType
      Asynchronous implementation of DataItemType.getDefinitionNode().
      Specified by:
      getDefinitionNodeAsync in interface DataItemType
      Returns:
      a CompletableFuture that completes successfully with the PropertyType Node or completes exceptionally if an error occurs creating or getting the Node.
    • getValuePrecision

      public Double getValuePrecision() throws org.eclipse.milo.opcua.stack.core.UaException
      Description copied from interface: DataItemType
      Get the local value of the ValuePrecision Node.

      The returned value is the last seen; it is not read live from the server.

      Specified by:
      getValuePrecision in interface DataItemType
      Returns:
      the local value of the ValuePrecision Node.
      Throws:
      org.eclipse.milo.opcua.stack.core.UaException - if an error occurs creating or getting the ValuePrecision Node.
    • setValuePrecision

      public void setValuePrecision(Double value) throws org.eclipse.milo.opcua.stack.core.UaException
      Description copied from interface: DataItemType
      Set the local value of the ValuePrecision Node.

      The value is only updated locally; it is not written to the server.

      Specified by:
      setValuePrecision in interface DataItemType
      Parameters:
      value - the local value to set for the ValuePrecision Node.
      Throws:
      org.eclipse.milo.opcua.stack.core.UaException - if an error occurs creating or getting the ValuePrecision Node.
    • readValuePrecision

      public Double readValuePrecision() throws org.eclipse.milo.opcua.stack.core.UaException
      Description copied from interface: DataItemType
      Read the value of the ValuePrecision Node from the server and update the local value if the operation succeeds.
      Specified by:
      readValuePrecision in interface DataItemType
      Returns:
      the Double value read from the server.
      Throws:
      org.eclipse.milo.opcua.stack.core.UaException - if a service- or operation-level error occurs.
    • writeValuePrecision

      public void writeValuePrecision(Double value) throws org.eclipse.milo.opcua.stack.core.UaException
      Description copied from interface: DataItemType
      Write a new value for the ValuePrecision Node to the server and update the local value if the operation succeeds.
      Specified by:
      writeValuePrecision in interface DataItemType
      Parameters:
      value - the Double value to write to the server.
      Throws:
      org.eclipse.milo.opcua.stack.core.UaException - if a service- or operation-level error occurs.
    • readValuePrecisionAsync

      public CompletableFuture<? extends Double> readValuePrecisionAsync()
      Description copied from interface: DataItemType
      An asynchronous implementation of DataItemType.readValuePrecision().
      Specified by:
      readValuePrecisionAsync in interface DataItemType
      Returns:
      a CompletableFuture that completes successfully with the value or completes exceptionally if an operation- or service-level error occurs.
    • writeValuePrecisionAsync

      public CompletableFuture<org.eclipse.milo.opcua.stack.core.types.builtin.StatusCode> writeValuePrecisionAsync(Double valuePrecision)
      Description copied from interface: DataItemType
      An asynchronous implementation of DataItemType.writeValuePrecision(java.lang.Double).
      Specified by:
      writeValuePrecisionAsync in interface DataItemType
      Returns:
      a CompletableFuture that completes successfully with the operation result or completes exceptionally if a service-level error occurs.
    • getValuePrecisionNode

      public PropertyTypeNode getValuePrecisionNode() throws org.eclipse.milo.opcua.stack.core.UaException
      Description copied from interface: DataItemType
      Get the ValuePrecision PropertyType Node, or null if it does not exist.

      The Node is created when first accessed and cached for subsequent calls.

      Specified by:
      getValuePrecisionNode in interface DataItemType
      Returns:
      the ValuePrecision PropertyType Node, or null if it does not exist.
      Throws:
      org.eclipse.milo.opcua.stack.core.UaException - if an error occurs creating or getting the Node.
    • getValuePrecisionNodeAsync

      public CompletableFuture<? extends PropertyTypeNode> getValuePrecisionNodeAsync()
      Description copied from interface: DataItemType
      Asynchronous implementation of DataItemType.getValuePrecisionNode().
      Specified by:
      getValuePrecisionNodeAsync in interface DataItemType
      Returns:
      a CompletableFuture that completes successfully with the PropertyType Node or completes exceptionally if an error occurs creating or getting the Node.