JsBigDec
, JsBigInt
, JsBool
, JsDouble
, JsInt
, JsLong
, JsNothing
, JsNull
, JsStr
public interface JsElem
Modifier and Type | Method | Description |
---|---|---|
default JsArray |
asJsArray() |
|
default JsBigDec |
asJsBigDec() |
|
default JsBigInt |
asJsBigInt() |
|
default JsBool |
asJsBool() |
|
default JsDouble |
asJsDouble() |
|
default JsInt |
asJsInt() |
|
default JsLong |
asJsLong() |
|
default JsObj |
asJsObj() |
|
default Json<?> |
asJson() |
|
default JsStr |
asJsStr() |
|
default boolean |
isArray() |
|
default boolean |
isArray(Predicate<JsArray> predicate) |
Returns true if this elem is a JsArray and satisfies the given predicate
|
default boolean |
isBigDec() |
|
default boolean |
isBigDec(Predicate<BigDecimal> predicate) |
Returns true if this elem is a JsBigDec and satisfies the given predicate
|
default boolean |
isBigInt() |
|
default boolean |
isBigInt(Predicate<BigInteger> predicate) |
Returns true if this elem is a JsBigInt and satisfies the given predicate
|
default boolean |
isBool() |
|
default boolean |
isDouble() |
|
default boolean |
isDouble(DoublePredicate predicate) |
Returns true if this elem is a JsDouble and satisfies the given predicate
|
default boolean |
isFalse() |
|
default boolean |
isInstant() |
|
default boolean |
isInstant(Predicate<Instant> predicate) |
Returns true if this elem is a JsStr that contains an Instant and satisfies the given predicate
|
default boolean |
isInt() |
|
default boolean |
isInt(IntPredicate predicate) |
Returns true if this elem is a JsInt and satisfies the given predicate
|
default boolean |
isIntegral() |
|
default boolean |
isJson() |
|
default boolean |
isJson(Predicate<Json<?>> predicate) |
Returns true if this elem is a Json and satisfies the given predicate
|
default boolean |
isLocalDate(DateTimeFormatter formatter) |
return true if this JsElem is a JsStr that contains a local date that can be parsed with the given formatter
|
default boolean |
isLocalDate(DateTimeFormatter formatter,
Predicate<LocalDate> predicate) |
return true if this JsElem is a JsStr that contains a local date that can be parsed with the given formatter
and satisfies the given predicate
|
default boolean |
isLocalDateTime(DateTimeFormatter formatter) |
return true if this JsElem is a JsStr that contains a local date-time that can be parsed with the given formatter
|
default boolean |
isLocalDateTime(DateTimeFormatter formatter,
Predicate<LocalDateTime> predicate) |
return true if this JsElem is a JsStr that contains a local date-time that can be parsed with the given formatter
and satisfies the given predicate
|
default boolean |
isLong() |
|
default boolean |
isLong(LongPredicate predicate) |
Returns true if this elem is a JsLong and satisfies the given predicate
|
default boolean |
isNothing() |
|
default boolean |
isNotJson() |
|
default boolean |
isNotNothing() |
|
default boolean |
isNotNull() |
|
default boolean |
isNotNumber() |
|
default boolean |
isNull() |
|
default boolean |
isNumber() |
|
default boolean |
isObj() |
|
default boolean |
isObj(Predicate<JsObj> predicate) |
Returns true if this elem is a JsObj and satisfies the given predicate
|
default boolean |
isStr() |
|
default boolean |
isStr(Predicate<String> predicate) |
Returns true if this elem is a JsStr and satisfies the given predicate
|
default boolean |
isTrue() |
default JsBool asJsBool()
UnsupportedOperationException
- if this JsElem is not a JsBooldefault boolean isBool()
default boolean isTrue()
default boolean isFalse()
default JsInt asJsInt()
UnsupportedOperationException
- if this JsElem is not a JsIntdefault boolean isInt()
default boolean isInt(IntPredicate predicate)
predicate
- the given predicatedefault JsDouble asJsDouble()
UnsupportedOperationException
- if this JsElem is not a JsDoubledefault boolean isDouble()
default boolean isDouble(DoublePredicate predicate)
predicate
- the given predicatedefault JsBigDec asJsBigDec()
UnsupportedOperationException
- if this JsElem is not a JsBigDec or a JsDoubledefault boolean isBigDec()
default boolean isBigDec(Predicate<BigDecimal> predicate)
predicate
- the given predicatedefault JsLong asJsLong()
UnsupportedOperationException
- if this JsElem is not a JsLong or a JsIntdefault boolean isLong()
default boolean isLong(LongPredicate predicate)
predicate
- the given predicatedefault Json<?> asJson()
UnsupportedOperationException
- if this JsElem is not a JsObj or a JsArraydefault boolean isJson()
default boolean isNotJson()
default boolean isJson(Predicate<Json<?>> predicate)
predicate
- the given predicatedefault JsObj asJsObj()
UnsupportedOperationException
- if this JsElem is not a JsObjdefault boolean isObj()
default boolean isObj(Predicate<JsObj> predicate)
predicate
- the given predicatedefault JsArray asJsArray()
UnsupportedOperationException
- if this JsElem is not a JsArraydefault boolean isArray()
default boolean isArray(Predicate<JsArray> predicate)
predicate
- the given predicatedefault JsStr asJsStr()
UnsupportedOperationException
- if this JsElem is not a JsStrdefault boolean isStr()
default boolean isStr(Predicate<String> predicate)
predicate
- the given predicatedefault JsBigInt asJsBigInt()
UnsupportedOperationException
- if this JsElem is not a JsBigInt or JsLong or JsIntdefault boolean isBigInt()
default boolean isBigInt(Predicate<BigInteger> predicate)
predicate
- the given predicatedefault boolean isInstant()
DateTimeFormatter.ISO_INSTANT
default boolean isInstant(Predicate<Instant> predicate)
predicate
- the given predicatedefault boolean isLocalDate(DateTimeFormatter formatter)
formatter
- the given formatterdefault boolean isLocalDate(DateTimeFormatter formatter, Predicate<LocalDate> predicate)
formatter
- the given formatterpredicate
- the given predicatedefault boolean isLocalDateTime(DateTimeFormatter formatter)
formatter
- the given formatterdefault boolean isLocalDateTime(DateTimeFormatter formatter, Predicate<LocalDateTime> predicate)
formatter
- the given formatterpredicate
- the given predicatedefault boolean isIntegral()
default boolean isNull()
default boolean isNothing()
default boolean isNotNull()
default boolean isNotNothing()
default boolean isNumber()
default boolean isNotNumber()
Copyright © 2019. All rights reserved.