edu.stanford.nlp.time
Class TimeExpression

java.lang.Object
  extended by edu.stanford.nlp.ling.tokensregex.MatchedExpression
      extended by edu.stanford.nlp.time.TimeExpression

public class TimeExpression
extends MatchedExpression

Time Expression

Author:
Angel Chang

Nested Class Summary
static class TimeExpression.Annotation
          The CoreMap key for storing a TimeExpression annotation
static class TimeExpression.ChildrenAnnotation
          The CoreMap key for storing a nested annotations
 
Nested classes/interfaces inherited from class edu.stanford.nlp.ling.tokensregex.MatchedExpression
MatchedExpression.SingleAnnotationExtractor
 
Field Summary
protected static Function<MatchedExpression,TimeExpression> TimeExpressionConverter
           
 
Fields inherited from class edu.stanford.nlp.ling.tokensregex.MatchedExpression
annotation, charOffsets, chunkOffsets, COREMAP_TO_CHAR_OFFSETS_INTERVAL_FUNC, COREMAP_TO_TOKEN_OFFSETS_INTERVAL_FUNC, EXPR_LENGTH_COMPARATOR, EXPR_LENGTH_PRIORITY_COMPARATOR, EXPR_ORDER_COMPARATOR, EXPR_PRIORITY_COMPARATOR, EXPR_PRIORITY_LENGTH_COMPARATOR, EXPR_TO_TOKEN_OFFSETS_INTERVAL_FUNC, EXPR_TOKEN_OFFSET_COMPARATOR, EXPR_TOKEN_OFFSETS_NESTED_FIRST_COMPARATOR, extractFunc, text, tokenOffsets, value
 
Constructor Summary
TimeExpression(Interval<java.lang.Integer> charOffsets, Interval<java.lang.Integer> tokenOffsets, Function<CoreMap,SUTime.Temporal> temporalFunc, double priority, double weight)
           
TimeExpression(MatchedExpression expr)
           
 
Method Summary
 boolean addMod()
           
 boolean extractAnnotation(Env env, CoreMap sourceAnnotation)
           
 boolean extractAnnotation(Env env, java.util.List<? extends CoreMap> source)
           
 SUTime.Temporal getTemporal()
           
 void setTemporal(SUTime.Temporal temporal)
           
 
Methods inherited from class edu.stanford.nlp.ling.tokensregex.MatchedExpression
extractAnnotation, getAnnotation, getCharOffsets, getChunkOffsets, getOrder, getPriority, getText, getTokenOffsets, getValue, isIncludeNested, removeNested, removeNullValues, removeOverlapping, replaceMerged, replaceMergedUsingTokenOffsets, setIncludeNested, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

TimeExpressionConverter

protected static final Function<MatchedExpression,TimeExpression> TimeExpressionConverter
Constructor Detail

TimeExpression

public TimeExpression(MatchedExpression expr)

TimeExpression

public TimeExpression(Interval<java.lang.Integer> charOffsets,
                      Interval<java.lang.Integer> tokenOffsets,
                      Function<CoreMap,SUTime.Temporal> temporalFunc,
                      double priority,
                      double weight)
Method Detail

addMod

public boolean addMod()

extractAnnotation

public boolean extractAnnotation(Env env,
                                 CoreMap sourceAnnotation)
Overrides:
extractAnnotation in class MatchedExpression

extractAnnotation

public boolean extractAnnotation(Env env,
                                 java.util.List<? extends CoreMap> source)
Overrides:
extractAnnotation in class MatchedExpression

getTemporal

public SUTime.Temporal getTemporal()

setTemporal

public void setTemporal(SUTime.Temporal temporal)


Stanford NLP Group