IBlockIndexOrder

Description

interface Tinman.Core.Database.IBlockIndexOrder
<TKey>
<TValue in>

Base interface for classes that provide index semantic for a BlockIndex.

The value ordering of the block index is defined by the method ValueCompare. Keys are extracted from values via ValueToKey.

Public / Methods

ValueCompare


public method ValueCompare → (2)

key in : TKey

The key.

value in : TValue

The value.

returns → int32

-1 if key in is less than value in, 1 if key in is greater than value in and 0 if key in is equal to value in.

Compares the given key to the specified value.

ValueToKey


public method ValueToKey → (1)

value in : TValue

The entry value.

returns → TKey

The entry key.

Returns the key for the given value.

This is a generic method; it operates independently from the current index content.