Skip to content

Commit 3ec461d

Browse files
authored
misc: fix typos (#1162)
Minor IDE auto white space strip
1 parent 5a9516c commit 3ec461d

6 files changed

Lines changed: 33 additions & 33 deletions

File tree

src/Lucene.Net.Facet/Taxonomy/CachedOrdinalsReader.cs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -39,25 +39,25 @@ namespace Lucene.Net.Facet.Taxonomy
3939

4040
/// <summary>
4141
/// A per-segment cache of documents' facet ordinals. Every
42-
/// <see cref="CachedOrds"/> holds the ordinals in a raw <see cref="T:int[]"/>,
42+
/// <see cref="CachedOrds"/> holds the ordinals in a raw <see cref="T:int[]"/>,
4343
/// and therefore consumes as much RAM as the total
4444
/// number of ordinals found in the segment, but saves the
4545
/// CPU cost of decoding ordinals during facet counting.
46-
///
46+
///
4747
/// <para>
4848
/// <b>NOTE:</b> every <see cref="CachedOrds"/> is limited to 2.1B
4949
/// total ordinals. If that is a limitation for you then
5050
/// consider limiting the segment size to fewer documents, or
5151
/// use an alternative cache which pages through the category
5252
/// ordinals.
53-
///
53+
///
5454
/// </para>
5555
/// <para>
5656
/// <b>NOTE:</b> when using this cache, it is advised to use
5757
/// a <see cref="DocValuesFormat"/> that does not cache the data in
5858
/// memory, at least for the category lists fields, or
5959
/// otherwise you'll be doing double-caching.
60-
///
60+
///
6161
/// </para>
6262
/// <para>
6363
/// <b>NOTE:</b> create one instance of this and re-use it
@@ -225,7 +225,7 @@ public virtual long RamBytesUsed()
225225
foreach (var pair in ordsCache)
226226
cachedOrdsList.Add(pair.Value);
227227
#else
228-
// LUCENENET specific - since .NET Standard 2.0 and .NET Framework don't have a CondtionalWeakTable enumerator,
228+
// LUCENENET specific - since .NET Standard 2.0 and .NET Framework don't have a ConditionalWeakTable enumerator,
229229
// we use a weak event to retrieve the CachedOrds instances. We look each of these up here to avoid the need
230230
// to attach events to the CachedOrds instances themselves (thus using the existing IndexReader.Dispose()
231231
// method to detach the events rather than using a finalizer in CachedOrds to ensure they are cleaned up).
@@ -250,4 +250,4 @@ public virtual long RamBytesUsed()
250250
return total;
251251
}
252252
}
253-
}
253+
}

src/Lucene.Net.Tests.Analysis.Common/Analysis/Util/TestCharArraySet.cs

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -273,7 +273,7 @@ public virtual void TestUnmodifiableSet()
273273
// CharArraySet.UnmodifiableSet(null);
274274
// fail("can not make null unmodifiable");
275275
//}
276-
//catch (ArgumentNullException) // NOTE: In .NET we throw an ArgumentExcpetion, not a NullReferenceExeption
276+
//catch (ArgumentNullException) // NOTE: In .NET we throw an ArgumentException, not a NullReferenceException
277277
//{
278278
// // expected
279279
//}
@@ -341,7 +341,7 @@ public virtual void TestSingleHighSurrogate()
341341
}
342342

343343
/// @deprecated (3.1) remove this test when lucene 3.0 "broken unicode 4" support is
344-
/// no longer needed.
344+
/// no longer needed.
345345
[Test]
346346
[Obsolete("(3.1) remove this test when lucene 3.0 'broken unicode 4' support is no longer needed.")]
347347
public virtual void TestSupplementaryCharsBWCompat()
@@ -375,7 +375,7 @@ public virtual void TestSupplementaryCharsBWCompat()
375375
}
376376

