Class StringValue
- java.lang.Object
-
- software.amazon.smithy.rulesengine.language.evaluation.value.Value
-
- software.amazon.smithy.rulesengine.language.evaluation.value.StringValue
-
- All Implemented Interfaces:
FromSourceLocation
,ToNode
public final class StringValue extends Value
A string value.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(java.lang.Object o)
StringValue
expectStringValue()
Returns the current value as anArrayValue
, throwingRuntimeException
when the value is the wrong type.Type
getType()
java.lang.String
getValue()
Gets the value of the string.int
hashCode()
Node
toNode()
Converts a value to aNode
.java.lang.String
toString()
-
Methods inherited from class software.amazon.smithy.rulesengine.language.evaluation.value.Value
arrayValue, booleanValue, emptyValue, endpointValue, expectArrayValue, expectBooleanValue, expectEndpointValue, expectIntegerValue, expectRecordValue, fromNode, getSourceLocation, integerValue, isEmpty, recordValue, stringValue
-
-
-
-
Method Detail
-
getValue
public java.lang.String getValue()
Gets the value of the string.- Returns:
- the value of the string.
-
expectStringValue
public StringValue expectStringValue()
Description copied from class:Value
Returns the current value as anArrayValue
, throwingRuntimeException
when the value is the wrong type.- Overrides:
expectStringValue
in classValue
- Returns:
- returns a string value.
-
toNode
public Node toNode()
Description copied from interface:ToNode
Converts a value to aNode
.- Returns:
- Returns the creates Node.
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equals
in classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
-