C# Class Raven.Database.Indexing.Index

This is a thread safe, single instance for a particular index.
Inheritance: IDisposable
Exibir arquivo Open project: nhsevidence/ravendb Class Usage Examples

Protected Properties

Property Type Description
indexDefinition Raven.Database.Indexing.IndexDefinition
logIndexing Logger
logQuerying Logger
name string

Private Properties

Property Type Description
CloneDocument Lucene.Net.Documents.Document
CreateDocumentFromFields RavenJObject
CreateIndexWriter Lucene.Net.Index.IndexWriter
CreateProperty RavenJToken>.KeyValuePair
GetSearcher IDisposable
RecreateSearcher void
WriteTempIndexToDiskIfNeeded void

Public Methods

Method Description
CreateAnalyzer ( Analyzer defaultAnalyzer, ICollection toDispose ) : Lucene.Net.Analysis.PerFieldAnalyzerWrapper
Dispose ( ) : void
Flush ( ) : void
GetExtension ( string indexExtensionKey ) : IIndexExtension
IndexDocuments ( AbstractViewGenerator viewGenerator, IEnumerable documents, WorkContext context, IStorageActionsAccessor actions, System.DateTime minimumTimestamp ) : void
Remove ( string keys, WorkContext context ) : void
SetExtension ( string indexExtensionKey, IIndexExtension extension ) : void
TryGetDocKey ( object current ) : string

Protected Methods

Method Description
AddDocumentToIndex ( IndexWriter currentIndexWriter, Lucene.Net.Documents.Document luceneDoc, Analyzer analyzer ) : void
Index ( Lucene.Net.Store.Directory directory, string name, Raven.Database.Indexing.IndexDefinition indexDefinition, AbstractViewGenerator viewGenerator ) : System
RetrieveDocument ( Lucene.Net.Documents.Document document, FieldsToFetch fieldsToFetch, float score ) : Raven.Database.Data.IndexQueryResult
RobustEnumerationIndex ( IEnumerable input, IEnumerable funcs, IStorageActionsAccessor actions, WorkContext context ) : IEnumerable
RobustEnumerationReduce ( IEnumerable input, IndexingFunc func, IStorageActionsAccessor actions, WorkContext context ) : IEnumerable
RobustEnumerationReduceDuringMapPhase ( IEnumerable input, IndexingFunc func, IStorageActionsAccessor actions, WorkContext context ) : IEnumerable
Write ( WorkContext context, Func action ) : void

Private Methods

Method Description
CloneDocument ( Lucene.Net.Documents.Document luceneDoc ) : Lucene.Net.Documents.Document
CreateDocumentFromFields ( Lucene.Net.Documents.Document document, IEnumerable fieldsToFetch ) : RavenJObject
CreateIndexWriter ( Lucene.Net.Store.Directory directory ) : IndexWriter
CreateProperty ( Field fld, Lucene.Net.Documents.Document document ) : RavenJToken>.KeyValuePair
GetSearcher ( IndexSearcher &searcher ) : IDisposable
RecreateSearcher ( ) : void
WriteTempIndexToDiskIfNeeded ( WorkContext context ) : void

Method Details

AddDocumentToIndex() protected method

protected AddDocumentToIndex ( IndexWriter currentIndexWriter, Lucene.Net.Documents.Document luceneDoc, Analyzer analyzer ) : void
currentIndexWriter Lucene.Net.Index.IndexWriter
luceneDoc Lucene.Net.Documents.Document
analyzer Lucene.Net.Analysis.Analyzer
return void

CreateAnalyzer() public method

public CreateAnalyzer ( Analyzer defaultAnalyzer, ICollection toDispose ) : Lucene.Net.Analysis.PerFieldAnalyzerWrapper
defaultAnalyzer Lucene.Net.Analysis.Analyzer
toDispose ICollection
return Lucene.Net.Analysis.PerFieldAnalyzerWrapper

Dispose() public method

public Dispose ( ) : void
return void

Flush() public method

public Flush ( ) : void
return void

GetExtension() public method

public GetExtension ( string indexExtensionKey ) : IIndexExtension
indexExtensionKey string
return IIndexExtension

Index() protected method

protected Index ( Lucene.Net.Store.Directory directory, string name, Raven.Database.Indexing.IndexDefinition indexDefinition, AbstractViewGenerator viewGenerator ) : System
directory Lucene.Net.Store.Directory
name string
indexDefinition Raven.Database.Indexing.IndexDefinition
viewGenerator Raven.Database.Linq.AbstractViewGenerator
return System

IndexDocuments() public abstract method

public abstract IndexDocuments ( AbstractViewGenerator viewGenerator, IEnumerable documents, WorkContext context, IStorageActionsAccessor actions, System.DateTime minimumTimestamp ) : void
viewGenerator Raven.Database.Linq.AbstractViewGenerator
documents IEnumerable
context WorkContext
actions IStorageActionsAccessor
minimumTimestamp System.DateTime
return void

Remove() public abstract method

public abstract Remove ( string keys, WorkContext context ) : void
keys string
context WorkContext
return void

RetrieveDocument() protected method

protected RetrieveDocument ( Lucene.Net.Documents.Document document, FieldsToFetch fieldsToFetch, float score ) : Raven.Database.Data.IndexQueryResult
document Lucene.Net.Documents.Document
fieldsToFetch FieldsToFetch
score float
return Raven.Database.Data.IndexQueryResult

RobustEnumerationIndex() protected method

protected RobustEnumerationIndex ( IEnumerable input, IEnumerable funcs, IStorageActionsAccessor actions, WorkContext context ) : IEnumerable
input IEnumerable
funcs IEnumerable
actions IStorageActionsAccessor
context WorkContext
return IEnumerable

RobustEnumerationReduce() protected method

protected RobustEnumerationReduce ( IEnumerable input, IndexingFunc func, IStorageActionsAccessor actions, WorkContext context ) : IEnumerable
input IEnumerable
func IndexingFunc
actions IStorageActionsAccessor
context WorkContext
return IEnumerable

RobustEnumerationReduceDuringMapPhase() protected method

protected RobustEnumerationReduceDuringMapPhase ( IEnumerable input, IndexingFunc func, IStorageActionsAccessor actions, WorkContext context ) : IEnumerable
input IEnumerable
func IndexingFunc
actions IStorageActionsAccessor
context WorkContext
return IEnumerable

SetExtension() public method

public SetExtension ( string indexExtensionKey, IIndexExtension extension ) : void
indexExtensionKey string
extension IIndexExtension
return void

TryGetDocKey() public static method

public static TryGetDocKey ( object current ) : string
current object
return string

Write() protected method

protected Write ( WorkContext context, Func action ) : void
context WorkContext
action Func
return void

Property Details

indexDefinition protected_oe property

protected IndexDefinition,Raven.Database.Indexing indexDefinition
return Raven.Database.Indexing.IndexDefinition

logIndexing protected_oe static_oe property

protected static Logger logIndexing
return Logger

logQuerying protected_oe static_oe property

protected static Logger logQuerying
return Logger

name protected_oe property

protected string name
return string