Class FieldComparer.RelevanceComparer
Sorts by descending relevance. NOTE: if you are sorting only by descending relevance and then secondarily by ascending docID, performance is faster using TopScoreDocCollector directly (which all overloads of Search(Query, Int32) use when no Sort is specified).
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: Lucene.Net.Search
Assembly: Lucene.Net.dll
Syntax
public sealed class RelevanceComparer : FieldComparer<Single>
Properties
| Improve this Doc View SourceItem[Int32]
Declaration
public override Single this[int slot] { get; }
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | slot |
Property Value
Type | Description |
---|---|
J2N.Numerics.Single |
Overrides
Lucene.Net.Search.FieldComparer<J2N.Numerics.Single>.Item[System.Int32]
Methods
| Improve this Doc View SourceCompare(Int32, Int32)
Declaration
public override int Compare(int slot1, int slot2)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | slot1 | |
System.Int32 | slot2 |
Returns
Type | Description |
---|---|
System.Int32 |
Overrides
Lucene.Net.Search.FieldComparer<J2N.Numerics.Single>.Compare(System.Int32, System.Int32)
|
Improve this Doc
View Source
CompareBottom(Int32)
Declaration
public override int CompareBottom(int doc)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | doc |
Returns
Type | Description |
---|---|
System.Int32 |
Overrides
Lucene.Net.Search.FieldComparer<J2N.Numerics.Single>.CompareBottom(System.Int32)
|
Improve this Doc
View Source
CompareTop(Int32)
Declaration
public override int CompareTop(int doc)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | doc |
Returns
Type | Description |
---|---|
System.Int32 |
Overrides
Lucene.Net.Search.FieldComparer<J2N.Numerics.Single>.CompareTop(System.Int32)
|
Improve this Doc
View Source
CompareValues(Single, Single)
Declaration
public override int CompareValues(Single first, Single second)
Parameters
Type | Name | Description |
---|---|---|
J2N.Numerics.Single | first | |
J2N.Numerics.Single | second |
Returns
Type | Description |
---|---|
System.Int32 |
Overrides
Lucene.Net.Search.FieldComparer<J2N.Numerics.Single>.CompareValues(J2N.Numerics.Single, J2N.Numerics.Single)
|
Improve this Doc
View Source
Copy(Int32, Int32)
Declaration
public override void Copy(int slot, int doc)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | slot | |
System.Int32 | doc |
Overrides
Lucene.Net.Search.FieldComparer<J2N.Numerics.Single>.Copy(System.Int32, System.Int32)
|
Improve this Doc
View Source
SetBottom(Int32)
Declaration
public override void SetBottom(int slot)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | slot |
Overrides
Lucene.Net.Search.FieldComparer<J2N.Numerics.Single>.SetBottom(System.Int32)
|
Improve this Doc
View Source
SetNextReader(AtomicReaderContext)
Declaration
public override FieldComparer SetNextReader(AtomicReaderContext context)
Parameters
Type | Name | Description |
---|---|---|
AtomicReaderContext | context |
Returns
Type | Description |
---|---|
FieldComparer |
Overrides
Lucene.Net.Search.FieldComparer<J2N.Numerics.Single>.SetNextReader(Lucene.Net.Index.AtomicReaderContext)
|
Improve this Doc
View Source
SetScorer(Scorer)
Declaration
public override void SetScorer(Scorer scorer)
Parameters
Type | Name | Description |
---|---|---|
Scorer | scorer |
Overrides
| Improve this Doc View SourceSetTopValue(Single)
Declaration
public override void SetTopValue(Single value)
Parameters
Type | Name | Description |
---|---|---|
J2N.Numerics.Single | value |
Overrides
Lucene.Net.Search.FieldComparer<J2N.Numerics.Single>.SetTopValue(J2N.Numerics.Single)