You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucenenet.apache.org by sy...@apache.org on 2014/09/10 04:04:38 UTC
git commit: Cleanup
Repository: lucenenet
Updated Branches:
refs/heads/master 4986b22eb -> f69360e20
Cleanup
Project: http://git-wip-us.apache.org/repos/asf/lucenenet/repo
Commit: http://git-wip-us.apache.org/repos/asf/lucenenet/commit/f69360e2
Tree: http://git-wip-us.apache.org/repos/asf/lucenenet/tree/f69360e2
Diff: http://git-wip-us.apache.org/repos/asf/lucenenet/diff/f69360e2
Branch: refs/heads/master
Commit: f69360e205b52603899d34fda8c028a6de7fd8d4
Parents: 4986b22
Author: Itamar Syn-Hershko <it...@code972.com>
Authored: Wed Sep 10 05:03:43 2014 +0300
Committer: Itamar Syn-Hershko <it...@code972.com>
Committed: Wed Sep 10 05:03:43 2014 +0300
----------------------------------------------------------------------
.../Document/DocumentStoredFieldVisitor.cs | 2 +-
src/Lucene.Net.Core/Document/DoubleField.cs | 4 +-
src/Lucene.Net.Core/Document/FieldType.cs | 47 +++++++++-----------
src/Lucene.Net.Core/Document/FloatField.cs | 4 +-
src/Lucene.Net.Core/Document/IntField.cs | 4 +-
src/Lucene.Net.Core/Document/LongField.cs | 4 +-
src/Lucene.Net.Core/Document/StringField.cs | 4 +-
.../Index/DocInverterPerField.cs | 2 +-
src/Lucene.Net.Core/Index/FieldInfo.cs | 2 +-
src/Lucene.Net.Core/Index/FieldInfos.cs | 2 +-
src/Lucene.Net.Core/Index/IndexableFieldType.cs | 4 +-
.../Analysis/BaseTokenStreamTestCase.cs | 10 ++---
.../Index/BasePostingsFormatTestCase.cs | 2 +-
src/Lucene.Net.TestFramework/Index/DocHelper.cs | 6 +--
.../core/Analysis/TestMockAnalyzer.cs | 2 +-
.../Lucene40/TestLucene40PostingsReader.cs | 4 +-
.../Codecs/Lucene41/TestBlockPostingsFormat2.cs | 2 +-
.../Codecs/Lucene41/TestBlockPostingsFormat3.cs | 6 +--
.../core/Index/Test2BPostings.cs | 2 +-
.../core/Index/Test2BPostingsBytes.cs | 2 +-
src/Lucene.Net.Tests/core/Index/Test2BTerms.cs | 2 +-
.../core/Index/TestBagOfPositions.cs | 4 +-
src/Lucene.Net.Tests/core/Index/TestCodecs.cs | 2 +-
.../core/Index/TestDocumentWriter.cs | 2 +-
.../core/Index/TestFieldsReader.cs | 6 +--
.../core/Index/TestIndexWriter.cs | 4 +-
.../core/Index/TestIndexableField.cs | 2 +-
.../core/Index/TestLongPostings.cs | 2 +-
.../core/Index/TestOmitPositions.cs | 12 ++---
src/Lucene.Net.Tests/core/Index/TestOmitTf.cs | 4 +-
.../core/Index/TestPostingsOffsets.cs | 14 +++---
.../core/Search/Similarities/TestSimilarity2.cs | 4 +-
32 files changed, 85 insertions(+), 88 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/lucenenet/blob/f69360e2/src/Lucene.Net.Core/Document/DocumentStoredFieldVisitor.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Core/Document/DocumentStoredFieldVisitor.cs b/src/Lucene.Net.Core/Document/DocumentStoredFieldVisitor.cs
index e316d20..28aa5a7 100644
--- a/src/Lucene.Net.Core/Document/DocumentStoredFieldVisitor.cs
+++ b/src/Lucene.Net.Core/Document/DocumentStoredFieldVisitor.cs
@@ -73,7 +73,7 @@ namespace Lucene.Net.Documents
ft.StoreTermVectors = fieldInfo.HasVectors();
ft.Indexed = fieldInfo.Indexed;
ft.OmitNorms = fieldInfo.OmitsNorms();
- ft.IndexOptionsValue = fieldInfo.FieldIndexOptions;
+ ft.IndexOptions = fieldInfo.FieldIndexOptions;
Doc.Add(new Field(fieldInfo.Name, value, ft));
}
http://git-wip-us.apache.org/repos/asf/lucenenet/blob/f69360e2/src/Lucene.Net.Core/Document/DoubleField.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Core/Document/DoubleField.cs b/src/Lucene.Net.Core/Document/DoubleField.cs
index 45c07ae..2fc1826 100644
--- a/src/Lucene.Net.Core/Document/DoubleField.cs
+++ b/src/Lucene.Net.Core/Document/DoubleField.cs
@@ -133,14 +133,14 @@ namespace Lucene.Net.Documents
TYPE_NOT_STORED.Indexed = true;
TYPE_NOT_STORED.Tokenized = true;
TYPE_NOT_STORED.OmitNorms = true;
- TYPE_NOT_STORED.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_ONLY;
+ TYPE_NOT_STORED.IndexOptions = FieldInfo.IndexOptions.DOCS_ONLY;
TYPE_NOT_STORED.NumericTypeValue = Documents.FieldType.NumericType.DOUBLE;
TYPE_NOT_STORED.Freeze();
TYPE_STORED.Indexed = true;
TYPE_STORED.Tokenized = true;
TYPE_STORED.OmitNorms = true;
- TYPE_STORED.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_ONLY;
+ TYPE_STORED.IndexOptions = FieldInfo.IndexOptions.DOCS_ONLY;
TYPE_STORED.NumericTypeValue = Documents.FieldType.NumericType.DOUBLE;
TYPE_STORED.Stored = true;
TYPE_STORED.Freeze();
http://git-wip-us.apache.org/repos/asf/lucenenet/blob/f69360e2/src/Lucene.Net.Core/Document/FieldType.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Core/Document/FieldType.cs b/src/Lucene.Net.Core/Document/FieldType.cs
index 2eaa5f4..75ba177 100644
--- a/src/Lucene.Net.Core/Document/FieldType.cs
+++ b/src/Lucene.Net.Core/Document/FieldType.cs
@@ -1,5 +1,6 @@
using System;
using System.Text;
+using Lucene.Net.Analysis;
using Lucene.Net.Index;
using Lucene.Net.Util;
@@ -22,10 +23,6 @@ namespace Lucene.Net.Documents
* limitations under the License.
*/
- // javadocs
-
- // javadocs
-
/// <summary>
/// Describes the properties of a field.
/// </summary>
@@ -62,7 +59,7 @@ namespace Lucene.Net.Documents
private bool StoreTermVectorPositions_Renamed;
private bool StoreTermVectorPayloads_Renamed;
private bool OmitNorms_Renamed;
- private FieldInfo.IndexOptions? IndexOptions_Renamed = FieldInfo.IndexOptions.DOCS_AND_FREQS_AND_POSITIONS;
+ private FieldInfo.IndexOptions? _indexOptions = FieldInfo.IndexOptions.DOCS_AND_FREQS_AND_POSITIONS;
private NumericType? numericType;
private bool Frozen;
private int NumericPrecisionStep_Renamed = NumericUtils.PRECISION_STEP_DEFAULT;
@@ -81,7 +78,7 @@ namespace Lucene.Net.Documents
this.StoreTermVectorPositions_Renamed = @ref.StoreTermVectorPositions;
this.StoreTermVectorPayloads_Renamed = @ref.StoreTermVectorPayloads;
this.OmitNorms_Renamed = @ref.OmitNorms;
- this.IndexOptions_Renamed = @ref.IndexOptionsValue;
+ this._indexOptions = @ref.IndexOptions;
this.docValueType = @ref.DocValueType;
this.numericType = @ref.NumericTypeValue;
// Do not copy frozen!
@@ -115,7 +112,7 @@ namespace Lucene.Net.Documents
/// <summary>
/// Set to <code>true</code> to index (invert) this field. </summary>
/// <param name="value"> true if this field should be indexed. </param>
- /// <exception cref="IllegalStateException"> if this FieldType is frozen against
+ /// <exception cref="InvalidOperationException"> if this FieldType is frozen against
/// future modifications. </exception>
/// <seealso cref= #indexed() </seealso>
public bool Indexed
@@ -131,7 +128,7 @@ namespace Lucene.Net.Documents
/// <summary>
/// Set to <code>true</code> to store this field. </summary>
/// <param name="value"> true if this field should be stored. </param>
- /// <exception cref="IllegalStateException"> if this FieldType is frozen against
+ /// <exception cref="InvalidOperationException"> if this FieldType is frozen against
/// future modifications. </exception>
/// <seealso cref= #stored() </seealso>
public bool Stored
@@ -151,7 +148,7 @@ namespace Lucene.Net.Documents
/// Set to <code>true</code> to tokenize this field's contents via the
/// configured <seealso cref="Analyzer"/>. </summary>
/// <param name="value"> true if this field should be tokenized. </param>
- /// <exception cref="IllegalStateException"> if this FieldType is frozen against
+ /// <exception cref="InvalidOperationException"> if this FieldType is frozen against
/// future modifications. </exception>
/// <seealso cref= #tokenized() </seealso>
public virtual bool Tokenized
@@ -171,7 +168,7 @@ namespace Lucene.Net.Documents
/// Set to <code>true</code> if this field's indexed form should be also stored
/// into term vectors. </summary>
/// <param name="value"> true if this field should store term vectors. </param>
- /// <exception cref="IllegalStateException"> if this FieldType is frozen against
+ /// <exception cref="InvalidOperationException"> if this FieldType is frozen against
/// future modifications. </exception>
/// <seealso cref= #storeTermVectors() </seealso>
public bool StoreTermVectors
@@ -189,7 +186,7 @@ namespace Lucene.Net.Documents
/// Set to <code>true</code> to also store token character offsets into the term
/// vector for this field. </summary>
/// <param name="value"> true if this field should store term vector offsets. </param>
- /// <exception cref="IllegalStateException"> if this FieldType is frozen against
+ /// <exception cref="InvalidOperationException"> if this FieldType is frozen against
/// future modifications. </exception>
/// <seealso cref= #storeTermVectorOffsets() </seealso>
public virtual bool StoreTermVectorOffsets
@@ -209,7 +206,7 @@ namespace Lucene.Net.Documents
/// Set to <code>true</code> to also store token positions into the term
/// vector for this field. </summary>
/// <param name="value"> true if this field should store term vector positions. </param>
- /// <exception cref="IllegalStateException"> if this FieldType is frozen against
+ /// <exception cref="InvalidOperationException"> if this FieldType is frozen against
/// future modifications. </exception>
/// <seealso cref= #storeTermVectorPositions() </seealso>
public virtual bool StoreTermVectorPositions
@@ -229,7 +226,7 @@ namespace Lucene.Net.Documents
/// Set to <code>true</code> to also store token payloads into the term
/// vector for this field. </summary>
/// <param name="value"> true if this field should store term vector payloads. </param>
- /// <exception cref="IllegalStateException"> if this FieldType is frozen against
+ /// <exception cref="InvalidOperationException"> if this FieldType is frozen against
/// future modifications. </exception>
/// <seealso cref= #storeTermVectorPayloads() </seealso>
public virtual bool StoreTermVectorPayloads
@@ -248,7 +245,7 @@ namespace Lucene.Net.Documents
/// <summary>
/// Set to <code>true</code> to omit normalization values for the field. </summary>
/// <param name="value"> true if this field should omit norms. </param>
- /// <exception cref="IllegalStateException"> if this FieldType is frozen against
+ /// <exception cref="InvalidOperationException"> if this FieldType is frozen against
/// future modifications. </exception>
/// <seealso cref= #omitNorms() </seealso>
public bool OmitNorms
@@ -264,26 +261,26 @@ namespace Lucene.Net.Documents
/// <summary>
/// Sets the indexing options for the field: </summary>
/// <param name="value"> indexing options </param>
- /// <exception cref="IllegalStateException"> if this FieldType is frozen against
+ /// <exception cref="InvalidOperationException"> if this FieldType is frozen against
/// future modifications. </exception>
/// <seealso cref= #indexOptions() </seealso>
- public virtual FieldInfo.IndexOptions? IndexOptionsValue
+ public virtual FieldInfo.IndexOptions? IndexOptions
{
get
{
- return this.IndexOptions_Renamed;
+ return this._indexOptions;
}
set
{
CheckIfFrozen();
- this.IndexOptions_Renamed = value;
+ this._indexOptions = value;
}
}
/// <summary>
/// Specifies the field's numeric type. </summary>
/// <param name="type"> numeric type, or null if the field has no numeric type. </param>
- /// <exception cref="IllegalStateException"> if this FieldType is frozen against
+ /// <exception cref="InvalidOperationException"> if this FieldType is frozen against
/// future modifications. </exception>
/// <seealso cref= #numericType() </seealso>
public virtual NumericType? NumericTypeValue
@@ -302,8 +299,8 @@ namespace Lucene.Net.Documents
/// <summary>
/// Sets the numeric precision step for the field. </summary>
/// <param name="precisionStep"> numeric precision step for the field </param>
- /// <exception cref="IllegalArgumentException"> if precisionStep is less than 1. </exception>
- /// <exception cref="IllegalStateException"> if this FieldType is frozen against
+ /// <exception cref="ArgumentException"> if precisionStep is less than 1. </exception>
+ /// <exception cref="InvalidOperationException"> if this FieldType is frozen against
/// future modifications. </exception>
/// <seealso cref= #numericPrecisionStep() </seealso>
public virtual int NumericPrecisionStep
@@ -327,7 +324,7 @@ namespace Lucene.Net.Documents
/// Prints a Field for human consumption. </summary>
public override sealed string ToString()
{
- StringBuilder result = new StringBuilder();
+ var result = new StringBuilder();
if (Stored)
{
result.Append("stored");
@@ -363,10 +360,10 @@ namespace Lucene.Net.Documents
{
result.Append(",omitNorms");
}
- if (IndexOptions_Renamed != FieldInfo.IndexOptions.DOCS_AND_FREQS_AND_POSITIONS)
+ if (_indexOptions != FieldInfo.IndexOptions.DOCS_AND_FREQS_AND_POSITIONS)
{
result.Append(",indexOptions=");
- result.Append(IndexOptions_Renamed);
+ result.Append(_indexOptions);
}
if (numericType != null)
{
@@ -402,7 +399,7 @@ namespace Lucene.Net.Documents
/// <summary>
/// Set's the field's DocValuesType </summary>
/// <param name="type"> DocValues type, or null if no DocValues should be stored. </param>
- /// <exception cref="IllegalStateException"> if this FieldType is frozen against
+ /// <exception cref="InvalidOperationException"> if this FieldType is frozen against
/// future modifications. </exception>
/// <seealso cref= #docValueType() </seealso>
public FieldInfo.DocValuesType_e? DocValueType
http://git-wip-us.apache.org/repos/asf/lucenenet/blob/f69360e2/src/Lucene.Net.Core/Document/FloatField.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Core/Document/FloatField.cs b/src/Lucene.Net.Core/Document/FloatField.cs
index 809e780..8e0e64f 100644
--- a/src/Lucene.Net.Core/Document/FloatField.cs
+++ b/src/Lucene.Net.Core/Document/FloatField.cs
@@ -127,13 +127,13 @@ namespace Lucene.Net.Documents
TYPE_NOT_STORED.Indexed = true;
TYPE_NOT_STORED.Tokenized = true;
TYPE_NOT_STORED.OmitNorms = true;
- TYPE_NOT_STORED.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_ONLY;
+ TYPE_NOT_STORED.IndexOptions = FieldInfo.IndexOptions.DOCS_ONLY;
TYPE_NOT_STORED.NumericTypeValue = Documents.FieldType.NumericType.FLOAT;
TYPE_NOT_STORED.Freeze();
TYPE_STORED.Indexed = true;
TYPE_STORED.Tokenized = true;
TYPE_STORED.OmitNorms = true;
- TYPE_STORED.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_ONLY;
+ TYPE_STORED.IndexOptions = FieldInfo.IndexOptions.DOCS_ONLY;
TYPE_STORED.NumericTypeValue = Documents.FieldType.NumericType.FLOAT;
TYPE_STORED.Stored = true;
TYPE_STORED.Freeze();
http://git-wip-us.apache.org/repos/asf/lucenenet/blob/f69360e2/src/Lucene.Net.Core/Document/IntField.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Core/Document/IntField.cs b/src/Lucene.Net.Core/Document/IntField.cs
index c3b1996..1a52496 100644
--- a/src/Lucene.Net.Core/Document/IntField.cs
+++ b/src/Lucene.Net.Core/Document/IntField.cs
@@ -126,13 +126,13 @@ namespace Lucene.Net.Documents
TYPE_NOT_STORED.Indexed = true;
TYPE_NOT_STORED.Tokenized = true;
TYPE_NOT_STORED.OmitNorms = true;
- TYPE_NOT_STORED.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_ONLY;
+ TYPE_NOT_STORED.IndexOptions = FieldInfo.IndexOptions.DOCS_ONLY;
TYPE_NOT_STORED.NumericTypeValue = Documents.FieldType.NumericType.INT;
TYPE_NOT_STORED.Freeze();
TYPE_STORED.Indexed = true;
TYPE_STORED.Tokenized = true;
TYPE_STORED.OmitNorms = true;
- TYPE_STORED.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_ONLY;
+ TYPE_STORED.IndexOptions = FieldInfo.IndexOptions.DOCS_ONLY;
TYPE_STORED.NumericTypeValue = Documents.FieldType.NumericType.INT;
TYPE_STORED.Stored = true;
TYPE_STORED.Freeze();
http://git-wip-us.apache.org/repos/asf/lucenenet/blob/f69360e2/src/Lucene.Net.Core/Document/LongField.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Core/Document/LongField.cs b/src/Lucene.Net.Core/Document/LongField.cs
index 74d63df..61a7cad 100644
--- a/src/Lucene.Net.Core/Document/LongField.cs
+++ b/src/Lucene.Net.Core/Document/LongField.cs
@@ -131,13 +131,13 @@ namespace Lucene.Net.Documents
TYPE_NOT_STORED.Indexed = true;
TYPE_NOT_STORED.Tokenized = true;
TYPE_NOT_STORED.OmitNorms = true;
- TYPE_NOT_STORED.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_ONLY;
+ TYPE_NOT_STORED.IndexOptions = FieldInfo.IndexOptions.DOCS_ONLY;
TYPE_NOT_STORED.NumericTypeValue = Documents.FieldType.NumericType.LONG;
TYPE_NOT_STORED.Freeze();
TYPE_STORED.Indexed = true;
TYPE_STORED.Tokenized = true;
TYPE_STORED.OmitNorms = true;
- TYPE_STORED.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_ONLY;
+ TYPE_STORED.IndexOptions = FieldInfo.IndexOptions.DOCS_ONLY;
TYPE_STORED.NumericTypeValue = Documents.FieldType.NumericType.LONG;
TYPE_STORED.Stored = true;
TYPE_STORED.Freeze();
http://git-wip-us.apache.org/repos/asf/lucenenet/blob/f69360e2/src/Lucene.Net.Core/Document/StringField.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Core/Document/StringField.cs b/src/Lucene.Net.Core/Document/StringField.cs
index 86abc2f..2766a35 100644
--- a/src/Lucene.Net.Core/Document/StringField.cs
+++ b/src/Lucene.Net.Core/Document/StringField.cs
@@ -44,13 +44,13 @@ namespace Lucene.Net.Documents
{
TYPE_NOT_STORED.Indexed = true;
TYPE_NOT_STORED.OmitNorms = true;
- TYPE_NOT_STORED.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_ONLY;
+ TYPE_NOT_STORED.IndexOptions = FieldInfo.IndexOptions.DOCS_ONLY;
TYPE_NOT_STORED.Tokenized = false;
TYPE_NOT_STORED.Freeze();
TYPE_STORED.Indexed = true;
TYPE_STORED.OmitNorms = true;
- TYPE_STORED.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_ONLY;
+ TYPE_STORED.IndexOptions = FieldInfo.IndexOptions.DOCS_ONLY;
TYPE_STORED.Stored = true;
TYPE_STORED.Tokenized = false;
TYPE_STORED.Freeze();
http://git-wip-us.apache.org/repos/asf/lucenenet/blob/f69360e2/src/Lucene.Net.Core/Index/DocInverterPerField.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Core/Index/DocInverterPerField.cs b/src/Lucene.Net.Core/Index/DocInverterPerField.cs
index fe8d18f..18f0ff6 100644
--- a/src/Lucene.Net.Core/Index/DocInverterPerField.cs
+++ b/src/Lucene.Net.Core/Index/DocInverterPerField.cs
@@ -86,7 +86,7 @@ namespace Lucene.Net.Index
// only bother checking offsets if something will consume them.
// TODO: after we fix analyzers, also check if termVectorOffsets will be indexed.
- bool checkOffsets = fieldType.IndexOptionsValue == FieldInfo.IndexOptions.DOCS_AND_FREQS_AND_POSITIONS_AND_OFFSETS;
+ bool checkOffsets = fieldType.IndexOptions == FieldInfo.IndexOptions.DOCS_AND_FREQS_AND_POSITIONS_AND_OFFSETS;
int lastStartOffset = 0;
if (i > 0)
http://git-wip-us.apache.org/repos/asf/lucenenet/blob/f69360e2/src/Lucene.Net.Core/Index/FieldInfo.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Core/Index/FieldInfo.cs b/src/Lucene.Net.Core/Index/FieldInfo.cs
index 57f0a95..8a49c9c 100644
--- a/src/Lucene.Net.Core/Index/FieldInfo.cs
+++ b/src/Lucene.Net.Core/Index/FieldInfo.cs
@@ -184,7 +184,7 @@ namespace Lucene.Net.Index
internal void Update(IndexableFieldType ft)
{
- Update(ft.Indexed, false, ft.OmitNorms, false, ft.IndexOptionsValue);
+ Update(ft.Indexed, false, ft.OmitNorms, false, ft.IndexOptions);
}
// should only be called by FieldInfos#addOrUpdate
http://git-wip-us.apache.org/repos/asf/lucenenet/blob/f69360e2/src/Lucene.Net.Core/Index/FieldInfos.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Core/Index/FieldInfos.cs b/src/Lucene.Net.Core/Index/FieldInfos.cs
index e54f830..9701907 100644
--- a/src/Lucene.Net.Core/Index/FieldInfos.cs
+++ b/src/Lucene.Net.Core/Index/FieldInfos.cs
@@ -372,7 +372,7 @@ namespace Lucene.Net.Index
// rather, each component in the chain should update
// what it "owns". EG fieldType.indexOptions() should
// be updated by maybe FreqProxTermsWriterPerField:
- return AddOrUpdateInternal(name, -1, fieldType.Indexed, false, fieldType.OmitNorms, false, fieldType.IndexOptionsValue, fieldType.DocValueType, null);
+ return AddOrUpdateInternal(name, -1, fieldType.Indexed, false, fieldType.OmitNorms, false, fieldType.IndexOptions, fieldType.DocValueType, null);
}
internal FieldInfo AddOrUpdateInternal(string name, int preferredFieldNumber, bool isIndexed, bool storeTermVector, bool omitNorms, bool storePayloads, FieldInfo.IndexOptions? indexOptions, DocValuesType_e? docValues, DocValuesType_e? normType)
http://git-wip-us.apache.org/repos/asf/lucenenet/blob/f69360e2/src/Lucene.Net.Core/Index/IndexableFieldType.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Core/Index/IndexableFieldType.cs b/src/Lucene.Net.Core/Index/IndexableFieldType.cs
index b30e5d1..da2d3e9 100644
--- a/src/Lucene.Net.Core/Index/IndexableFieldType.cs
+++ b/src/Lucene.Net.Core/Index/IndexableFieldType.cs
@@ -93,10 +93,10 @@ namespace Lucene.Net.Index
bool OmitNorms { get; set; }
/// <summary>
- /// <seealso cref="IndexOptionsValue"/>, describing what should be
+ /// <seealso cref="IndexOptions"/>, describing what should be
/// recorded into the inverted index
/// </summary>
- FieldInfo.IndexOptions? IndexOptionsValue { get; set; }
+ FieldInfo.IndexOptions? IndexOptions { get; set; }
FieldType.NumericType? NumericTypeValue { get; set; }
http://git-wip-us.apache.org/repos/asf/lucenenet/blob/f69360e2/src/Lucene.Net.TestFramework/Analysis/BaseTokenStreamTestCase.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.TestFramework/Analysis/BaseTokenStreamTestCase.cs b/src/Lucene.Net.TestFramework/Analysis/BaseTokenStreamTestCase.cs
index f2f1bde..ae519a1 100644
--- a/src/Lucene.Net.TestFramework/Analysis/BaseTokenStreamTestCase.cs
+++ b/src/Lucene.Net.TestFramework/Analysis/BaseTokenStreamTestCase.cs
@@ -701,25 +701,25 @@ namespace Lucene.Net.Analysis
switch (random.Next(4))
{
case 0:
- ft.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_ONLY;
+ ft.IndexOptions = FieldInfo.IndexOptions.DOCS_ONLY;
break;
case 1:
- ft.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_AND_FREQS;
+ ft.IndexOptions = FieldInfo.IndexOptions.DOCS_AND_FREQS;
break;
case 2:
- ft.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_AND_FREQS_AND_POSITIONS;
+ ft.IndexOptions = FieldInfo.IndexOptions.DOCS_AND_FREQS_AND_POSITIONS;
break;
default:
if (supportsOffsets && offsetsAreCorrect)
{
- ft.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_AND_FREQS_AND_POSITIONS_AND_OFFSETS;
+ ft.IndexOptions = FieldInfo.IndexOptions.DOCS_AND_FREQS_AND_POSITIONS_AND_OFFSETS;
}
else
{
- ft.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_AND_FREQS_AND_POSITIONS;
+ ft.IndexOptions = FieldInfo.IndexOptions.DOCS_AND_FREQS_AND_POSITIONS;
}
break;
}
http://git-wip-us.apache.org/repos/asf/lucenenet/blob/f69360e2/src/Lucene.Net.TestFramework/Index/BasePostingsFormatTestCase.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.TestFramework/Index/BasePostingsFormatTestCase.cs b/src/Lucene.Net.TestFramework/Index/BasePostingsFormatTestCase.cs
index 347fa9c..1fa531e 100644
--- a/src/Lucene.Net.TestFramework/Index/BasePostingsFormatTestCase.cs
+++ b/src/Lucene.Net.TestFramework/Index/BasePostingsFormatTestCase.cs
@@ -1319,7 +1319,7 @@ namespace Lucene.Net.Index
{
continue;
}
- var ft = new FieldType {IndexOptionsValue = opts, Indexed = true, OmitNorms = true};
+ var ft = new FieldType {IndexOptions = opts, Indexed = true, OmitNorms = true};
ft.Freeze();
int numFields = Random().Next(5);
for (int j = 0; j < numFields; ++j)
http://git-wip-us.apache.org/repos/asf/lucenenet/blob/f69360e2/src/Lucene.Net.TestFramework/Index/DocHelper.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.TestFramework/Index/DocHelper.cs b/src/Lucene.Net.TestFramework/Index/DocHelper.cs
index d80d755..483d174 100644
--- a/src/Lucene.Net.TestFramework/Index/DocHelper.cs
+++ b/src/Lucene.Net.TestFramework/Index/DocHelper.cs
@@ -222,7 +222,7 @@ namespace Lucene.Net.Index
CustomType5.Tokenized = false;
NoNormsField = new Field(NO_NORMS_KEY, NO_NORMS_TEXT, CustomType5);
CustomType6 = new FieldType(TextField.TYPE_STORED);
- CustomType6.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_ONLY;
+ CustomType6.IndexOptions = FieldInfo.IndexOptions.DOCS_ONLY;
NoTFField = new Field(NO_TF_KEY, NO_TF_TEXT, CustomType6);
CustomType7 = new FieldType();
CustomType7.Stored = true;
@@ -285,7 +285,7 @@ namespace Lucene.Net.Index
{
Add(Unstored, f);
}
- if (f.FieldType().IndexOptionsValue == FieldInfo.IndexOptions.DOCS_ONLY)
+ if (f.FieldType().IndexOptions == FieldInfo.IndexOptions.DOCS_ONLY)
{
Add(NoTf, f);
}
@@ -293,7 +293,7 @@ namespace Lucene.Net.Index
{
Add(NoNorms, f);
}
- if (f.FieldType().IndexOptionsValue == FieldInfo.IndexOptions.DOCS_ONLY)
+ if (f.FieldType().IndexOptions == FieldInfo.IndexOptions.DOCS_ONLY)
{
Add(NoTf, f);
}
http://git-wip-us.apache.org/repos/asf/lucenenet/blob/f69360e2/src/Lucene.Net.Tests/core/Analysis/TestMockAnalyzer.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Tests/core/Analysis/TestMockAnalyzer.cs b/src/Lucene.Net.Tests/core/Analysis/TestMockAnalyzer.cs
index 18dd8e1..dcff51c 100644
--- a/src/Lucene.Net.Tests/core/Analysis/TestMockAnalyzer.cs
+++ b/src/Lucene.Net.Tests/core/Analysis/TestMockAnalyzer.cs
@@ -352,7 +352,7 @@ namespace Lucene.Net.Analysis
Document doc = new Document();
FieldType ft = new FieldType();
ft.Indexed = true;
- ft.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_ONLY;
+ ft.IndexOptions = FieldInfo.IndexOptions.DOCS_ONLY;
ft.Tokenized = true;
ft.StoreTermVectors = true;
ft.StoreTermVectorPositions = true;
http://git-wip-us.apache.org/repos/asf/lucenenet/blob/f69360e2/src/Lucene.Net.Tests/core/Codecs/Lucene40/TestLucene40PostingsReader.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Tests/core/Codecs/Lucene40/TestLucene40PostingsReader.cs b/src/Lucene.Net.Tests/core/Codecs/Lucene40/TestLucene40PostingsReader.cs
index 1442576..63dfa8e 100644
--- a/src/Lucene.Net.Tests/core/Codecs/Lucene40/TestLucene40PostingsReader.cs
+++ b/src/Lucene.Net.Tests/core/Codecs/Lucene40/TestLucene40PostingsReader.cs
@@ -84,7 +84,7 @@ namespace Lucene.Net.Codecs.Lucene40
titleType.StoreTermVectors = true;
titleType.StoreTermVectorPositions = true;
titleType.StoreTermVectorOffsets = true;
- titleType.IndexOptionsValue = IndexOptions();
+ titleType.IndexOptions = IndexOptions();
Field titleField = new Field("title", "", titleType);
doc.Add(titleField);
@@ -93,7 +93,7 @@ namespace Lucene.Net.Codecs.Lucene40
bodyType.StoreTermVectors = true;
bodyType.StoreTermVectorPositions = true;
bodyType.StoreTermVectorOffsets = true;
- bodyType.IndexOptionsValue = IndexOptions();
+ bodyType.IndexOptions = IndexOptions();
Field bodyField = new Field("body", "", bodyType);
doc.Add(bodyField);
http://git-wip-us.apache.org/repos/asf/lucenenet/blob/f69360e2/src/Lucene.Net.Tests/core/Codecs/Lucene41/TestBlockPostingsFormat2.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Tests/core/Codecs/Lucene41/TestBlockPostingsFormat2.cs b/src/Lucene.Net.Tests/core/Codecs/Lucene41/TestBlockPostingsFormat2.cs
index 8dd033f..a7c6bfc 100644
--- a/src/Lucene.Net.Tests/core/Codecs/Lucene41/TestBlockPostingsFormat2.cs
+++ b/src/Lucene.Net.Tests/core/Codecs/Lucene41/TestBlockPostingsFormat2.cs
@@ -82,7 +82,7 @@ namespace Lucene.Net.Codecs.Lucene41
StoreTermVectorOffsets = true,
StoreTermVectorPositions = true,
StoreTermVectorPayloads = true,
- IndexOptionsValue = option
+ IndexOptions = option
};
// turn on tvs for a cross-check, since we rely upon checkindex in this test (for now)
doc.Add(new Field(option.ToString(), "", ft));
http://git-wip-us.apache.org/repos/asf/lucenenet/blob/f69360e2/src/Lucene.Net.Tests/core/Codecs/Lucene41/TestBlockPostingsFormat3.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Tests/core/Codecs/Lucene41/TestBlockPostingsFormat3.cs b/src/Lucene.Net.Tests/core/Codecs/Lucene41/TestBlockPostingsFormat3.cs
index 3bc9da8..304f74b 100644
--- a/src/Lucene.Net.Tests/core/Codecs/Lucene41/TestBlockPostingsFormat3.cs
+++ b/src/Lucene.Net.Tests/core/Codecs/Lucene41/TestBlockPostingsFormat3.cs
@@ -85,12 +85,12 @@ namespace Lucene.Net.Codecs.Lucene41
FieldType docsOnlyType = new FieldType(TextField.TYPE_NOT_STORED);
// turn this on for a cross-check
docsOnlyType.StoreTermVectors = true;
- docsOnlyType.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_ONLY;
+ docsOnlyType.IndexOptions = FieldInfo.IndexOptions.DOCS_ONLY;
FieldType docsAndFreqsType = new FieldType(TextField.TYPE_NOT_STORED);
// turn this on for a cross-check
docsAndFreqsType.StoreTermVectors = true;
- docsAndFreqsType.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_AND_FREQS;
+ docsAndFreqsType.IndexOptions = FieldInfo.IndexOptions.DOCS_AND_FREQS;
FieldType positionsType = new FieldType(TextField.TYPE_NOT_STORED);
// turn these on for a cross-check
@@ -99,7 +99,7 @@ namespace Lucene.Net.Codecs.Lucene41
positionsType.StoreTermVectorOffsets = true;
positionsType.StoreTermVectorPayloads = true;
FieldType offsetsType = new FieldType(positionsType);
- offsetsType.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_AND_FREQS_AND_POSITIONS_AND_OFFSETS;
+ offsetsType.IndexOptions = FieldInfo.IndexOptions.DOCS_AND_FREQS_AND_POSITIONS_AND_OFFSETS;
Field field1 = new Field("field1docs", "", docsOnlyType);
Field field2 = new Field("field2freqs", "", docsAndFreqsType);
Field field3 = new Field("field3positions", "", positionsType);
http://git-wip-us.apache.org/repos/asf/lucenenet/blob/f69360e2/src/Lucene.Net.Tests/core/Index/Test2BPostings.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Tests/core/Index/Test2BPostings.cs b/src/Lucene.Net.Tests/core/Index/Test2BPostings.cs
index cdd5f3d..bfc2d61 100644
--- a/src/Lucene.Net.Tests/core/Index/Test2BPostings.cs
+++ b/src/Lucene.Net.Tests/core/Index/Test2BPostings.cs
@@ -65,7 +65,7 @@ namespace Lucene.Net.Index
Document doc = new Document();
FieldType ft = new FieldType(TextField.TYPE_NOT_STORED);
ft.OmitNorms = true;
- ft.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_ONLY;
+ ft.IndexOptions = FieldInfo.IndexOptions.DOCS_ONLY;
Field field = new Field("field", new MyTokenStream(), ft);
doc.Add(field);
http://git-wip-us.apache.org/repos/asf/lucenenet/blob/f69360e2/src/Lucene.Net.Tests/core/Index/Test2BPostingsBytes.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Tests/core/Index/Test2BPostingsBytes.cs b/src/Lucene.Net.Tests/core/Index/Test2BPostingsBytes.cs
index 3a99924..857e0eb 100644
--- a/src/Lucene.Net.Tests/core/Index/Test2BPostingsBytes.cs
+++ b/src/Lucene.Net.Tests/core/Index/Test2BPostingsBytes.cs
@@ -71,7 +71,7 @@ namespace Lucene.Net.Index
Document doc = new Document();
FieldType ft = new FieldType(TextField.TYPE_NOT_STORED);
- ft.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_AND_FREQS;
+ ft.IndexOptions = FieldInfo.IndexOptions.DOCS_AND_FREQS;
ft.OmitNorms = true;
MyTokenStream tokenStream = new MyTokenStream();
Field field = new Field("field", tokenStream, ft);
http://git-wip-us.apache.org/repos/asf/lucenenet/blob/f69360e2/src/Lucene.Net.Tests/core/Index/Test2BTerms.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Tests/core/Index/Test2BTerms.cs b/src/Lucene.Net.Tests/core/Index/Test2BTerms.cs
index ea114c1..a36a885 100644
--- a/src/Lucene.Net.Tests/core/Index/Test2BTerms.cs
+++ b/src/Lucene.Net.Tests/core/Index/Test2BTerms.cs
@@ -205,7 +205,7 @@ namespace Lucene.Net.Index
MyTokenStream ts = new MyTokenStream(Random(), TERMS_PER_DOC);
FieldType customType = new FieldType(TextField.TYPE_NOT_STORED);
- customType.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_ONLY;
+ customType.IndexOptions = FieldInfo.IndexOptions.DOCS_ONLY;
customType.OmitNorms = true;
Field field = new Field("field", ts, customType);
doc.Add(field);
http://git-wip-us.apache.org/repos/asf/lucenenet/blob/f69360e2/src/Lucene.Net.Tests/core/Index/TestBagOfPositions.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Tests/core/Index/TestBagOfPositions.cs b/src/Lucene.Net.Tests/core/Index/TestBagOfPositions.cs
index 1b3840c..3579f5a 100644
--- a/src/Lucene.Net.Tests/core/Index/TestBagOfPositions.cs
+++ b/src/Lucene.Net.Tests/core/Index/TestBagOfPositions.cs
@@ -99,12 +99,12 @@ namespace Lucene.Net.Index
int options = Random().Next(3);
if (options == 0)
{
- fieldType.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_AND_FREQS; // we dont actually need positions
+ fieldType.IndexOptions = FieldInfo.IndexOptions.DOCS_AND_FREQS; // we dont actually need positions
fieldType.StoreTermVectors = true; // but enforce term vectors when we do this so we check SOMETHING
}
else if (options == 1 && !DoesntSupportOffsets.Contains(TestUtil.GetPostingsFormat("field")))
{
- fieldType.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_AND_FREQS_AND_POSITIONS_AND_OFFSETS;
+ fieldType.IndexOptions = FieldInfo.IndexOptions.DOCS_AND_FREQS_AND_POSITIONS_AND_OFFSETS;
}
// else just positions
http://git-wip-us.apache.org/repos/asf/lucenenet/blob/f69360e2/src/Lucene.Net.Tests/core/Index/TestCodecs.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Tests/core/Index/TestCodecs.cs b/src/Lucene.Net.Tests/core/Index/TestCodecs.cs
index c7d1e3d..6c0804e 100644
--- a/src/Lucene.Net.Tests/core/Index/TestCodecs.cs
+++ b/src/Lucene.Net.Tests/core/Index/TestCodecs.cs
@@ -182,7 +182,7 @@ namespace Lucene.Net.Index
set { }
}
- public FieldInfo.IndexOptions? IndexOptionsValue
+ public FieldInfo.IndexOptions? IndexOptions
{
get { return OmitTF ? FieldInfo.IndexOptions.DOCS_ONLY : FieldInfo.IndexOptions.DOCS_AND_FREQS_AND_POSITIONS; }
set { }
http://git-wip-us.apache.org/repos/asf/lucenenet/blob/f69360e2/src/Lucene.Net.Tests/core/Index/TestDocumentWriter.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Tests/core/Index/TestDocumentWriter.cs b/src/Lucene.Net.Tests/core/Index/TestDocumentWriter.cs
index d9ee02c..e66a2fe 100644
--- a/src/Lucene.Net.Tests/core/Index/TestDocumentWriter.cs
+++ b/src/Lucene.Net.Tests/core/Index/TestDocumentWriter.cs
@@ -383,7 +383,7 @@ namespace Lucene.Net.Index
doc.Add(NewField("f1", "v2", customType2));
// f2 has no TF
FieldType customType3 = new FieldType(TextField.TYPE_NOT_STORED);
- customType3.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_ONLY;
+ customType3.IndexOptions = FieldInfo.IndexOptions.DOCS_ONLY;
Field f = NewField("f2", "v1", customType3);
doc.Add(f);
doc.Add(NewField("f2", "v2", customType2));
http://git-wip-us.apache.org/repos/asf/lucenenet/blob/f69360e2/src/Lucene.Net.Tests/core/Index/TestFieldsReader.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Tests/core/Index/TestFieldsReader.cs b/src/Lucene.Net.Tests/core/Index/TestFieldsReader.cs
index ce1cdca..1909432 100644
--- a/src/Lucene.Net.Tests/core/Index/TestFieldsReader.cs
+++ b/src/Lucene.Net.Tests/core/Index/TestFieldsReader.cs
@@ -88,19 +88,19 @@ namespace Lucene.Net.Index
Assert.IsTrue(field.FieldType().StoreTermVectors);
Assert.IsFalse(field.FieldType().OmitNorms);
- Assert.IsTrue(field.FieldType().IndexOptionsValue == FieldInfo.IndexOptions.DOCS_AND_FREQS_AND_POSITIONS);
+ Assert.IsTrue(field.FieldType().IndexOptions == FieldInfo.IndexOptions.DOCS_AND_FREQS_AND_POSITIONS);
field = (Field)doc.GetField(DocHelper.TEXT_FIELD_3_KEY);
Assert.IsTrue(field != null);
Assert.IsFalse(field.FieldType().StoreTermVectors);
Assert.IsTrue(field.FieldType().OmitNorms);
- Assert.IsTrue(field.FieldType().IndexOptionsValue == FieldInfo.IndexOptions.DOCS_AND_FREQS_AND_POSITIONS);
+ Assert.IsTrue(field.FieldType().IndexOptions == FieldInfo.IndexOptions.DOCS_AND_FREQS_AND_POSITIONS);
field = (Field)doc.GetField(DocHelper.NO_TF_KEY);
Assert.IsTrue(field != null);
Assert.IsFalse(field.FieldType().StoreTermVectors);
Assert.IsFalse(field.FieldType().OmitNorms);
- Assert.IsTrue(field.FieldType().IndexOptionsValue == FieldInfo.IndexOptions.DOCS_ONLY);
+ Assert.IsTrue(field.FieldType().IndexOptions == FieldInfo.IndexOptions.DOCS_ONLY);
DocumentStoredFieldVisitor visitor = new DocumentStoredFieldVisitor(DocHelper.TEXT_FIELD_3_KEY);
reader.Document(0, visitor);
http://git-wip-us.apache.org/repos/asf/lucenenet/blob/f69360e2/src/Lucene.Net.Tests/core/Index/TestIndexWriter.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Tests/core/Index/TestIndexWriter.cs b/src/Lucene.Net.Tests/core/Index/TestIndexWriter.cs
index 9b16201..e489065 100644
--- a/src/Lucene.Net.Tests/core/Index/TestIndexWriter.cs
+++ b/src/Lucene.Net.Tests/core/Index/TestIndexWriter.cs
@@ -2109,10 +2109,10 @@ namespace Lucene.Net.Index
IndexWriter w = new IndexWriter(dir, new IndexWriterConfig(TEST_VERSION_CURRENT, new MockAnalyzer(Random())));
FieldType docsAndFreqs = new FieldType(TextField.TYPE_NOT_STORED);
- docsAndFreqs.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_AND_FREQS;
+ docsAndFreqs.IndexOptions = FieldInfo.IndexOptions.DOCS_AND_FREQS;
FieldType docsOnly = new FieldType(TextField.TYPE_NOT_STORED);
- docsOnly.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_ONLY;
+ docsOnly.IndexOptions = FieldInfo.IndexOptions.DOCS_ONLY;
Document doc = new Document();
doc.Add(new Field("field", "a b c", docsAndFreqs));
http://git-wip-us.apache.org/repos/asf/lucenenet/blob/f69360e2/src/Lucene.Net.Tests/core/Index/TestIndexableField.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Tests/core/Index/TestIndexableField.cs b/src/Lucene.Net.Tests/core/Index/TestIndexableField.cs
index 81bd96f..48898b7 100644
--- a/src/Lucene.Net.Tests/core/Index/TestIndexableField.cs
+++ b/src/Lucene.Net.Tests/core/Index/TestIndexableField.cs
@@ -126,7 +126,7 @@ namespace Lucene.Net.Index
set { }
}
- public FieldInfo.IndexOptions? IndexOptionsValue
+ public FieldInfo.IndexOptions? IndexOptions
{
get { return FieldInfo.IndexOptions.DOCS_AND_FREQS_AND_POSITIONS; }
set { }
http://git-wip-us.apache.org/repos/asf/lucenenet/blob/f69360e2/src/Lucene.Net.Tests/core/Index/TestLongPostings.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Tests/core/Index/TestLongPostings.cs b/src/Lucene.Net.Tests/core/Index/TestLongPostings.cs
index 99dbc8d..38f3584 100644
--- a/src/Lucene.Net.Tests/core/Index/TestLongPostings.cs
+++ b/src/Lucene.Net.Tests/core/Index/TestLongPostings.cs
@@ -383,7 +383,7 @@ namespace Lucene.Net.Index
RandomIndexWriter riw = new RandomIndexWriter(Random(), dir, iwc);
FieldType ft = new FieldType(TextField.TYPE_NOT_STORED);
- ft.IndexOptionsValue = options;
+ ft.IndexOptions = options;
for (int idx = 0; idx < NUM_DOCS; idx++)
{
Document doc = new Document();
http://git-wip-us.apache.org/repos/asf/lucenenet/blob/f69360e2/src/Lucene.Net.Tests/core/Index/TestOmitPositions.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Tests/core/Index/TestOmitPositions.cs b/src/Lucene.Net.Tests/core/Index/TestOmitPositions.cs
index 9118dd0..527e207 100644
--- a/src/Lucene.Net.Tests/core/Index/TestOmitPositions.cs
+++ b/src/Lucene.Net.Tests/core/Index/TestOmitPositions.cs
@@ -48,7 +48,7 @@ namespace Lucene.Net.Index
RandomIndexWriter w = new RandomIndexWriter(Random(), dir);
Document doc = new Document();
FieldType ft = new FieldType(TextField.TYPE_NOT_STORED);
- ft.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_AND_FREQS;
+ ft.IndexOptions = FieldInfo.IndexOptions.DOCS_AND_FREQS;
Field f = NewField("foo", "this is a test test", ft);
doc.Add(f);
for (int i = 0; i < 100; i++)
@@ -83,7 +83,7 @@ namespace Lucene.Net.Index
// f1,f2,f3: docs only
FieldType ft = new FieldType(TextField.TYPE_NOT_STORED);
- ft.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_ONLY;
+ ft.IndexOptions = FieldInfo.IndexOptions.DOCS_ONLY;
Field f1 = NewField("f1", "this field has docs only", ft);
d.Add(f1);
@@ -95,7 +95,7 @@ namespace Lucene.Net.Index
d.Add(f3);
FieldType ft2 = new FieldType(TextField.TYPE_NOT_STORED);
- ft2.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_AND_FREQS;
+ ft2.IndexOptions = FieldInfo.IndexOptions.DOCS_AND_FREQS;
// f4,f5,f6 docs and freqs
Field f4 = NewField("f4", "this field has docs and freqs", ft2);
@@ -108,7 +108,7 @@ namespace Lucene.Net.Index
d.Add(f6);
FieldType ft3 = new FieldType(TextField.TYPE_NOT_STORED);
- ft3.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_AND_FREQS_AND_POSITIONS;
+ ft3.IndexOptions = FieldInfo.IndexOptions.DOCS_AND_FREQS_AND_POSITIONS;
// f7,f8,f9 docs/freqs/positions
Field f7 = NewField("f7", "this field has docs and freqs and positions", ft3);
@@ -212,7 +212,7 @@ namespace Lucene.Net.Index
Document d = new Document();
FieldType ft = new FieldType(TextField.TYPE_NOT_STORED);
- ft.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_AND_FREQS;
+ ft.IndexOptions = FieldInfo.IndexOptions.DOCS_AND_FREQS;
Field f1 = NewField("f1", "this field has term freqs", ft);
d.Add(f1);
@@ -251,7 +251,7 @@ namespace Lucene.Net.Index
{
// no positions
FieldType ft = new FieldType(TextField.TYPE_NOT_STORED);
- ft.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_AND_FREQS;
+ ft.IndexOptions = FieldInfo.IndexOptions.DOCS_AND_FREQS;
Directory dir = NewDirectory();
RandomIndexWriter iw = new RandomIndexWriter(Random(), dir);
http://git-wip-us.apache.org/repos/asf/lucenenet/blob/f69360e2/src/Lucene.Net.Tests/core/Index/TestOmitTf.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Tests/core/Index/TestOmitTf.cs b/src/Lucene.Net.Tests/core/Index/TestOmitTf.cs
index 6afd51c..0da91f0 100644
--- a/src/Lucene.Net.Tests/core/Index/TestOmitTf.cs
+++ b/src/Lucene.Net.Tests/core/Index/TestOmitTf.cs
@@ -105,7 +105,7 @@ namespace Lucene.Net.Index
static TestOmitTf()
{
- OmitType.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_ONLY;
+ OmitType.IndexOptions = FieldInfo.IndexOptions.DOCS_ONLY;
}
// Tests whether the DocumentWriter correctly enable the
@@ -590,7 +590,7 @@ namespace Lucene.Net.Index
RandomIndexWriter iw = new RandomIndexWriter(Random(), dir, NewIndexWriterConfig(TEST_VERSION_CURRENT, new MockAnalyzer(Random())));
Document doc = new Document();
FieldType ft = new FieldType(TextField.TYPE_NOT_STORED);
- ft.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_ONLY;
+ ft.IndexOptions = FieldInfo.IndexOptions.DOCS_ONLY;
ft.Freeze();
Field f = NewField("foo", "bar", ft);
doc.Add(f);
http://git-wip-us.apache.org/repos/asf/lucenenet/blob/f69360e2/src/Lucene.Net.Tests/core/Index/TestPostingsOffsets.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Tests/core/Index/TestPostingsOffsets.cs b/src/Lucene.Net.Tests/core/Index/TestPostingsOffsets.cs
index cd552a5..d3c0a0f 100644
--- a/src/Lucene.Net.Tests/core/Index/TestPostingsOffsets.cs
+++ b/src/Lucene.Net.Tests/core/Index/TestPostingsOffsets.cs
@@ -71,7 +71,7 @@ namespace Lucene.Net.Index
Document doc = new Document();
FieldType ft = new FieldType(TextField.TYPE_NOT_STORED);
- ft.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_AND_FREQS_AND_POSITIONS_AND_OFFSETS;
+ ft.IndexOptions = FieldInfo.IndexOptions.DOCS_AND_FREQS_AND_POSITIONS_AND_OFFSETS;
if (Random().NextBoolean())
{
ft.StoreTermVectors = true;
@@ -140,7 +140,7 @@ namespace Lucene.Net.Index
RandomIndexWriter w = new RandomIndexWriter(Random(), dir, Iwc);
FieldType ft = new FieldType(TextField.TYPE_STORED);
- ft.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_AND_FREQS_AND_POSITIONS_AND_OFFSETS;
+ ft.IndexOptions = FieldInfo.IndexOptions.DOCS_AND_FREQS_AND_POSITIONS_AND_OFFSETS;
if (Random().NextBoolean())
{
ft.StoreTermVectors = true;
@@ -250,7 +250,7 @@ namespace Lucene.Net.Index
// TODO: randomize what IndexOptions we use; also test
// changing this up in one IW buffered segment...:
- ft.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_AND_FREQS_AND_POSITIONS_AND_OFFSETS;
+ ft.IndexOptions = FieldInfo.IndexOptions.DOCS_AND_FREQS_AND_POSITIONS_AND_OFFSETS;
if (Random().NextBoolean())
{
ft.StoreTermVectors = true;
@@ -412,7 +412,7 @@ namespace Lucene.Net.Index
else
{
FieldType ft = new FieldType(TextField.TYPE_STORED);
- ft.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_AND_FREQS_AND_POSITIONS_AND_OFFSETS;
+ ft.IndexOptions = FieldInfo.IndexOptions.DOCS_AND_FREQS_AND_POSITIONS_AND_OFFSETS;
if (Random().NextBoolean())
{
// store some term vectors for the checkindex cross-check
@@ -444,7 +444,7 @@ namespace Lucene.Net.Index
customType3.StoreTermVectors = true;
customType3.StoreTermVectorPositions = true;
customType3.StoreTermVectorOffsets = true;
- customType3.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_AND_FREQS_AND_POSITIONS_AND_OFFSETS;
+ customType3.IndexOptions = FieldInfo.IndexOptions.DOCS_AND_FREQS_AND_POSITIONS_AND_OFFSETS;
doc.Add(new Field("content3", "here is more content with aaa aaa aaa", customType3));
doc.Add(new Field("content3", "here is more content with aaa aaa aaa", customType3));
iw.AddDocument(doc);
@@ -515,7 +515,7 @@ namespace Lucene.Net.Index
Token t2 = new Token("foo", int.MaxValue - 500, int.MaxValue);
TokenStream tokenStream = new CannedTokenStream(new Token[] { t1, t2 });
FieldType ft = new FieldType(TextField.TYPE_NOT_STORED);
- ft.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_AND_FREQS_AND_POSITIONS_AND_OFFSETS;
+ ft.IndexOptions = FieldInfo.IndexOptions.DOCS_AND_FREQS_AND_POSITIONS_AND_OFFSETS;
// store some term vectors for the checkindex cross-check
ft.StoreTermVectors = true;
ft.StoreTermVectorPositions = true;
@@ -537,7 +537,7 @@ namespace Lucene.Net.Index
try
{
FieldType ft = new FieldType(TextField.TYPE_NOT_STORED);
- ft.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_AND_FREQS_AND_POSITIONS_AND_OFFSETS;
+ ft.IndexOptions = FieldInfo.IndexOptions.DOCS_AND_FREQS_AND_POSITIONS_AND_OFFSETS;
// store some term vectors for the checkindex cross-check
ft.StoreTermVectors = true;
ft.StoreTermVectorPositions = true;
http://git-wip-us.apache.org/repos/asf/lucenenet/blob/f69360e2/src/Lucene.Net.Tests/core/Search/Similarities/TestSimilarity2.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Tests/core/Search/Similarities/TestSimilarity2.cs b/src/Lucene.Net.Tests/core/Search/Similarities/TestSimilarity2.cs
index a3e68a1..fc6a434 100644
--- a/src/Lucene.Net.Tests/core/Search/Similarities/TestSimilarity2.cs
+++ b/src/Lucene.Net.Tests/core/Search/Similarities/TestSimilarity2.cs
@@ -187,7 +187,7 @@ namespace Lucene.Net.Search.Similarities
RandomIndexWriter iw = new RandomIndexWriter(Random(), dir);
Document doc = new Document();
FieldType ft = new FieldType(TextField.TYPE_NOT_STORED);
- ft.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_ONLY;
+ ft.IndexOptions = FieldInfo.IndexOptions.DOCS_ONLY;
ft.Freeze();
Field f = NewField("foo", "bar", ft);
doc.Add(f);
@@ -216,7 +216,7 @@ namespace Lucene.Net.Search.Similarities
RandomIndexWriter iw = new RandomIndexWriter(Random(), dir);
Document doc = new Document();
FieldType ft = new FieldType(TextField.TYPE_NOT_STORED);
- ft.IndexOptionsValue = FieldInfo.IndexOptions.DOCS_ONLY;
+ ft.IndexOptions = FieldInfo.IndexOptions.DOCS_ONLY;
ft.OmitNorms = true;
ft.Freeze();
Field f = NewField("foo", "bar", ft);