MaltParser 1.0.1

org.maltparser.parser.algorithm.helper
Class Transition

java.lang.Object
  extended by org.maltparser.parser.algorithm.helper.Transition
All Implemented Interfaces:
Comparable<Transition>

public class Transition
extends Object
implements Comparable<Transition>

Transition contains one individual transition. For example, Nivre arc-eager algorithms have the unlabeled transition SH, RE and the labeled transitionRA, LA. These transition will be four individual transition.

Since:
1.0
Author:
Joakim Nivre, Johan Hall

Constructor Summary
Transition(int code, String name, boolean labeled)
          Creates a transition
 
Method Summary
 int compareTo(Transition o)
           
 boolean equals(Object o)
           
 int getCode()
          Returns the transition code
 String getName()
          Returns the transition name
 boolean isLabeled()
          Returns true if the transition is labeled, otherwise false
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Transition

public Transition(int code,
                  String name,
                  boolean labeled)
Creates a transition

Parameters:
code - Transition code
name - Transition name
labeled - true if the transition is labeled, otherwise false
Method Detail

getCode

public int getCode()
Returns the transition code

Returns:
the transition code

getName

public String getName()
Returns the transition name

Returns:
the transition name

isLabeled

public boolean isLabeled()
Returns true if the transition is labeled, otherwise false

Returns:
true if the transition is labeled, otherwise false

compareTo

public int compareTo(Transition o)
Specified by:
compareTo in interface Comparable<Transition>

equals

public boolean equals(Object o)
Overrides:
equals in class Object

toString

public String toString()
Overrides:
toString in class Object

MaltParser 1.0.1

Copyright 2007 Johan Hall, Jens Nilsson and Joakim Nivre.