|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.lucene.document.AbstractField
org.apache.jackrabbit.core.query.lucene.LazyTextExtractorField
public class LazyTextExtractorField
LazyTextExtractorField
implements a Lucene field with a String
value that is lazily initialized from a given Reader
. In addition
this class provides a method to find out whether the purpose of the reader
is to extract text and whether the extraction process is already finished.
isExtractorFinished()
,
Serialized FormField Summary |
---|
Fields inherited from class org.apache.lucene.document.AbstractField |
---|
binaryLength, binaryOffset, boost, fieldsData, isBinary, isCompressed, isIndexed, isStored, isTokenized, lazy, name, omitNorms, omitTf, storeOffsetWithTermVector, storePositionWithTermVector, storeTermVector |
Constructor Summary | |
---|---|
LazyTextExtractorField(String name,
Reader reader,
boolean store,
boolean withOffsets)
Creates a new LazyTextExtractorField with the given
name . |
Method Summary | |
---|---|
byte[] |
binaryValue()
|
void |
dispose()
Disposes this field and closes the underlying reader. |
boolean |
isExtractorFinished()
|
Reader |
readerValue()
|
String |
stringValue()
|
org.apache.lucene.analysis.TokenStream |
tokenStreamValue()
|
Methods inherited from class org.apache.lucene.document.AbstractField |
---|
getBinaryLength, getBinaryOffset, getBinaryValue, getBinaryValue, getBoost, getOmitNorms, getOmitTf, isBinary, isCompressed, isIndexed, isLazy, isStored, isStoreOffsetWithTermVector, isStorePositionWithTermVector, isTermVectorStored, isTokenized, name, setBoost, setOmitNorms, setOmitTf, setStoreTermVector, toString |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public LazyTextExtractorField(String name, Reader reader, boolean store, boolean withOffsets)
LazyTextExtractorField
with the given
name
.
name
- the name of the field.reader
- the reader where to obtain the string from.store
- when set true
the string value is stored in the
index.withOffsets
- when set true
a term vector with offsets
is written into the index.Method Detail |
---|
public String stringValue()
public Reader readerValue()
null
.public byte[] binaryValue()
null
.public org.apache.lucene.analysis.TokenStream tokenStreamValue()
null
.public boolean isExtractorFinished()
true
if the underlying reader is ready to provide
extracted text.public void dispose() throws IOException
IOException
- if an error occurs while closing the reader.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |