C# Class BitSharp.Esent.EsentBlockTxesStorage

Inheritance: IBlockTxesStorage
Show file Open project: pmlyon/BitSharp

Private Properties

Property Type Description
AddBlockIndex int
AddTransaction void
CreateDatabase void
CreateOrOpenDatabase void
DeleteBlockIndex void
DeleteDatabase void
OpenDatabase void
ReadBlockTransactions IEnumerator
TryGetBlockIndex bool

Public Methods

Method Description
ContainsBlock ( UInt256 blockHash ) : bool
Defragment ( ) : void
DeleteElements ( IEnumerable blockTxIndices ) : void
Dispose ( ) : void
EsentBlockTxesStorage ( string baseDirectory, int index = null ) : BitSharp.Common
Flush ( ) : void
PruneElements ( IEnumerable blockTxIndices ) : void
TryAddBlockTransactions ( UInt256 blockHash, IEnumerable blockTxes ) : bool
TryGetTransaction ( UInt256 blockHash, int txIndex, BlockTx &transaction ) : bool
TryReadBlockTransactions ( UInt256 blockHash, IEnumerator &blockTxes ) : bool
TryReadBlockTxNodes ( UInt256 blockHash, IEnumerator &blockTxNodes ) : bool
TryRemoveBlockTransactions ( UInt256 blockHash ) : bool

Protected Methods

Method Description
Dispose ( bool disposing ) : void

Private Methods

Method Description
AddBlockIndex ( BitSharp.Esent.EsentBlockTxesCursor cursor, UInt256 blockHash ) : int
AddTransaction ( int blockIndex, int txIndex, UInt256 txHash, byte txBytes, BitSharp.Esent.EsentBlockTxesCursor cursor ) : void
CreateDatabase ( ) : void
CreateOrOpenDatabase ( ) : void
DeleteBlockIndex ( BitSharp.Esent.EsentBlockTxesCursor cursor, UInt256 blockHash ) : void
DeleteDatabase ( ) : void
OpenDatabase ( ) : void
ReadBlockTransactions ( UInt256 blockHash, bool requireTx ) : IEnumerator
TryGetBlockIndex ( BitSharp.Esent.EsentBlockTxesCursor cursor, UInt256 blockHash, int &blockIndex ) : bool

Method Details

ContainsBlock() public method

public ContainsBlock ( UInt256 blockHash ) : bool
blockHash UInt256
return bool

Defragment() public method

public Defragment ( ) : void
return void

DeleteElements() public method

public DeleteElements ( IEnumerable blockTxIndices ) : void
blockTxIndices IEnumerable
return void

Dispose() public method

public Dispose ( ) : void
return void

Dispose() protected method

protected Dispose ( bool disposing ) : void
disposing bool
return void

EsentBlockTxesStorage() public method

public EsentBlockTxesStorage ( string baseDirectory, int index = null ) : BitSharp.Common
baseDirectory string
index int
return BitSharp.Common

Flush() public method

public Flush ( ) : void
return void

PruneElements() public method

public PruneElements ( IEnumerable blockTxIndices ) : void
blockTxIndices IEnumerable
return void

TryAddBlockTransactions() public method

public TryAddBlockTransactions ( UInt256 blockHash, IEnumerable blockTxes ) : bool
blockHash UInt256
blockTxes IEnumerable
return bool

TryGetTransaction() public method

public TryGetTransaction ( UInt256 blockHash, int txIndex, BlockTx &transaction ) : bool
blockHash UInt256
txIndex int
transaction BitSharp.Core.Domain.BlockTx
return bool

TryReadBlockTransactions() public method

public TryReadBlockTransactions ( UInt256 blockHash, IEnumerator &blockTxes ) : bool
blockHash UInt256
blockTxes IEnumerator
return bool

TryReadBlockTxNodes() public method

public TryReadBlockTxNodes ( UInt256 blockHash, IEnumerator &blockTxNodes ) : bool
blockHash UInt256
blockTxNodes IEnumerator
return bool

TryRemoveBlockTransactions() public method

public TryRemoveBlockTransactions ( UInt256 blockHash ) : bool
blockHash UInt256
return bool