public class OLuceneFullTextIndexEngine extends OLuceneIndexEngineAbstract
OBaseIndexEngine.Validator<K,V>, OBaseIndexEngine.ValuesTransformer
collectionFields, indexDefinition, KEY, metadata, name, RID, version
VERSION
Constructor and Description |
---|
OLuceneFullTextIndexEngine(OStorage storage,
String idxName,
int id) |
Modifier and Type | Method and Description |
---|---|
org.apache.lucene.document.Document |
buildDocument(Object key,
OIdentifiable value) |
org.apache.lucene.search.Query |
buildQuery(Object maybeQuery) |
org.apache.lucene.index.IndexWriter |
createIndexWriter(org.apache.lucene.store.Directory directory) |
Object |
get(Object key) |
Set<OIdentifiable> |
getInTx(Object key,
OLuceneTxChanges changes) |
boolean |
hasRangeQuerySupport() |
void |
init(String indexName,
String indexType,
OIndexDefinition indexDefinition,
boolean isAutomatic,
ODocument metadata) |
Stream<ORawPair<Object,ORID>> |
iterateEntriesBetween(Object rangeFrom,
boolean fromInclusive,
Object rangeTo,
boolean toInclusive,
boolean ascSortOrder,
OBaseIndexEngine.ValuesTransformer transformer) |
Stream<ORawPair<Object,ORID>> |
iterateEntriesMajor(Object fromKey,
boolean isInclusive,
boolean ascSortOrder,
OBaseIndexEngine.ValuesTransformer transformer) |
Stream<ORawPair<Object,ORID>> |
iterateEntriesMinor(Object toKey,
boolean isInclusive,
boolean ascSortOrder,
OBaseIndexEngine.ValuesTransformer transformer) |
void |
onRecordAddedToResultSet(OLuceneQueryContext queryContext,
OContextualRecordId recordId,
org.apache.lucene.document.Document ret,
org.apache.lucene.search.ScoreDoc score) |
void |
put(OAtomicOperation atomicOperation,
Object key,
Object value) |
boolean |
remove(OAtomicOperation atomicOperation,
Object key) |
void |
update(OAtomicOperation atomicOperation,
Object key,
OIndexKeyUpdater<Object> updater) |
boolean |
validatedPut(OAtomicOperation atomicOperation,
Object key,
ORID value,
OBaseIndexEngine.Validator<Object,ORID> validator)
Puts the given value under the given key into this index engine.
|
acquireAtomicExclusiveLock, addDocument, buildTxChanges, clear, close, create, delete, deleteQuery, descStream, flush, freeze, getDatabase, getId, getIndexNameByKey, getName, indexAnalyzer, indexName, isCollectionIndex, keyStream, load, openIfClosed, queryAnalyzer, release, release, remove, searcher, size, sizeInTx, stream, updateLastAccess
acquireExclusiveLock, acquireSharedLock, releaseExclusiveLock, releaseSharedLock, tryAcquireExclusiveLock, tryAcquireSharedLock
addUser, assertExclusiveLockHold, assertSharedLockHold, getUsers, isConcurrent, removeUser
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getEngineAPIVersion
public void init(String indexName, String indexType, OIndexDefinition indexDefinition, boolean isAutomatic, ODocument metadata)
init
in interface OBaseIndexEngine
init
in class OLuceneIndexEngineAbstract
public org.apache.lucene.index.IndexWriter createIndexWriter(org.apache.lucene.store.Directory directory) throws IOException
createIndexWriter
in class OLuceneIndexEngineAbstract
IOException
public void onRecordAddedToResultSet(OLuceneQueryContext queryContext, OContextualRecordId recordId, org.apache.lucene.document.Document ret, org.apache.lucene.search.ScoreDoc score)
onRecordAddedToResultSet
in interface OLuceneIndexEngine
onRecordAddedToResultSet
in class OLuceneIndexEngineAbstract
public boolean remove(OAtomicOperation atomicOperation, Object key)
public void update(OAtomicOperation atomicOperation, Object key, OIndexKeyUpdater<Object> updater)
public void put(OAtomicOperation atomicOperation, Object key, Object value)
public boolean validatedPut(OAtomicOperation atomicOperation, Object key, ORID value, OBaseIndexEngine.Validator<Object,ORID> validator)
OIndexEngine
key
- the key to put the value under.value
- the value to put.validator
- the operation validator.true
if the validator allowed the put, false
otherwise.Validator#validate(Object, Object, Object)
public Stream<ORawPair<Object,ORID>> iterateEntriesBetween(Object rangeFrom, boolean fromInclusive, Object rangeTo, boolean toInclusive, boolean ascSortOrder, OBaseIndexEngine.ValuesTransformer transformer)
public Stream<ORawPair<Object,ORID>> iterateEntriesMajor(Object fromKey, boolean isInclusive, boolean ascSortOrder, OBaseIndexEngine.ValuesTransformer transformer)
public Stream<ORawPair<Object,ORID>> iterateEntriesMinor(Object toKey, boolean isInclusive, boolean ascSortOrder, OBaseIndexEngine.ValuesTransformer transformer)
public boolean hasRangeQuerySupport()
public org.apache.lucene.document.Document buildDocument(Object key, OIdentifiable value)
public org.apache.lucene.search.Query buildQuery(Object maybeQuery)
public Set<OIdentifiable> getInTx(Object key, OLuceneTxChanges changes)
Copyright © 2009–2020 OrientDB. All rights reserved.