Record Class ConstantValue
java.lang.Object
java.lang.Record
net.codecrete.windowsapi.metadata.ConstantValue
- Record Components:
name- the constant namenamespace- the constant's namespacetype- the constant typevalue- the constant valueisAnsiEncoding- flag indicating if a string value is encoded as ANSI (Windows-1252) or Unicode (UTF-16).
public record ConstantValue(String name, Namespace namespace, Type type, Object value, boolean isAnsiEncoding)
extends Record
Value of a constant.
-
Constructor Summary
ConstructorsConstructorDescriptionConstantValue(String name, Namespace namespace, Type type, Object value, boolean isAnsiEncoding) Creates an instance of aConstantValuerecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.booleanReturns the value of theisAnsiEncodingrecord component.name()Returns the value of thenamerecord component.Returns the value of thenamespacerecord component.final StringtoString()Returns a string representation of this record class.type()Returns the value of thetyperecord component.value()Returns the value of thevaluerecord component.
-
Constructor Details
-
ConstantValue
public ConstantValue(String name, Namespace namespace, Type type, Object value, boolean isAnsiEncoding) Creates an instance of aConstantValuerecord class.- Parameters:
name- the value for thenamerecord componentnamespace- the value for thenamespacerecord componenttype- the value for thetyperecord componentvalue- the value for thevaluerecord componentisAnsiEncoding- the value for theisAnsiEncodingrecord component
-
-
Method Details
-
toString
-
hashCode
-
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. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with thecomparemethod from their corresponding wrapper classes. -
name
-
namespace
-
type
-
value
-
isAnsiEncoding
public boolean isAnsiEncoding()Returns the value of theisAnsiEncodingrecord component.- Returns:
- the value of the
isAnsiEncodingrecord component
-