com.xerox.jxip
Class XipLeaf

java.lang.Object
  extended by com.xerox.jxip.XipNode
      extended by com.xerox.jxip.XipLeaf
All Implemented Interfaces:
java.lang.Comparable

public class XipLeaf
extends XipNode

XipLeaf Class


Field Summary
 
Fields inherited from class com.xerox.jxip.XipNode
daughters, dependencies, features, LEAF, mother, NODE
 
Constructor Summary
XipLeaf(java.lang.String category, java.lang.String surface, java.lang.String lemma, java.lang.String initialfeatures, long left, long right, long index, long gramNodeId, java.lang.String fileName, long sentenceNb, long leftChar, long rightChar)
          Constructor for the XipLeaf object
 
Method Summary
 java.lang.String getInitialFeatures()
          Gets the initial features
 long getLeftTokOffset()
          Gets the left token-based offset
 java.lang.String getLemma()
          Gets the lemma
 long getRightTokOffset()
          Gets the right token-based offset
 java.lang.String getSurface()
          Gets the surface
 int getType()
          return always XipNode.LEAF
 boolean isLeaf()
          return always true
 void setLeftTokOffset(long n)
          Sets the left token-based offset
 void setRightTokOffset(long n)
          Sets the right token-based offset
 java.lang.String toString()
          return the surface
 java.lang.String toString(boolean withFeature, java.lang.String tab, boolean deeply)
          return XipLeaf data as a string
 
Methods inherited from class com.xerox.jxip.XipNode
addDaughter, addDependency, chunkTreeToString, chunkTreeToString, compareTo, dependenciesToString, featuresToString, flMatches, fMatches, fMatches, getCategory, getChunkHead, getDaughters, getDependencies, getDependenciesByName, getDependenciesByName, getDependenciesByName, getDependenciesByName, getDependentAhead, getDependentAhead, getDependentAhead, getDependentIn, getDependentIn, getDescendantsByBooleanMethod, getDescendantsByBooleanMethod, getDescendantsByCategory, getDescendantsByCategory, getDescendantsByDependency, getDescendantsByDependency, getDescendantsByDependency, getDescendantsByFeature, getDescendantsByFeature, getFeature, getFeatures, getFirstDescendantsByCategory, getFirstDescendantsByFeature, getFirstDescendantsByFeature, getGramIdNode, getHeadIn, getHeadIn, getId, getId, getIndex, getLeafNodes, getLeft, getLeftChar, getMiscInfo, getMother, getNodeByGramId, getNodeByUid, getRight, getRightChar, getUid, hasDependency, hasDependency, hasDependency, hasDependency, hasFeature, hasFeature, hasFeatures, invokeMethodOnNode, isChunkHead, isDependentIn, isFicticious, isHeadIn, isPreTerminalNode, isRelDependentOf, isRelDependentOf, isRelHeadOf, isRelHeadOf, setFeatures, setMiscInfo, setMother, toHtmlString, toString2
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

XipLeaf

public XipLeaf(java.lang.String category,
               java.lang.String surface,
               java.lang.String lemma,
               java.lang.String initialfeatures,
               long left,
               long right,
               long index,
               long gramNodeId,
               java.lang.String fileName,
               long sentenceNb,
               long leftChar,
               long rightChar)
Constructor for the XipLeaf object

Parameters:
category - the node name
surface - surface
lemma - lemma
initialfeatures -
left - offset of the beginning of the word in the sentence
right - offset of the end of the word in the sentence
index - index used as link with c++ data
gramNodeId -
fileName -
sentenceNb -
leftChar -
rightChar -
Method Detail

getLemma

public java.lang.String getLemma()
Gets the lemma

Overrides:
getLemma in class XipNode
Returns:
The lemma

getSurface

public java.lang.String getSurface()
Gets the surface

Overrides:
getSurface in class XipNode
Returns:
The surface

getInitialFeatures

public java.lang.String getInitialFeatures()
Gets the initial features

Returns:
The initial features

getLeftTokOffset

public long getLeftTokOffset()
Gets the left token-based offset

Overrides:
getLeftTokOffset in class XipNode
Returns:
The left token based offset

getRightTokOffset

public long getRightTokOffset()
Gets the right token-based offset

Overrides:
getRightTokOffset in class XipNode
Returns:
The right token based offset

setLeftTokOffset

public void setLeftTokOffset(long n)
Sets the left token-based offset

Parameters:
n - the left token based offset

setRightTokOffset

public void setRightTokOffset(long n)
Sets the right token-based offset

Parameters:
n - the right token based offset

isLeaf

public boolean isLeaf()
return always true

Overrides:
isLeaf in class XipNode
Returns:
return always true

getType

public int getType()
return always XipNode.LEAF

Overrides:
getType in class XipNode
Returns:
return always XipNode.LEAF

toString

public java.lang.String toString()
return the surface

Overrides:
toString in class XipNode
Returns:
return the surface

toString

public java.lang.String toString(boolean withFeature,
                                 java.lang.String tab,
                                 boolean deeply)
return XipLeaf data as a string

Overrides:
toString in class XipNode
Parameters:
withFeature - if true build the string with the XipNode features
tab - tabulation
deeply - unused
Returns:
XipLeaf to a string


Copyright © 2008 Xerox All Rights Reserved.