- java.lang.Object
-
- swim.structure.Item
-
- swim.structure.Field
-
-
Method Summary
Modifier and Type Method Description Fieldand(Field that)Itemand(Item that)Valuebody()Always returnsAbsentbecause aFieldcan't be aRecord, so it can't have any non-first members to flatten, and because aFieldisn't a distinctValue, so it can't returnExtant.booleanbooleanValue()Converts the value of thisFieldinto a primitivebooleanvalue, if possible.booleanbooleanValue(boolean orElse)Converts the value of thisFieldinto a primitivebooleanvalue, if possible; otherwise returnsorElseif the value of thisFieldcan't be converted into a primitivebooleanvalue.abstract Fieldbranch()bytebyteValue()Converts the value of thisFieldinto a primitivebytevalue, if possible.bytebyteValue(byte orElse)Converts the value of thisFieldinto a primitivebytevalue, if possible; otherwise returnsorElseif the value of thisFieldcan't be converted into a primitivebytevalue.charcharValue()Converts the value of thisFieldinto a primitivecharvalue, if possible.charcharValue(char orElse)Converts the value of thisFieldinto a primitivecharvalue, if possible; otherwise returnsorElseif the value of thisFieldcan't be converted into a primitivecharvalue.abstract Fieldcommit()Fieldconditional(Field thenTerm, Field elseTerm)Itemconditional(Item thenTerm, Item elseTerm)booleancontains(Item item)Always returnsfalsebecause aFieldcan't be aRecord, so it can't have a member equal toitem.booleancontainsKey(String key)Always returnsfalsebecause aFieldcan't be aRecord, so it can't have aFieldmember whose key string is equal to the givenkey.booleancontainsKey(Value key)Always returnsfalsebecause aFieldcan't be aRecord, so it can't have aFieldmember whose key is equal to the givenkey.booleancontainsValue(Value value)Always returnsfalsebecause aFieldcan't be aRecord, so it can't have aFieldmember whose value is equal to the givenvalue.doubledoubleValue()Converts the value of thisFieldinto a primitivedoublevalue, if possible.doubledoubleValue(double orElse)Converts the value of thisFieldinto a primitivedoublevalue, if possible; otherwise returnsorElseif the value of thisFieldcan't be converted into a primitivedoublevalue.Valueflattened()floatfloatValue()Converts the value of thisFieldinto a primitivefloatvalue, if possible.floatfloatValue(float orElse)Converts the value of thisFieldinto a primitivefloatvalue, if possible; otherwise returnsorElseif the value of thisFieldcan't be converted into a primitivefloatvalue.Valueget(String key)Always returnsAbsentbecause aFieldcan't be aRecord, so it can't have aFieldmember whose key string is equal to the givenkey.Valueget(Value key)Always returnsAbsentbecause aFieldcan't be aRecord, so it can't have aFieldmember whose key is equal to the givenkey.ValuegetAttr(String key)Always returnsAbsentbecause aFieldcan't be aRecord, so it can't have anAttrmember whose key string is equal to the givenkey.ValuegetAttr(Text key)Always returnsAbsentbecause aFieldcan't be aRecord, so it can't have anAttrmember whose key is equal to the givenkey.FieldgetField(String key)Always returnsnullbecause aFieldcan't be aRecord, so it can't have aFieldmember whose key string is equal to the givenkey.FieldgetField(Value key)Always returnsnullbecause aFieldcan't be aRecord, so it can't have aFieldmember whose key is equal to the givenkey.ItemgetItem(int index)Always returnsAbsentbecause aFieldcan't be aRecord, so it can't have a member at the givenindex.ValuegetKey()Returns the key component of thisField.ValuegetSlot(String key)Always returnsAbsentbecause aFieldcan't be aRecord, so it can't have aSlotmember whose key string is equal to the givenkey.ValuegetSlot(Value key)Always returnsAbsentbecause aFieldcan't be aRecord, so it can't have aSlotmember whose key is equal to the givenkey.ValuegetValue()Returns the value component of thisField.Itemhead()Valueheader(String tag)Always returnsAbsentbecause aFieldcan't be aRecord, so it can't have a headAttrwhose value could be returned if its key were equal to thetag.Recordheaders(String tag)Always returnsnullbecause aFieldcan't be aRecord, so it can't have a headAttrwhose value could be returned as aRecordif its key is equal to thetag.BigIntegerintegerValue()Converts the value of thisFieldinto aBigIntegervalue, if possible.BigIntegerintegerValue(BigInteger orElse)Converts the value of thisFieldinto aBigIntegervalue, if possible; otherwise returnsorElseif the value of thisFieldcan't be converted into aBigIntegervalue.intintValue()Converts the value of thisFieldinto a primitiveintvalue, if possible.intintValue(int orElse)Converts the value of thisFieldinto a primitiveintvalue, if possible; otherwise returnsorElseif the value of thisFieldcan't be converted into a primitiveintvalue.booleanisDefined()booleanisDistinct()abstract Valuekey()Returns the key component of thisField.Valuelambda(Value template)intlength()Always returns0because aFieldcan't be aRecord, so it can't contain any members.longlongValue()Converts the value of thisFieldinto a primitivelongvalue, if possible.longlongValue(long orElse)Converts the value of thisFieldinto a primitivelongvalue, if possible; otherwise returnsorElseif the value of thisFieldcan't be converted into a primitivelongvalue.NumbernumberValue()Converts the value of thisFieldinto aNumberobject, if possible.NumbernumberValue(Number orElse)Converts the value of thisFieldinto aNumberobject, if possible; otherwise returnsorElseif the value of thisFieldcan't be converted into aNumberobject.static Fieldof(Object object)Fieldor(Field that)Itemor(Item that)Fieldremoved(String key)Fieldremoved(Value key)abstract ValuesetValue(Value value)Sets the value of thisFieldto the newvalue, returning the old value.shortshortValue()Converts the value of thisFieldinto a primitiveshortvalue, if possible.shortshortValue(short orElse)Converts the value of thisFieldinto a primitiveshortvalue, if possible; otherwise returnsorElseif the value of thisFieldcan't be converted into a primitiveshortvalue.StringstringValue()Converts the value of thisFieldinto aStringvalue, if possible.StringstringValue(String orElse)Converts the value of thisFieldinto aStringvalue, if possible; otherwise returnsorElseif the value of thisFieldcan't be converted into astringvalue.Stringtag()Always returnsnullbecause aFieldcan't be aRecord, so it can't have a first memberAttrwhose key string could be returned.Recordtail()Always returns an emptyRecordbecause aFieldcan't itself be aRecord, so it can't have any non-first members.Valuetarget()Always returns the value component of thisField.ValuetoValue()Returns the value component of thisField.Recordunflattened()Returns aRecordcontaining just thisField.abstract FieldupdatedValue(Value value)Returns a copy of thisFieldwith the updatedvalue.abstract Valuevalue()Returns the value component of thisField.-
Methods inherited from class swim.structure.Item
absent, alias, appended, appended, appended, appended, appended, appended, appended, appended, bitwiseAnd, bitwiseNot, bitwiseOr, bitwiseXor, cast, cast, coerce, coerce, compareTo, concat, debug, display, divide, empty, eq, equals, evaluate, evaluate, extant, filter, filter, fromObject, ge, globalScope, gt, hashCode, inverse, invoke, isAliased, isConstant, isMutable, iterator, keyEquals, le, lt, max, min, minus, modulo, ne, negative, not, plus, positive, precedence, prepended, prepended, prepended, prepended, prepended, prepended, prepended, prepended, substitute, substitute, times, toString, typeOrder, 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
-
-
-
-
Method Detail
-
isDistinct
public final boolean isDistinct()
- Specified by:
isDistinctin classItem
-
key
public abstract Value key()
Returns the key component of thisField.
-
value
public abstract Value value()
Returns the value component of thisField.
-
setValue
public abstract Value setValue(Value value)
Sets the value of thisFieldto the newvalue, returning the old value.- Specified by:
setValuein interfaceMap.Entry<Value,Value>- Throws:
UnsupportedOperationException- if thisFieldis immutable.
-
updatedValue
public abstract Field updatedValue(Value value)
Returns a copy of thisFieldwith the updatedvalue.
-
tag
public final String tag()
Always returnsnullbecause aFieldcan't be aRecord, so it can't have a first memberAttrwhose key string could be returned.
-
target
public final Value target()
Always returns the value component of thisField.
-
unflattened
public final Record unflattened()
Returns aRecordcontaining just thisField.- Specified by:
unflattenedin classItem
-
header
public final Value header(String tag)
Always returnsAbsentbecause aFieldcan't be aRecord, so it can't have a headAttrwhose value could be returned if its key were equal to thetag.
-
headers
public final Record headers(String tag)
Always returnsnullbecause aFieldcan't be aRecord, so it can't have a headAttrwhose value could be returned as aRecordif its key is equal to thetag.
-
tail
public final Record tail()
Always returns an emptyRecordbecause aFieldcan't itself be aRecord, so it can't have any non-first members.
-
body
public final Value body()
Always returnsAbsentbecause aFieldcan't be aRecord, so it can't have any non-first members to flatten, and because aFieldisn't a distinctValue, so it can't returnExtant.
-
length
public final int length()
Always returns0because aFieldcan't be aRecord, so it can't contain any members.
-
contains
public final boolean contains(Item item)
Always returnsfalsebecause aFieldcan't be aRecord, so it can't have a member equal toitem.
-
containsKey
public final boolean containsKey(Value key)
Always returnsfalsebecause aFieldcan't be aRecord, so it can't have aFieldmember whose key is equal to the givenkey.- Specified by:
containsKeyin classItem
-
containsKey
public final boolean containsKey(String key)
Always returnsfalsebecause aFieldcan't be aRecord, so it can't have aFieldmember whose key string is equal to the givenkey.- Specified by:
containsKeyin classItem
-
containsValue
public final boolean containsValue(Value value)
Always returnsfalsebecause aFieldcan't be aRecord, so it can't have aFieldmember whose value is equal to the givenvalue.- Specified by:
containsValuein classItem
-
get
public final Value get(Value key)
Always returnsAbsentbecause aFieldcan't be aRecord, so it can't have aFieldmember whose key is equal to the givenkey.
-
get
public final Value get(String key)
Always returnsAbsentbecause aFieldcan't be aRecord, so it can't have aFieldmember whose key string is equal to the givenkey.
-
getAttr
public final Value getAttr(Text key)
Always returnsAbsentbecause aFieldcan't be aRecord, so it can't have anAttrmember whose key is equal to the givenkey.
-
getAttr
public final Value getAttr(String key)
Always returnsAbsentbecause aFieldcan't be aRecord, so it can't have anAttrmember whose key string is equal to the givenkey.
-
getSlot
public final Value getSlot(Value key)
Always returnsAbsentbecause aFieldcan't be aRecord, so it can't have aSlotmember whose key is equal to the givenkey.
-
getSlot
public final Value getSlot(String key)
Always returnsAbsentbecause aFieldcan't be aRecord, so it can't have aSlotmember whose key string is equal to the givenkey.
-
getField
public final Field getField(Value key)
Always returnsnullbecause aFieldcan't be aRecord, so it can't have aFieldmember whose key is equal to the givenkey.
-
getField
public final Field getField(String key)
Always returnsnullbecause aFieldcan't be aRecord, so it can't have aFieldmember whose key string is equal to the givenkey.
-
getItem
public final Item getItem(int index)
Always returnsAbsentbecause aFieldcan't be aRecord, so it can't have a member at the givenindex.
-
conditional
public Item conditional(Item thenTerm, Item elseTerm)
- Specified by:
conditionalin classItem
-
stringValue
public final String stringValue()
Converts the value of thisFieldinto aStringvalue, if possible.- Specified by:
stringValuein classItem- Throws:
UnsupportedOperationException- if the value of thisFieldcan't be converted into aStringvalue.
-
stringValue
public final String stringValue(String orElse)
Converts the value of thisFieldinto aStringvalue, if possible; otherwise returnsorElseif the value of thisFieldcan't be converted into astringvalue.- Specified by:
stringValuein classItem
-
byteValue
public final byte byteValue()
Converts the value of thisFieldinto a primitivebytevalue, if possible.- Specified by:
byteValuein classItem- Throws:
UnsupportedOperationException- if the value of thisFieldcan't be converted into a primitivebytevalue.
-
byteValue
public final byte byteValue(byte orElse)
Converts the value of thisFieldinto a primitivebytevalue, if possible; otherwise returnsorElseif the value of thisFieldcan't be converted into a primitivebytevalue.
-
shortValue
public final short shortValue()
Converts the value of thisFieldinto a primitiveshortvalue, if possible.- Specified by:
shortValuein classItem- Throws:
UnsupportedOperationException- if the value of thisFieldcan't be converted into a primitiveshortvalue.
-
shortValue
public final short shortValue(short orElse)
Converts the value of thisFieldinto a primitiveshortvalue, if possible; otherwise returnsorElseif the value of thisFieldcan't be converted into a primitiveshortvalue.- Specified by:
shortValuein classItem
-
intValue
public final int intValue()
Converts the value of thisFieldinto a primitiveintvalue, if possible.- Specified by:
intValuein classItem- Throws:
UnsupportedOperationException- if the value of thisFieldcan't be converted into a primitiveintvalue.
-
intValue
public final int intValue(int orElse)
Converts the value of thisFieldinto a primitiveintvalue, if possible; otherwise returnsorElseif the value of thisFieldcan't be converted into a primitiveintvalue.
-
longValue
public final long longValue()
Converts the value of thisFieldinto a primitivelongvalue, if possible.- Specified by:
longValuein classItem- Throws:
UnsupportedOperationException- if the value of thisFieldcan't be converted into a primitivelongvalue.
-
longValue
public final long longValue(long orElse)
Converts the value of thisFieldinto a primitivelongvalue, if possible; otherwise returnsorElseif the value of thisFieldcan't be converted into a primitivelongvalue.
-
floatValue
public final float floatValue()
Converts the value of thisFieldinto a primitivefloatvalue, if possible.- Specified by:
floatValuein classItem- Throws:
UnsupportedOperationException- if the value of thisFieldcan't be converted into a primitivefloatvalue.
-
floatValue
public final float floatValue(float orElse)
Converts the value of thisFieldinto a primitivefloatvalue, if possible; otherwise returnsorElseif the value of thisFieldcan't be converted into a primitivefloatvalue.- Specified by:
floatValuein classItem
-
doubleValue
public final double doubleValue()
Converts the value of thisFieldinto a primitivedoublevalue, if possible.- Specified by:
doubleValuein classItem- Throws:
UnsupportedOperationException- if the value of thisFieldcan't be converted into a primitivedoublevalue.
-
doubleValue
public final double doubleValue(double orElse)
Converts the value of thisFieldinto a primitivedoublevalue, if possible; otherwise returnsorElseif the value of thisFieldcan't be converted into a primitivedoublevalue.- Specified by:
doubleValuein classItem
-
integerValue
public final BigInteger integerValue()
Converts the value of thisFieldinto aBigIntegervalue, if possible.- Specified by:
integerValuein classItem- Throws:
UnsupportedOperationException- if the value of thisFieldcan't be converted into aBigIntegervalue.
-
integerValue
public final BigInteger integerValue(BigInteger orElse)
Converts the value of thisFieldinto aBigIntegervalue, if possible; otherwise returnsorElseif the value of thisFieldcan't be converted into aBigIntegervalue.- Specified by:
integerValuein classItem
-
numberValue
public final Number numberValue()
Converts the value of thisFieldinto aNumberobject, if possible.- Specified by:
numberValuein classItem- Throws:
UnsupportedOperationException- if the value of thisFieldcan't be converted into aNumberobject.
-
numberValue
public final Number numberValue(Number orElse)
Converts the value of thisFieldinto aNumberobject, if possible; otherwise returnsorElseif the value of thisFieldcan't be converted into aNumberobject.- Specified by:
numberValuein classItem
-
charValue
public final char charValue()
Converts the value of thisFieldinto a primitivecharvalue, if possible.- Specified by:
charValuein classItem- Throws:
UnsupportedOperationException- if the value of thisFieldcan't be converted into a primitivecharvalue.
-
charValue
public final char charValue(char orElse)
Converts the value of thisFieldinto a primitivecharvalue, if possible; otherwise returnsorElseif the value of thisFieldcan't be converted into a primitivecharvalue.
-
booleanValue
public final boolean booleanValue()
Converts the value of thisFieldinto a primitivebooleanvalue, if possible.- Specified by:
booleanValuein classItem- Throws:
UnsupportedOperationException- if the value of thisFieldcan't be converted into a primitivebooleanvalue.
-
booleanValue
public final boolean booleanValue(boolean orElse)
Converts the value of thisFieldinto a primitivebooleanvalue, if possible; otherwise returnsorElseif the value of thisFieldcan't be converted into a primitivebooleanvalue.- Specified by:
booleanValuein classItem
-
-