opennlp.tools.parser.treeinsert
Class AttachContextGenerator

java.lang.Object
  extended by opennlp.tools.parser.AbstractContextGenerator
      extended by opennlp.tools.parser.treeinsert.AttachContextGenerator

public class AttachContextGenerator
extends AbstractContextGenerator


Constructor Summary
AttachContextGenerator(java.util.Set<java.lang.String> punctSet)
           
 
Method Summary
 java.lang.String[] getContext(java.lang.Object o)
           
 java.lang.String[] getContext(Parse[] constituents, int index, java.util.List<Parse> rightFrontier, int rfi)
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AttachContextGenerator

public AttachContextGenerator(java.util.Set<java.lang.String> punctSet)
Method Detail

getContext

public java.lang.String[] getContext(java.lang.Object o)

getContext

public java.lang.String[] getContext(Parse[] constituents,
                                     int index,
                                     java.util.List<Parse> rightFrontier,
                                     int rfi)
Parameters:
constituents - The constituents as they have been constructed so far.
index - The constituent index of the node being attached.
rightFrontier - The nodes which have been not attach to so far.
Returns:
A set of contextual features about this attachment.


Copyright © 2011 The Apache Software Foundation. All Rights Reserved.