Package org.biojava.bio.dp
Class Transition
- java.lang.Object
-
- org.biojava.bio.dp.Transition
-
- All Implemented Interfaces:
Serializable
public class Transition extends Object implements Serializable
This is a small and ugly class for storing a transition. It is hash-code-able, and has a sensible equality operator.- Author:
- Matthew Pocock
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description Transition(State from, State to)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object o)Two transitions are equal if they have the same from and to states.inthashCode()The hash code is from.hashCode() ^ to.hashCode()
-
-
-
Constructor Detail
-
Transition
public Transition(State from, State to)
-
-
Method Detail
-
equals
public boolean equals(Object o) throws ClassCastException
Two transitions are equal if they have the same from and to states.- Overrides:
equalsin classObject- Throws:
ClassCastException
-
-