Show / Hide Table of Contents

Class BaseSimpleLuceneIndexer

Abstract Implementation of a simple Full Text Indexer using Lucene.Net which indexes the full text of literal objects and associated a specific Node with that full text.

Inheritance
object
BaseFullTextIndexer
BaseSimpleFullTextIndexer
BaseSimpleLuceneIndexer
LuceneObjectsIndexer
LucenePredicatesIndexer
LuceneSubjectsIndexer
Implements
IFullTextIndexer
IDisposable
IConfigurationSerializable
Inherited Members
BaseSimpleFullTextIndexer.Index(string, Triple)
BaseSimpleFullTextIndexer.Unindex(string, Triple)
BaseFullTextIndexer.Index(Triple)
BaseFullTextIndexer.Index(IGraph, Triple)
BaseFullTextIndexer.Index(IGraph)
BaseFullTextIndexer.Index(ISparqlDataset)
BaseFullTextIndexer.Unindex(Triple)
BaseFullTextIndexer.Unindex(IGraph, Triple)
BaseFullTextIndexer.Unindex(IGraph)
BaseFullTextIndexer.Unindex(ISparqlDataset)
BaseFullTextIndexer.Dispose()
object.Equals(object)
object.Equals(object, object)
object.GetHashCode()
object.GetType()
object.MemberwiseClone()
object.ReferenceEquals(object, object)
object.ToString()
Namespace: VDS.RDF.Query.FullText.Indexing.Lucene
Assembly: dotNetRdf.Query.FullText.dll
Syntax
public abstract class BaseSimpleLuceneIndexer : BaseSimpleFullTextIndexer, IFullTextIndexer, IDisposable, IConfigurationSerializable

Constructors

| Edit this page View Source

BaseSimpleLuceneIndexer(Directory, Analyzer, IFullTextIndexSchema, IndexingMode)

Creates a new Simple Lucene Indexer.

Declaration
protected BaseSimpleLuceneIndexer(Directory indexDir, Analyzer analyzer, IFullTextIndexSchema schema, IndexingMode mode)
Parameters
Type Name Description
Directory indexDir

Directory.

Analyzer analyzer

Analyzer.

IFullTextIndexSchema schema

Index Schema.

IndexingMode mode

Indexing Mode.

Properties

| Edit this page View Source

IndexingMode

Gets the Indexing Mode used.

Declaration
public override IndexingMode IndexingMode { get; }
Property Value
Type Description
IndexingMode
Overrides
BaseFullTextIndexer.IndexingMode

Methods

| Edit this page View Source

CreateDocument(string, INode, string)

Creates a Lucene document to add to the index.

Declaration
protected virtual Document CreateDocument(string graphUri, INode n, string text)
Parameters
Type Name Description
string graphUri

Graph URI.

INode n

Node.

string text

Full Text.

Returns
Type Description
Document
Remarks

May be overridden by derived classes that wish to implement custom indexing behaviour.

| Edit this page View Source

DisposeInternal()

Lucene dispose logic that ensures changes to the index are discarded.

Declaration
protected override void DisposeInternal()
Overrides
BaseFullTextIndexer.DisposeInternal()
| Edit this page View Source

Flush()

Flushes any changes to the index.

Declaration
public override void Flush()
Overrides
BaseFullTextIndexer.Flush()
| Edit this page View Source

GetHash(string, INode, string)

Gets the hash that should be included as part of a document so that it can be unindexed if desired.

Declaration
protected string GetHash(string graphUri, INode n, string text)
Parameters
Type Name Description
string graphUri

Graph URI.

INode n

Node.

string text

Full Text.

Returns
Type Description
string
| Edit this page View Source

Index(string, INode, string)

Indexes a Node and some full text as a Lucene document.

Declaration
protected override void Index(string graphUri, INode n, string text)
Parameters
Type Name Description
string graphUri

Graph URI.

INode n

Node.

string text

Full Text.

Overrides
BaseSimpleFullTextIndexer.Index(string, INode, string)
| Edit this page View Source

SerializeConfiguration(ConfigurationSerializationContext)

Serializes the Configuration of the Indexer.

Declaration
public virtual void SerializeConfiguration(ConfigurationSerializationContext context)
Parameters
Type Name Description
ConfigurationSerializationContext context

Serialization Context.

| Edit this page View Source

Unindex(string, INode, string)

Unindexes a Node and some full text.

Declaration
protected override void Unindex(string graphUri, INode n, string text)
Parameters
Type Name Description
string graphUri

Graph URI.

INode n

Node.

string text

Full Text.

Overrides
BaseSimpleFullTextIndexer.Unindex(string, INode, string)

Implements

IFullTextIndexer
IDisposable
IConfigurationSerializable

Extension Methods

Extensions.ToSafeString(object)
Extensions.AsEnumerable<T>(T)
  • Edit this page
  • View Source
In this article
  • Constructors
    • BaseSimpleLuceneIndexer(Directory, Analyzer, IFullTextIndexSchema, IndexingMode)
  • Properties
    • IndexingMode
  • Methods
    • CreateDocument(string, INode, string)
    • DisposeInternal()
    • Flush()
    • GetHash(string, INode, string)
    • Index(string, INode, string)
    • SerializeConfiguration(ConfigurationSerializationContext)
    • Unindex(string, INode, string)
  • Implements
  • Extension Methods
Back to top Generated by DocFX