de.pado.dv
Class Path

java.lang.Object
  extended by java.util.AbstractCollection
      extended by java.util.AbstractList
          extended by java.util.ArrayList
              extended by de.pado.dv.Path
All Implemented Interfaces:
java.io.Serializable, java.lang.Cloneable, java.lang.Iterable, java.util.Collection, java.util.List, java.util.RandomAccess

public class Path
extends java.util.ArrayList

A Path is a list of Edges.

See Also:
Serialized Form

Field Summary
 
Fields inherited from class java.util.AbstractList
modCount
 
Constructor Summary
Path()
          Initialises an empty path.
Path(java.lang.String s)
          Constructs a Path from a string representation of a path
 
Method Summary
 void addEdge(Edge e)
          Add an Edge to a Path
 java.util.HashSet relSet()
          Returns the set of all relations on the Path.
 java.lang.String toString()
          Returns a string representation of a Path: Edge1=Edge2=...
 java.util.Set yield()
          returns the set of all nodes which are touched by the Path.
 
Methods inherited from class java.util.ArrayList
add, add, addAll, addAll, clear, clone, contains, ensureCapacity, get, indexOf, isEmpty, lastIndexOf, remove, remove, removeRange, set, size, toArray, toArray, trimToSize
 
Methods inherited from class java.util.AbstractList
equals, hashCode, iterator, listIterator, listIterator, subList
 
Methods inherited from class java.util.AbstractCollection
containsAll, removeAll, retainAll
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface java.util.List
containsAll, equals, hashCode, iterator, listIterator, listIterator, removeAll, retainAll, subList
 

Constructor Detail

Path

public Path(java.lang.String s)
Constructs a Path from a string representation of a path


Path

public Path()
Initialises an empty path.

Method Detail

addEdge

public void addEdge(Edge e)
Add an Edge to a Path


yield

public java.util.Set yield()
returns the set of all nodes which are touched by the Path. Note that this is a set, so there won't be any duplicates.


relSet

public java.util.HashSet relSet()
Returns the set of all relations on the Path. Note that this is a set, so there won't be any duplicates.


toString

public java.lang.String toString()
Returns a string representation of a Path: Edge1=Edge2=...

Overrides:
toString in class java.util.AbstractCollection