Package dev.webfx.platform.ast
Class ReadOnlyAstArrayWrapper
java.lang.Object
dev.webfx.platform.ast.ReadOnlyAstArrayWrapper
- All Implemented Interfaces:
ReadOnlyAstArray,ReadOnlyAstNode,Iterable<Object>
- Direct Known Subclasses:
ConfigArray
- Author:
- Bruno Salmon
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription<V> VgetElement(int index) Return the ith element of the array.protected ReadOnlyAstArrayintReturns the first index of the given value, or -1 if it cannot be found.intsize()Length of the array or number of keys of the objectMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface java.lang.Iterable
forEach, spliteratorMethods inherited from interface dev.webfx.platform.ast.ReadOnlyAstArray
getArray, getBoolean, getBoolean, getDouble, getDouble, getInteger, getInteger, getLong, getLong, getObject, getScalar, getScalar, getString, getString, isArray, isNull, isObject, isScalar, iterator
-
Constructor Details
-
ReadOnlyAstArrayWrapper
-
-
Method Details
-
getWrappedArray
-
size
public int size()Description copied from interface:ReadOnlyAstArrayLength of the array or number of keys of the object- Specified by:
sizein interfaceReadOnlyAstArray- Specified by:
sizein interfaceReadOnlyAstNode
-
indexOf
Description copied from interface:ReadOnlyAstArrayReturns the first index of the given value, or -1 if it cannot be found.- Specified by:
indexOfin interfaceReadOnlyAstArray
-
getElement
public <V> V getElement(int index) Description copied from interface:ReadOnlyAstArrayReturn the ith element of the array. Most consuming call.- Specified by:
getElementin interfaceReadOnlyAstArray
-