org.cogroo.entities
Class HeadedSpan

java.lang.Object
  extended by opennlp.tools.util.Span
      extended by org.cogroo.entities.HeadedSpan
All Implemented Interfaces:
Comparable<opennlp.tools.util.Span>

public class HeadedSpan
extends opennlp.tools.util.Span


Constructor Summary
HeadedSpan(int s, int e)
          Initializes a new Span Object.
HeadedSpan(int s, int e, String type)
           
HeadedSpan(opennlp.tools.util.Span span, int offset)
          Initializes a new Span object with an existing Span which is shifted by an offset.
 
Method Summary
 boolean equals(Object o)
           
 int getHead()
           
 int hashCode()
           
 void setHead(int headPosition)
           
 String toString()
          Generates a human readable string.
 
Methods inherited from class opennlp.tools.util.Span
compareTo, contains, contains, crosses, getCoveredText, getEnd, getStart, getType, intersects, length, spansToStrings, spansToStrings, startsWith
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

HeadedSpan

public HeadedSpan(int s,
                  int e,
                  String type)

HeadedSpan

public HeadedSpan(int s,
                  int e)
Initializes a new Span Object.

Parameters:
s - start of span.
e - end of span.

HeadedSpan

public HeadedSpan(opennlp.tools.util.Span span,
                  int offset)
Initializes a new Span object with an existing Span which is shifted by an offset.

Parameters:
span -
offset -
Method Detail

setHead

public void setHead(int headPosition)

equals

public boolean equals(Object o)
Overrides:
equals in class opennlp.tools.util.Span

hashCode

public int hashCode()
Overrides:
hashCode in class opennlp.tools.util.Span

toString

public String toString()
Generates a human readable string.

Overrides:
toString in class opennlp.tools.util.Span

getHead

public int getHead()


Copyright © 2012-2013 CoGrOO. All Rights Reserved.