Class HalfEdge

java.lang.Object
  extended byHalfEdge
All Implemented Interfaces:
java.lang.Comparable

public class HalfEdge
extends java.lang.Object
implements java.lang.Comparable

This class implements half-edges which are either unary, i.e. a state or binary, i.e. a pair formed by a word and a state or ternary, i.e. triples of two words (input and output) and a state.


Constructor Summary
HalfEdge(int q)
          Creates a unary half-edge.
HalfEdge(java.lang.String s, int q)
          Creates a binary half-edge.
HalfEdge(java.lang.String s, java.lang.String t, int q)
          Creates a ternary half-egde.
 
Method Summary
 int compareTo(java.lang.Object o)
          Overrides the method Object.compareTo.
 boolean equals(java.lang.Object o)
          Overrides the method Object.hashCode.
 int hashCode()
          Overrides the method Object.hashCode.
 java.lang.String toString()
          Overrides the method toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

HalfEdge

public HalfEdge(int q)
Creates a unary half-edge.


HalfEdge

public HalfEdge(java.lang.String s,
                int q)
Creates a binary half-edge.


HalfEdge

public HalfEdge(java.lang.String s,
                java.lang.String t,
                int q)
Creates a ternary half-egde.

Method Detail

compareTo

public int compareTo(java.lang.Object o)
Overrides the method Object.compareTo. Orders the half-edges lexicographically first by end, then by input label and last by output label.

Specified by:
compareTo in interface java.lang.Comparable

equals

public boolean equals(java.lang.Object o)
Overrides the method Object.hashCode.


hashCode

public int hashCode()
Overrides the method Object.hashCode. The hashcode of a half-edge is


toString

public java.lang.String toString()
Overrides the method toString