- java.lang.Object
-
- swim.structure.Item
-
- swim.structure.Value
-
- swim.structure.Text
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
booleanValue()
Converts thisValue
into a primitiveboolean
value, if possible.boolean
booleanValue(boolean orElse)
Converts thisValue
into a primitiveboolean
value, if possible; otherwise returnsorElse
if thisValue
can't be converted into a primitiveboolean
value.Text
branch()
byte
byteValue()
Converts thisValue
into a primitivebyte
value, if possible.byte
byteValue(byte orElse)
Converts thisValue
into a primitivebyte
value, if possible; otherwise returnsorElse
if thisValue
can't be converted into a primitivebyte
value.char
charValue()
Converts thisValue
into a primitivechar
value, if possible.char
charValue(char orElse)
Converts thisValue
into a primitivechar
value, if possible; otherwise returnsorElse
if thisValue
can't be converted into a primitivechar
value.Text
commit()
int
compareTo(Item other)
<T> Output<T>
debug(Output<T> output)
Writes a developer readable, debug-formatted string representation of this object tooutput
.<T> Output<T>
display(Output<T> output)
Writes a human readable, display-formatted string representation of this object tooutput
.double
doubleValue()
Converts thisValue
into a primitivedouble
value, if possible.double
doubleValue(double orElse)
Converts thisValue
into a primitivedouble
value, if possible; otherwise returnsorElse
if thisValue
can't be converted into a primitivedouble
value.static Text
empty()
boolean
equals(Object other)
float
floatValue()
Converts thisValue
into a primitivefloat
value, if possible.float
floatValue(float orElse)
Converts thisValue
into a primitivefloat
value, if possible; otherwise returnsorElse
if thisValue
can't be converted into a primitivefloat
value.static Text
from(String value)
static Text
fromObject(Object object)
int
hashCode()
BigInteger
integerValue()
Converts thisValue
into aBigInteger
value, if possible.BigInteger
integerValue(BigInteger orElse)
Converts thisValue
into aBigInteger
value, if possible; otherwise returnsorElse
if thisValue
can't be converted into aBigInteger
value.int
intValue()
Converts thisValue
into a primitiveint
value, if possible.int
intValue(int orElse)
Converts thisValue
into a primitiveint
value, if possible; otherwise returnsorElse
if thisValue
can't be converted into a primitiveint
value.boolean
isConstant()
long
longValue()
Converts thisValue
into a primitivelong
value, if possible.long
longValue(long orElse)
Converts thisValue
into a primitivelong
value, if possible; otherwise returnsorElse
if thisValue
can't be converted into a primitivelong
value.Number
numberValue()
Converts thisValue
into aNumber
object, if possible.Number
numberValue(Number orElse)
Converts thisValue
into aNumber
object, if possible; otherwise returnsorElse
if thisValue
can't be converted into aNumber
object.static Output<Text>
output()
static Output<Text>
output(OutputSettings settings)
Text
plus(Text that)
Value
plus(Value that)
short
shortValue()
Converts thisValue
into a primitiveshort
value, if possible.short
shortValue(short orElse)
Converts thisValue
into a primitiveshort
value, if possible; otherwise returnsorElse
if thisValue
can't be converted into a primitiveshort
value.int
size()
String
stringValue()
Converts thisValue
into aString
value, if possible.String
stringValue(String orElse)
Converts thisValue
into aString
value, if possible; otherwise returnsorElse
if thisValue
can't be converted into astring
value.int
typeOrder()
Returns the heterogeneous sort order of thisItem
.-
Methods inherited from class swim.structure.Value
absent, alias, and, and, bitwiseAnd, bitwiseAnd, bitwiseNot, bitwiseOr, bitwiseOr, bitwiseXor, bitwiseXor, body, builder, conditional, conditional, contains, containsKey, containsKey, containsValue, divide, divide, eq, eq, extant, flattened, ge, ge, get, get, getAttr, getAttr, getField, getField, getItem, getSlot, getSlot, gt, gt, head, header, headers, inverse, isAliased, isDefined, isDefinite, isDistinct, isMutable, key, keyEquals, lambda, le, le, length, lt, lt, minus, minus, modulo, modulo, ne, ne, negative, not, or, or, plus, positive, removed, removed, tag, tail, target, times, times, toValue, unflattened
-
Methods inherited from class swim.structure.Item
appended, appended, appended, appended, appended, appended, appended, appended, cast, cast, coerce, coerce, concat, evaluate, evaluate, filter, filter, globalScope, invoke, iterator, max, min, precedence, prepended, prepended, prepended, prepended, prepended, prepended, prepended, prepended, substitute, substitute, toString, updated, updated, updated, updated, updated, updated, updated, updated, updated, updated, updated, updated, updated, updated, updatedAttr, updatedAttr, updatedAttr, updatedAttr, updatedAttr, updatedAttr, updatedAttr, updatedAttr, updatedAttr, updatedAttr, updatedAttr, updatedAttr, updatedAttr, updatedAttr, updatedSlot, updatedSlot, updatedSlot, updatedSlot, updatedSlot, updatedSlot, updatedSlot, updatedSlot, updatedSlot, updatedSlot, updatedSlot, updatedSlot, updatedSlot, updatedSlot
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface java.lang.Iterable
forEach, spliterator
-
-
-
-
Field Detail
-
value
protected final String value
-
-
Constructor Detail
-
Text
protected Text(String value)
-
-
Method Detail
-
isConstant
public boolean isConstant()
Description copied from class:Item
- Specified by:
isConstant
in classItem
-
size
public int size()
-
stringValue
public String stringValue()
Description copied from class:Value
Converts thisValue
into aString
value, if possible.- Overrides:
stringValue
in classValue
-
stringValue
public String stringValue(String orElse)
Description copied from class:Value
Converts thisValue
into aString
value, if possible; otherwise returnsorElse
if thisValue
can't be converted into astring
value.- Overrides:
stringValue
in classValue
-
byteValue
public byte byteValue()
Description copied from class:Value
Converts thisValue
into a primitivebyte
value, if possible.
-
byteValue
public byte byteValue(byte orElse)
Description copied from class:Value
Converts thisValue
into a primitivebyte
value, if possible; otherwise returnsorElse
if thisValue
can't be converted into a primitivebyte
value.
-
shortValue
public short shortValue()
Description copied from class:Value
Converts thisValue
into a primitiveshort
value, if possible.- Overrides:
shortValue
in classValue
-
shortValue
public short shortValue(short orElse)
Description copied from class:Value
Converts thisValue
into a primitiveshort
value, if possible; otherwise returnsorElse
if thisValue
can't be converted into a primitiveshort
value.- Overrides:
shortValue
in classValue
-
intValue
public int intValue()
Description copied from class:Value
Converts thisValue
into a primitiveint
value, if possible.
-
intValue
public int intValue(int orElse)
Description copied from class:Value
Converts thisValue
into a primitiveint
value, if possible; otherwise returnsorElse
if thisValue
can't be converted into a primitiveint
value.
-
longValue
public long longValue()
Description copied from class:Value
Converts thisValue
into a primitivelong
value, if possible.
-
longValue
public long longValue(long orElse)
Description copied from class:Value
Converts thisValue
into a primitivelong
value, if possible; otherwise returnsorElse
if thisValue
can't be converted into a primitivelong
value.
-
floatValue
public float floatValue()
Description copied from class:Value
Converts thisValue
into a primitivefloat
value, if possible.- Overrides:
floatValue
in classValue
-
floatValue
public float floatValue(float orElse)
Description copied from class:Value
Converts thisValue
into a primitivefloat
value, if possible; otherwise returnsorElse
if thisValue
can't be converted into a primitivefloat
value.- Overrides:
floatValue
in classValue
-
doubleValue
public double doubleValue()
Description copied from class:Value
Converts thisValue
into a primitivedouble
value, if possible.- Overrides:
doubleValue
in classValue
-
doubleValue
public double doubleValue(double orElse)
Description copied from class:Value
Converts thisValue
into a primitivedouble
value, if possible; otherwise returnsorElse
if thisValue
can't be converted into a primitivedouble
value.- Overrides:
doubleValue
in classValue
-
integerValue
public BigInteger integerValue()
Description copied from class:Value
Converts thisValue
into aBigInteger
value, if possible.- Overrides:
integerValue
in classValue
-
integerValue
public BigInteger integerValue(BigInteger orElse)
Description copied from class:Value
Converts thisValue
into aBigInteger
value, if possible; otherwise returnsorElse
if thisValue
can't be converted into aBigInteger
value.- Overrides:
integerValue
in classValue
-
numberValue
public Number numberValue()
Description copied from class:Value
Converts thisValue
into aNumber
object, if possible.- Overrides:
numberValue
in classValue
-
numberValue
public Number numberValue(Number orElse)
Description copied from class:Value
Converts thisValue
into aNumber
object, if possible; otherwise returnsorElse
if thisValue
can't be converted into aNumber
object.- Overrides:
numberValue
in classValue
-
charValue
public char charValue()
Description copied from class:Value
Converts thisValue
into a primitivechar
value, if possible.
-
charValue
public char charValue(char orElse)
Description copied from class:Value
Converts thisValue
into a primitivechar
value, if possible; otherwise returnsorElse
if thisValue
can't be converted into a primitivechar
value.
-
booleanValue
public boolean booleanValue()
Description copied from class:Value
Converts thisValue
into a primitiveboolean
value, if possible.- Overrides:
booleanValue
in classValue
-
booleanValue
public boolean booleanValue(boolean orElse)
Description copied from class:Value
Converts thisValue
into a primitiveboolean
value, if possible; otherwise returnsorElse
if thisValue
can't be converted into a primitiveboolean
value.- Overrides:
booleanValue
in classValue
-
typeOrder
public int typeOrder()
Description copied from class:Item
Returns the heterogeneous sort order of thisItem
. Used to impose a total order on the set of all items. When comparing two items of different types, the items order according to theirtypeOrder
.
-
compareTo
public final int compareTo(Item other)
- Specified by:
compareTo
in interfaceComparable<Item>
- Specified by:
compareTo
in classItem
-
debug
public <T> Output<T> debug(Output<T> output)
Description copied from interface:Debug
Writes a developer readable, debug-formatted string representation of this object tooutput
.
-
display
public <T> Output<T> display(Output<T> output)
Description copied from interface:Display
Writes a human readable, display-formatted string representation of this object tooutput
.
-
empty
public static Text empty()
-
output
public static Output<Text> output(OutputSettings settings)
-
-