Class VariableList
java.lang.Object
me.topchetoeu.j2s.compilation.scope.VariableList
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionVariableList
(VariableIndex.IndexType type, int offset) VariableList
(VariableIndex.IndexType type, IntSupplier offset) VariableList
(VariableIndex.IndexType type, VariableList prev) -
Method Summary
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface java.lang.Iterable
forEach, spliterator
-
Field Details
-
indexType
-
-
Constructor Details
-
VariableList
- Parameters:
offset
- Will offset the indices by the given amount from the supplier
-
VariableList
- Parameters:
offset
- Will offset the indices by the given amount
-
VariableList
- Parameters:
prev
- Will offset the indices by the size of the given list
-
VariableList
-
-
Method Details
-
add
Adds the given variable to this list. If it already exists, does nothing- Returns:
- val
-
remove
If the variable is not in the list, does nothing. Otherwise, removes the variable from the list- Returns:
- null if nothing was done, else the deleted variable (should be var)
-
has
Checks if the list has the given variable -
indexer
Returns an indexer for the given variable -
size
public int size() -
iterator
-