377377
/// @deprecated (3.1) remove this test when lucene 3.0 "broken unicode 4" support is
378-
/// no longer needed.
378+
/// no longer needed.
379379
[Test]
380380
[Obsolete("(3.1) remove this test when lucene 3.0 'broken unicode 4' support is no longer needed.")]
381381
public virtual void TestSingleHighSurrogateBWComapt()
@@ -600,15 +600,15 @@ public virtual void TestContainsWithNull()
600600
set.Contains((char[])null, 0, 10);
601601
fail("null value must raise NPE");
602602
}
603-
catch (ArgumentException) // NOTE: In .NET we throw an ArgumentExcpetion, not a NullReferenceExeption
603+
catch (ArgumentException) // NOTE: In .NET we throw an ArgumentException, not a NullReferenceException
604604
{
605605
}
606606
try
607607
{
608608
set.Contains((ICharSequence)null);
609609
fail("null value must raise NPE");
610610
}
611-
catch (ArgumentException) // NOTE: In .NET we throw an ArgumentExcpetion, not a NullReferenceExeption
611+
catch (ArgumentException) // NOTE: In .NET we throw an ArgumentException, not a NullReferenceException
612612
{
613613
}
614614
// LUCENENET Specific test for string (since it does not implement ICharSequence)
@@ -617,15 +617,15 @@ public virtual void TestContainsWithNull()
617617
set.Contains((string)null);
618618
fail("null value must raise NPE");
619619
}
620-
catch (ArgumentException) // NOTE: In .NET we throw an ArgumentExcpetion, not a NullReferenceExeption
620+
catch (ArgumentException) // NOTE: In .NET we throw an ArgumentException, not a NullReferenceException
621621
{
622622
}
623623
try
624624
{
625625
set.Contains((object)null);
626626
fail("null value must raise NPE");
627627
}
628-
catch (ArgumentException) // NOTE: In .NET we throw an ArgumentExcpetion, not a NullReferenceExeption
628+
catch (ArgumentException) // NOTE: In .NET we throw an ArgumentException, not a NullReferenceException
629629
{
630630
}
631631
}
@@ -1743,4 +1743,4 @@ public virtual void TestCopyToCharSequence()
17431743

17441744
#endregion
17451745
}
1746-
}
1746+
}

src/Lucene.Net.Tests/Index/TestReaderClosed.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ public virtual void TestReaderChaining()
101101
catch (Exception ace) when (ace.IsAlreadyClosedException())
102102
{
103103
//Assert.AreEqual("this IndexReader cannot be used anymore as one of its child readers was closed", ace.Message);
104-
// LUCENENET specific - ObjectDisposedExeption appends the type of object to the end of the message,
104+
// LUCENENET specific - ObjectDisposedException appends the type of object to the end of the message,
105105
// so we need to check the start of the message only.
106106
assertTrue(ace.Message.StartsWith("this IndexReader cannot be used anymore as one of its child readers was disposed.", StringComparison.Ordinal));
107107
}

src/Lucene.Net/Index/IndexReader.cs

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -411,7 +411,7 @@ public static DirectoryReader Open(Directory directory)
411411
/// <param name="directory"> the index directory </param>
412412
/// <param name="termInfosIndexDivisor"> Subsamples which indexed
413413
/// terms are loaded into RAM. this has the same effect as
414-
/// <see cref="LiveIndexWriterConfig.TermIndexInterval"/>
414+
/// <see cref="LiveIndexWriterConfig.TermIndexInterval"/>
415415
/// (which can be set on <see cref="IndexWriterConfig"/>) except that setting
416416
/// must be done at indexing time while this setting can be
417417
/// set per reader. When set to <c>N</c>, then one in every
@@ -452,7 +452,7 @@ public static DirectoryReader Open(IndexWriter writer, bool applyAllDeletes)
452452

