All Packages  Class Hierarchy  This Package  Previous  Next  Index

Interface jdsl.core.api.Position

public interface Position
Interface for a position. A position formalizes the intuitive notion of the "place" where an element is stored in a positional container (sequence, tree, graph). A node of a tree and a vertex of a graph are examples of positions.

See Also:
PositionalContainer, InvalidPositionException

Method Index

 o container()
Return the container holding this position.
 o element()
Return the element stored at this position.

Methods

 o element
 public abstract Object element() throws InvalidPositionException
Return the element stored at this position.

An InvalidPositionException is thrown if the position is invalid because it was removed from its container.

Returns:
element stored at this position
 o container
 public abstract Container container() throws InvalidPositionException
Return the container holding this position.

An InvalidPositionException is thrown if the position is invalid because it was removed from its container.

Returns:
container holding this position.

All Packages  Class Hierarchy  This Package  Previous  Next  Index