net.sourceforge.combean.interfaces.graph.containers
Interface NodeStack

Package class diagram package NodeStack
All Superinterfaces:
FixedNodeCollection
All Known Implementing Classes:
StackAsNodeStack

public interface NodeStack
extends FixedNodeCollection

A simple stack with the possibility to push and pop nodes.


Method Summary
 Node peek()
          Get the node on top of the stack without removing it.
 Node pop()
          Get the node on top of the stack and remove it.
 Node push(Node v)
          Put a node on top of the stack.
 
Methods inherited from interface net.sourceforge.combean.interfaces.graph.containers.FixedNodeCollection
isEmpty, iterator
 

Method Detail

peek

Node peek()
Get the node on top of the stack without removing it.

Returns:
the node on top of the stack
Throws:
EmptyStackException

pop

Node pop()
Get the node on top of the stack and remove it.

Returns:
the node on top of the stack
Throws:
EmptyStackException

push

Node push(Node v)
Put a node on top of the stack.

Parameters:
v - the node to add to the stack
Returns:
the node which has been added