453453
/// <summary>
454454
/// Expert: returns an <see cref="IndexReader"/> reading the index in the given
455-
/// <see cref="IndexCommit"/>.
455+
/// <see cref="IndexCommit"/>.
456456
/// </summary>
457457
/// <param name="commit"> the commit point to open </param>
458458
/// <exception cref="IOException"> if there is a low-level IO error </exception>
@@ -468,7 +468,7 @@ public static DirectoryReader Open(IndexCommit commit)
468468
/// <param name="commit"> the commit point to open </param>
469469
/// <param name="termInfosIndexDivisor"> Subsamples which indexed
470470
/// terms are loaded into RAM. this has the same effect as
471-
/// <see cref="LiveIndexWriterConfig.TermIndexInterval"/>
471+
/// <see cref="LiveIndexWriterConfig.TermIndexInterval"/>
472472
/// (which can be set in <see cref="IndexWriterConfig"/>) except that setting
473473
/// must be done at indexing time while this setting can be
474474
/// set per reader. When set to <c>N</c>, then one in every
@@ -540,7 +540,7 @@ public Terms GetTermVector(int docID, string field)
540540
/// <b>NOTE:</b> for performance reasons, this method does not check if the
541541
/// requested document is deleted, and therefore asking for a deleted document
542542
/// may yield unspecified results. Usually this is not required, however you
543-
/// can test if the doc is deleted by checking the
543+
/// can test if the doc is deleted by checking the
544544
/// <see cref="Util.IBits"/> returned from <see cref="MultiFields.GetLiveDocs"/>.
545545
/// <para/>
546546
/// <b>NOTE:</b> only the content of a field is returned,
@@ -591,13 +591,13 @@ public void Dispose()
591591

592592
/// <summary>
593593
/// Closes files associated with this index.
594-
/// This method implements the disposable pattern.
594+
/// This method implements the disposable pattern.
595595
/// It may be overridden to dispose any managed or unmanaged resources,
596596
/// but be sure to call <c>base.Dispose(disposing)</c> to close files associated with the
597597
/// underlying <see cref="IndexReader"/>.
598598
/// </summary>
599-
/// <param name="disposing"><c>true</c> indicates to dispose all managed
600-
/// and unmanaged resources, <c>false</c> indicates dispose unmanaged
599+
/// <param name="disposing"><c>true</c> indicates to dispose all managed
600+
/// and unmanaged resources, <c>false</c> indicates dispose unmanaged
601601
/// resources only</param>
602602
protected virtual void Dispose(bool disposing)
603603
{
@@ -619,7 +619,7 @@ protected virtual void Dispose(bool disposing)
619619
}
620620

621621
#if !FEATURE_CONDITIONALWEAKTABLE_ENUMERATOR
622-
// LUCENENET specific - since .NET Standard 2.0 and .NET Framework don't have a CondtionalWeakTable enumerator,
622+
// LUCENENET specific - since .NET Standard 2.0 and .NET Framework don't have a ConditionalWeakTable enumerator,
623623
// we use a weak event to retrieve the ConditionalWeakTable items
624624
foreach (var getParentReadersEvent in getParentReadersEvents)
625625
getParentReadersEvent.Unsubscribe(OnGetParentReaders);
@@ -636,7 +636,7 @@ protected virtual void Dispose(bool disposing)
636636
protected internal abstract void DoClose();
637637

638638
#if !FEATURE_CONDITIONALWEAKTABLE_ENUMERATOR
639-
// LUCENENET specific - since .NET Standard 2.0 and .NET Framework don't have a CondtionalWeakTable enumerator,
639+
// LUCENENET specific - since .NET Standard 2.0 and .NET Framework don't have a ConditionalWeakTable enumerator,
640640
// we use a weak event to retrieve the ConditionalWeakTable items
641641
[ExcludeFromRamUsageEstimation]
642642
private readonly ISet<WeakEvents.GetParentReadersEvent> getParentReadersEvents = new JCG.HashSet<WeakEvents.GetParentReadersEvent>();
@@ -699,10 +699,10 @@ private void OnGetCacheKeys(WeakEvents.GetCacheKeysEventArgs e)
699699
public IList<AtomicReaderContext> Leaves => Context.Leaves;
700700

701701
/// <summary>
702-
/// Expert: Returns a key for this <see cref="IndexReader"/>, so
702+
/// Expert: Returns a key for this <see cref="IndexReader"/>, so
703703
/// <see cref="Search.FieldCache"/>/<see cref="Search.CachingWrapperFilter"/> can find
704704
/// it again.
705-
/// This key must not have Equals()/GetHashCode() methods,
705+
/// This key must not have Equals()/GetHashCode() methods,
706706
/// so &quot;equals&quot; means &quot;identical&quot;.
707707
/// </summary>
708708
public virtual object CoreCacheKey =>
@@ -713,7 +713,7 @@ private void OnGetCacheKeys(WeakEvents.GetCacheKeysEventArgs e)
713713
/// <summary>
714714
/// Expert: Returns a key for this <see cref="IndexReader"/> that also includes deletions,
715715
/// so <see cref="Search.IFieldCache"/>/<see cref="Search.CachingWrapperFilter"/> can find it again.
716-
/// This key must not have Equals()/GetHashCode() methods,
716+
/// This key must not have Equals()/GetHashCode() methods,
717717
/// so &quot;equals&quot; means &quot;identical&quot;.
718718
/// </summary>
719719
public virtual object CombinedCoreAndDeletesKey =>

