Class UpToTwoPositiveInt64Outputs
An FST Outputs<T> implementation where each output
is one or two non-negative long values. If it's a
System.Single output, System.Nullable<T> is
returned; else, TwoLongs. Order
is preserved in the TwoLongs case, ie .first is the first
input/output added to Builder<T>, and .second is the
second. You cannot store 0 output with this (that's
reserved to mean "no output")!
NOTE: the only way to create a TwoLongs output is to
add the same input to the FST twice in a row. This is
how the FST maps a single input to two outputs (e.g. you
cannot pass a UpToTwoPositiveInt64Outputs.TwoInt64s to Add(Int32sRef, T). If you
need more than two then use ListOfOutputs<T>, but if
you only have at most 2 then this implementation will
require fewer bytes as it steals one bit from each long
value.
NOTE: the resulting FST is not guaranteed to be minimal!
See Builder<T>.
NOTE: This was UpToTwoPositiveIntOutputs in Lucene - the data type (int) was wrong there - it should have been long
This is a Lucene.NET EXPERIMENTAL API, use at your own risk
Inheritance
System.Object
UpToTwoPositiveInt64Outputs
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()
Assembly: Lucene.Net.Misc.dll
Syntax
public sealed class UpToTwoPositiveInt64Outputs : Outputs<object>
Properties
|
Improve this Doc
View Source
NoOutput
Declaration
public override object NoOutput { get; }
Property Value
Type |
Description |
System.Object |
|
Overrides
Lucene.Net.Util.Fst.Outputs<System.Object>.NoOutput
Methods
|
Improve this Doc
View Source
Add(Object, Object)
Declaration
public override object Add(object prefix, object output)
Parameters
Type |
Name |
Description |
System.Object |
prefix |
|
System.Object |
output |
|
Returns
Type |
Description |
System.Object |
|
Overrides
Lucene.Net.Util.Fst.Outputs<System.Object>.Add(System.Object, System.Object)
|
Improve this Doc
View Source
Common(Object, Object)
Declaration
public override object Common(object output1, object output2)
Parameters
Type |
Name |
Description |
System.Object |
output1 |
|
System.Object |
output2 |
|
Returns
Type |
Description |
System.Object |
|
Overrides
Lucene.Net.Util.Fst.Outputs<System.Object>.Common(System.Object, System.Object)
|
Improve this Doc
View Source
Get(Int64)
Declaration
Parameters
Type |
Name |
Description |
System.Int64 |
v |
|
Returns
Type |
Description |
System.Nullable<System.Int64> |
|
|
Improve this Doc
View Source
Get(Int64, Int64)
Declaration
public UpToTwoPositiveInt64Outputs.TwoInt64s Get(long first, long second)
Parameters
Type |
Name |
Description |
System.Int64 |
first |
|
System.Int64 |
second |
|
Returns
|
Improve this Doc
View Source
GetSingleton(Boolean)
Declaration
public static UpToTwoPositiveInt64Outputs GetSingleton(bool doShare)
Parameters
Type |
Name |
Description |
System.Boolean |
doShare |
|
Returns
|
Improve this Doc
View Source
Merge(Object, Object)
Declaration
public override object Merge(object first, object second)
Parameters
Type |
Name |
Description |
System.Object |
first |
|
System.Object |
second |
|
Returns
Type |
Description |
System.Object |
|
Overrides
Lucene.Net.Util.Fst.Outputs<System.Object>.Merge(System.Object, System.Object)
|
Improve this Doc
View Source
OutputToString(Object)
Declaration
public override string OutputToString(object output)
Parameters
Type |
Name |
Description |
System.Object |
output |
|
Returns
Type |
Description |
System.String |
|
Overrides
Lucene.Net.Util.Fst.Outputs<System.Object>.OutputToString(System.Object)
|
Improve this Doc
View Source
Declaration
public override object Read(DataInput in)
Parameters
Returns
Type |
Description |
System.Object |
|
Overrides
Lucene.Net.Util.Fst.Outputs<System.Object>.Read(Lucene.Net.Store.DataInput)
|
Improve this Doc
View Source
Subtract(Object, Object)
Declaration
public override object Subtract(object output, object inc)
Parameters
Type |
Name |
Description |
System.Object |
output |
|
System.Object |
inc |
|
Returns
Type |
Description |
System.Object |
|
Overrides
Lucene.Net.Util.Fst.Outputs<System.Object>.Subtract(System.Object, System.Object)
|
Improve this Doc
View Source
Write(Object, DataOutput)
Declaration
public override void Write(object output, DataOutput out)
Parameters
Type |
Name |
Description |
System.Object |
output |
|
DataOutput |
out |
|
Overrides
Lucene.Net.Util.Fst.Outputs<System.Object>.Write(System.Object, Lucene.Net.Store.DataOutput)