public abstract class IndexedItem extends Item
| Constructor and Description |
|---|
IndexedItem()
Constructs an instance.
|
| Modifier and Type | Method and Description |
|---|---|
int |
getIndex()
Gets the item index.
|
boolean |
hasIndex()
Gets whether or not this instance has been assigned an index.
|
java.lang.String |
indexString()
Gets the index of this item as a string, suitable for including in
annotations.
|
void |
setIndex(int index)
Sets the item index.
|
public IndexedItem()
public final boolean hasIndex()
true iff this instance has been assigned an indexpublic final int getIndex()
>= 0; the indexjava.lang.RuntimeException - thrown if the item index is not yet assignedpublic final void setIndex(int index)
RuntimeException if
called a second (or subsequent) time.index - >= 0; the item indexpublic final java.lang.String indexString()
non-null; the index stringCopyright © 2020. All Rights Reserved.