|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectcom.tensegrity.graphics.interaction.DefaultInteractionDescriptor
The DefaultInteractionDescriptor class is the default
implementation if the InteractionDescriptor interface.
| Field Summary |
| Fields inherited from interface com.tensegrity.graphics.interaction.InteractionDescriptor |
ITEM_INDEX_NONE |
| Constructor Summary | |
DefaultInteractionDescriptor(java.util.List items,
int indexMoveItem)
Constructor for DefaultInteractionDescriptor. |
|
| Method Summary | |
void |
addItem(InteractionItem item)
Adds the item given by item to the
InteractionDescriptor. |
InteractionItem |
getItem(int index)
Returns the InteractionItem at the index given by
index. |
InteractionItem |
getMoveItem()
Returns the InteractionItem that moves the
BaseInteractable or null if there is no item that moves the whole
BaseInteractable. |
int |
indexOf(InteractionItem item)
Returns the index for the InteractionItem given by
item. |
int |
indexOfMoveItem()
Returns the index of the 'move' InteractionItem or
InteractionDescriptor.ITEM_INDEX_NONE if no 'move' InteractionItem is
available. |
int |
itemCount()
Returns the number of InteractionItems currently available
for the InteractionDescriptor. |
java.util.Iterator |
iteratorItems()
This method returns an iterator which steps over the InteractionItems provided by this
InteractionDescriptor object. |
void |
removeItem(int index)
Removes the item at the index given by index from the
InteractionDescriptor. |
void |
removeItem(InteractionItem item)
Removes the InteractionItem given by item from
the InteractionDescriptor. |
java.lang.String |
toString()
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
public DefaultInteractionDescriptor(java.util.List items,
int indexMoveItem)
DefaultInteractionDescriptor.
| Method Detail |
public int itemCount()
InteractionDescriptorInteractionItems currently available
for the InteractionDescriptor.
itemCount in interface InteractionDescriptorInteractionItemspublic int indexOf(InteractionItem item)
InteractionDescriptorInteractionItem given by
item.
indexOf in interface InteractionDescriptoritem - the InteractionItem to return the index for
InteractionItempublic int indexOfMoveItem()
InteractionDescriptorInteractionItem or
InteractionDescriptor.ITEM_INDEX_NONE if no 'move' InteractionItem is
available.
indexOfMoveItem in interface InteractionDescriptorInteractionItem or
InteractionDescriptor.ITEM_INDEX_NONEpublic void addItem(InteractionItem item)
InteractionDescriptoritem to the
InteractionDescriptor.
addItem in interface InteractionDescriptoritem - the InteractionItem to addpublic void removeItem(int index)
InteractionDescriptorindex from the
InteractionDescriptor.
removeItem in interface InteractionDescriptorindex - the index of the InteractionItem to removepublic void removeItem(InteractionItem item)
InteractionDescriptorInteractionItem given by item from
the InteractionDescriptor.
removeItem in interface InteractionDescriptoritem - the InteactionDescriptor to removepublic InteractionItem getItem(int index)
InteractionDescriptorInteractionItem at the index given by
index.
getItem in interface InteractionDescriptorindex - the index of the InteractionItem to return
InteractionItem at the given
indexpublic java.util.Iterator iteratorItems()
InteractionDescriptorInteractionItems provided by this
InteractionDescriptor object.
iteratorItems in interface InteractionDescriptorpublic InteractionItem getMoveItem()
InteractionDescriptorInteractionItem that moves the
BaseInteractable or null if there is no item that moves the whole
BaseInteractable.
getMoveItem in interface InteractionDescriptorBaseInteractablepublic java.lang.String toString()
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||