src/Lucene.Net/Search/CachingWrapperFilter.cs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ public CachingWrapperFilter(Filter filter)
6464

6565
/// <summary>
6666
/// Provide the <see cref="DocIdSet"/> to be cached, using the <see cref="DocIdSet"/> provided
67-
/// by the wrapped Filter.
67+
/// by the wrapped Filter.
6868
/// <para/>This implementation returns the given <see cref="DocIdSet"/>,
6969
/// if <see cref="DocIdSet.IsCacheable"/> returns <c>true</c>, else it calls
7070
/// <see cref="CacheImpl(DocIdSetIterator, AtomicReader)"/>
@@ -134,7 +134,7 @@ public override DocIdSet GetDocIdSet(AtomicReaderContext context, IBits acceptDo
134134
try
135135
{
136136
cache.AddOrUpdate(key, docIdSet);
137-
// LUCENENET specific - since .NET Standard 2.0 and .NET Framework don't have a CondtionalWeakTable enumerator,
137+
// LUCENENET specific - since .NET Standard 2.0 and .NET Framework don't have a ConditionalWeakTable enumerator,
138138
// we use a weak event to retrieve the DocIdSet instances
139139
reader.SubscribeToGetCacheKeysEvent(eventAggregator.GetEvent<WeakEvents.GetCacheKeysEvent>());
140140
}
@@ -196,7 +196,7 @@ public virtual long GetSizeInBytes()
196196
foreach (var pair in cache)
197197
docIdSets.Add(pair.Value);
198198
#else
199-
// LUCENENET specific - since .NET Standard 2.0 and .NET Framework don't have a CondtionalWeakTable enumerator,
199+
// LUCENENET specific - since .NET Standard 2.0 and .NET Framework don't have a ConditionalWeakTable enumerator,
200200
// we use a weak event to retrieve the DocIdSet instances. We look each of these up here to avoid the need
201201
// to attach events to the DocIdSet instances themselves (thus using the existing IndexReader.Dispose()
202202
// method to detach the events rather than using a finalizer in DocIdSet to ensure they are cleaned up).
@@ -221,4 +221,4 @@ public virtual long GetSizeInBytes()
221221
return total;
222222
}
223223
}
224-
}
224+
}

src/Lucene.Net/Search/FieldCacheImpl.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,7 @@ private void AddCacheEntries<TKey, TValue>(IList<FieldCache.CacheEntry> result,
186186
}
187187
}
188188
#else
189-
// LUCENENET specific - since .NET Standard 2.0 and .NET Framework don't have a CondtionalWeakTable enumerator,
189+
// LUCENENET specific - since .NET Standard 2.0 and .NET Framework don't have a ConditionalWeakTable enumerator,
190190
// we use a weak event to retrieve the readerKey instances and then lookup the values in the table one by one.
191191
var e = new WeakEvents.GetCacheKeysEventArgs();
192192
eventAggregator.GetEvent<WeakEvents.GetCacheKeysEvent>().Publish(e);
@@ -268,7 +268,7 @@ private void InitReader(AtomicReader reader)
268268
}
269269
}
270270
#if !FEATURE_CONDITIONALWEAKTABLE_ENUMERATOR
271-
// LUCENENET specific - since .NET Standard 2.0 and .NET Framework don't have a CondtionalWeakTable enumerator,
271+
// LUCENENET specific - since .NET Standard 2.0 and .NET Framework don't have a ConditionalWeakTable enumerator,
272272
// we use a weak event to retrieve the readerKey instances
273273
reader.SubscribeToGetCacheKeysEvent(eventAggregator.GetEvent<WeakEvents.GetCacheKeysEvent>());
274274
#endif

0 commit comments

Comments
 (0)