org.apache.lucene.analysis.sinks
public class DateRecognizerSinkFilter extends org.apache.lucene.analysis.TeeSinkTokenFilter.SinkFilter
Token.termBuffer()
as a Date using a DateFormat
.
If the value is a Date, it will add it to the sink.
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
DATE_TYPE |
protected java.text.DateFormat |
dateFormat |
protected org.apache.lucene.analysis.tokenattributes.TermAttribute |
termAtt |
Constructor and Description |
---|
DateRecognizerSinkFilter()
Uses
DateFormat.getDateInstance() as the DateFormat object. |
DateRecognizerSinkFilter(java.text.DateFormat dateFormat) |
Modifier and Type | Method and Description |
---|---|
boolean |
accept(org.apache.lucene.util.AttributeSource source) |
public static final java.lang.String DATE_TYPE
protected java.text.DateFormat dateFormat
protected org.apache.lucene.analysis.tokenattributes.TermAttribute termAtt
Copyright © 2000-2014 Apache Software Foundation. All Rights Reserved.