Record Class DataValue
java.lang.Object
java.lang.Record
org.eclipse.milo.opcua.stack.core.types.builtin.DataValue
-
Nested Class Summary
Nested Classes -
Constructor Summary
ConstructorsConstructorDescriptionDataValue(long statusCode) DataValue(StatusCode statusCode) DataValue(Variant value, StatusCode status) DataValue(Variant value, StatusCode status, @Nullable DateTime time) DataValue(Variant value, StatusCode status, @Nullable DateTime sourceTime, @Nullable DateTime serverTime) DataValue(Variant value, StatusCode statusCode, @Nullable DateTime sourceTime, @Nullable UShort sourcePicoseconds, @Nullable DateTime serverTime, @Nullable UShort serverPicoseconds) Creates an instance of aDataValuerecord class. -
Method Summary
Modifier and TypeMethodDescriptioncopy()static DataValuederivedNonValue(DataValue from, TimestampsToReturn timestamps) static DataValuederivedValue(DataValue from, TimestampsToReturn timestamps) final booleanIndicates whether some other object is "equal to" this one.@Nullable UShort@Nullable DateTime@Nullable UShort@Nullable DateTimegetValue()final inthashCode()Returns a hash code value for this object.static DataValue.BuildernewValue()@Nullable UShortReturns the value of theserverPicosecondsrecord component.@Nullable DateTimeReturns the value of theserverTimerecord component.@Nullable UShortReturns the value of thesourcePicosecondsrecord component.@Nullable DateTimeReturns the value of thesourceTimerecord component.Returns the value of thestatusCoderecord component.final StringtoString()Returns a string representation of this record class.value()Returns the value of thevaluerecord component.static DataValueCreate aDataValuecontaining only a value.withServerTime(@Nullable DateTime serverTime) withSourceTime(@Nullable DateTime sourceTime) withStatus(StatusCode status)
-
Constructor Details
-
DataValue
public DataValue(long statusCode) -
DataValue
-
DataValue
-
DataValue
-
DataValue
-
DataValue
public DataValue(Variant value, StatusCode status, @Nullable DateTime sourceTime, @Nullable DateTime serverTime) -
DataValue
public DataValue(Variant value, StatusCode statusCode, @Nullable DateTime sourceTime, @Nullable UShort sourcePicoseconds, @Nullable DateTime serverTime, @Nullable UShort serverPicoseconds) Creates an instance of aDataValuerecord class.- Parameters:
value- the value for thevaluerecord componentstatusCode- the value for thestatusCoderecord componentsourceTime- the value for thesourceTimerecord componentsourcePicoseconds- the value for thesourcePicosecondsrecord componentserverTime- the value for theserverTimerecord componentserverPicoseconds- the value for theserverPicosecondsrecord component
-
-
Method Details
-
getValue
-
getStatusCode
-
getSourceTime
-
getSourcePicoseconds
-
getServerTime
-
getServerPicoseconds
-
withStatus
-
withSourceTime
-
withServerTime
-
copy
-
copy
-
newValue
-
derivedValue
-
derivedNonValue
-
valueOnly
Create aDataValuecontaining only a value.StatusCode.GOODis implied, and other fields will be null. -
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
value
Returns the value of thevaluerecord component.- Returns:
- the value of the
valuerecord component
-
statusCode
Returns the value of thestatusCoderecord component.- Returns:
- the value of the
statusCoderecord component
-
sourceTime
Returns the value of thesourceTimerecord component.- Returns:
- the value of the
sourceTimerecord component
-
sourcePicoseconds
Returns the value of thesourcePicosecondsrecord component.- Returns:
- the value of the
sourcePicosecondsrecord component
-
serverTime
Returns the value of theserverTimerecord component.- Returns:
- the value of the
serverTimerecord component
-
serverPicoseconds
Returns the value of theserverPicosecondsrecord component.- Returns:
- the value of the
serverPicosecondsrecord component
-