Package dev.webfx.platform.ast
Interface ReadOnlyAstObject
- All Superinterfaces:
ReadOnlyAstNode
- All Known Subinterfaces:
AstObject
,Config
,NativeAstObject
- All Known Implementing Classes:
AstObjectWrapper
,ChildConfig
,ConfigImpl
,ImmutableAstObject
,MapAstObject
,MapBasedAstObject
,ReadOnlyAstObjectWrapper
,ReadOnlyMergedAstObject
,RootConfig
- Author:
- Bruno Salmon
-
Method Summary
Modifier and TypeMethodDescription<T> T
Return the element as a value or wrapped object/array.default ReadOnlyAstArray
Return the element as a JsonArray.default Boolean
getBoolean
(String key) Return the element as a boolean.default Boolean
getBoolean
(String key, Boolean defaultValue) Return the element as a boolean.default Double
Return the element as a double.default Double
Return the element as a double.default Instant
getInstant
(String key) Return the element as an instant.default Instant
getInstant
(String key, Instant defaultValue) Return the element as an instant.default Integer
getInteger
(String key) Return the element as an int.default Integer
getInteger
(String key, Integer defaultValue) Return the element as an int.default Long
Return the element as a long.default Long
Return the element as a long.default ReadOnlyAstObject
Return the element as a JsonObject.default <T> T
default <T> T
default String
Return the element as a String.default String
Return the element as a String.default boolean
Test whether a given key has present.default boolean
default boolean
default boolean
default boolean
keys()
All keys of the object.default int
size()
-
Method Details
-
has
Test whether a given key has present. -
keys
ReadOnlyAstArray keys()All keys of the object. -
size
default int size()- Specified by:
size
in interfaceReadOnlyAstNode
-
get
Return the element as a value or wrapped object/array. -
isObject
-
isArray
-
isScalar
-
getObject
Return the element as a JsonObject. If the type is not an object, this can result in runtime errors. -
getArray
Return the element as a JsonArray. If the type is not an array, this can result in runtime errors. -
getScalar
-
getScalar
-
isTrue
-
getBoolean
Return the element as a boolean. If the type is not a boolean, this can result in runtime errors. -
getBoolean
Return the element as a boolean. If the type is not a boolean, this can result in runtime errors. -
getString
Return the element as a String. If the type is not a String, this can result in runtime errors. -
getString
Return the element as a String. If the type is not a String, this can result in runtime errors. -
getInteger
Return the element as an int. If the type is not a int, this can result in runtime errors. -
getInteger
Return the element as an int. If the type is not a int, this can result in runtime errors. -
getLong
Return the element as a long. If the type is not a long, this can result in runtime errors. -
getLong
Return the element as a long. If the type is not a long, this can result in runtime errors. -
getDouble
Return the element as a double. If the type is not a double, this can result in runtime errors. -
getDouble
Return the element as a double. If the type is not a double, this can result in runtime errors. -
getInstant
Return the element as an instant. If the type is not an instant, this can result in runtime errors. -
getInstant
Return the element as an instant. If the type is not an instant, this can result in runtime errors.
-