public interface Document extends Observable<Document>, Comparable<Document>
Document
is tracked by the Lucene searchindex. It implements
Observable
so it can notify an Observer
of changes.Document
is being created from a Document
instance, which is then
being added/updated/deleted from/to the index, depending on the DocumentEvent
passed to
DocumentProducer
#put({@link DocumentEvent})
.
TODO appng-search is the better place for this
DocumentProducer
,
DocumentEvent
Observable.Event
Modifier and Type | Field and Description |
---|---|
static Observable.Event |
CREATE
Event indicating a
Document has been created. |
static Observable.Event |
DELETE
Event indicating a
Document has been deleted. |
static String |
FIELD_CONTENT |
static String |
FIELD_DATE |
static String |
FIELD_ID |
static String |
FIELD_IMAGE |
static String |
FIELD_LANGUAGE |
static String |
FIELD_PATH |
static String |
FIELD_TEASER |
static String |
FIELD_TITLE |
static String |
FIELD_TYPE |
static Observable.Event |
UPDATE
Event indicating a
Document has been updated. |
static String |
YYYY_MM_DD_HH_MM_SS |
Modifier and Type | Method and Description |
---|---|
Iterable<org.apache.lucene.index.IndexableField> |
getAdditionalFields()
Returns some additionally
IndexableField s (if any) to be added to the
Document which is being created from this Document . |
String |
getContent()
Returns the content to be indexed.
|
Date |
getDate()
|
String |
getDescription()
Returns the description of this
Document . |
int |
getDocId() |
org.apache.lucene.index.IndexableField |
getField(String string) |
String |
getFragment() |
String |
getId()
|
String |
getImage() |
String |
getLanguage()
Returns the language of this
Document . |
String |
getName()
Returns the name of this
Document . |
String |
getPath()
|
float |
getScore() |
String |
getType()
|
void |
setFragment(String fragment) |
addObserver, notifyObservers, removeObserver
compareTo
static final String FIELD_PATH
static final String FIELD_TITLE
static final String FIELD_TEASER
static final String FIELD_IMAGE
static final String FIELD_DATE
static final String FIELD_TYPE
static final String FIELD_LANGUAGE
static final String FIELD_CONTENT
static final String FIELD_ID
static final String YYYY_MM_DD_HH_MM_SS
static final Observable.Event CREATE
Document
has been created.static final Observable.Event UPDATE
Document
has been updated.static final Observable.Event DELETE
Document
has been deleted.String getId()
Document
.Site
, since each site has it's own
searchindex.String getDescription()
Document
.Document
String getImage()
String getContent()
String getType()
Iterable<org.apache.lucene.index.IndexableField> getAdditionalFields()
IndexableField
s (if any) to be added to the
Document
which is being created from this Document
.IndexableField
sorg.apache.lucene.index.IndexableField getField(String string)
float getScore()
int getDocId()
String getFragment()
void setFragment(String fragment)
Copyright © 2011–2023 aiticon GmbH. All rights reserved.