Documentation
¶
Index ¶
- Variables
- func CheckAvailableRAM()
- func TestBlockNeiExistance_Helper(bc chainreadinterface.IBlockChain, neiName string, neiExpectedExistance bool, ...)
- func TestCopyOfJsonRealChain_Helper(bc chainreadinterface.IBlockChain, t *testing.T)
- func TestCopyOfTinyChain_Helper(bc chainreadinterface.IBlockChain, t *testing.T)
- func TestTransactionNeiExistance_Helper(bc chainreadinterface.IBlockChain, neiName string, neiExpectedExistance bool, ...)
- type Address
- type AddressHandle
- type Block
- func (block *Block) Hash() (indexedhashes.Sha256, error)
- func (block *Block) HashSpecified() bool
- func (block *Block) Height() int64
- func (block *Block) HeightSpecified() bool
- func (block *Block) IsBlockHandle()
- func (block *Block) IsInvalid() bool
- func (block *Block) NonEssentialInts() (*map[string]int64, error)
- func (block *Block) NthTransaction(n int64) (chainreadinterface.ITransHandle, error)
- func (block *Block) TransactionCount() (int64, error)
- type BlockHandle
- type ConcreteAppendableChainCreator
- func (cacc *ConcreteAppendableChainCreator) Create() error
- func (cacc *ConcreteAppendableChainCreator) CreateFromHashStores() error
- func (cacc *ConcreteAppendableChainCreator) Exists() bool
- func (cacc *ConcreteAppendableChainCreator) Open() (IAppendableChain, error)
- func (cacc *ConcreteAppendableChainCreator) OpenReadOnly() (chainreadinterface.IBlockChain, chainreadinterface.IHandleCreator, IParents, ...)
- func (cacc *ConcreteAppendableChainCreator) OpenWithIndexer() (IAppendableChain, transactionindexing.ITransactionIndexer, error)
- type ConcreteHashesChainCreator
- type HashHeight
- type IAppendableChain
- type IAppendableChainFactory
- type IAppendableChainFactoryWithIndexer
- type IAppendableHashesChain
- type IAppendableHashesChainFactory
- type IParents
- type IPrivilegedFiles
- type TransHandle
- func (th *TransHandle) Hash() (indexedhashes.Sha256, error)
- func (th *TransHandle) HashSpecified() bool
- func (th *TransHandle) Height() int64
- func (th *TransHandle) HeightSpecified() bool
- func (th *TransHandle) IndicesPath() (int64, int64)
- func (th *TransHandle) IndicesPathSpecified() bool
- func (th *TransHandle) IsInvalid() bool
- func (th *TransHandle) IsTransHandle()
- type TransIndex
- type Transaction
- func (tr *Transaction) AllTxoSatoshis() ([]int64, error)
- func (tr *Transaction) Hash() (indexedhashes.Sha256, error)
- func (tr *Transaction) HashSpecified() bool
- func (tr *Transaction) Height() int64
- func (tr *Transaction) HeightSpecified() bool
- func (th *Transaction) IndicesPath() (int64, int64)
- func (th *Transaction) IndicesPathSpecified() bool
- func (tr *Transaction) IsInvalid() bool
- func (tr *Transaction) IsTransHandle()
- func (tr *Transaction) NonEssentialInts() (*map[string]int64, error)
- func (tr *Transaction) NthTxi(n int64) (chainreadinterface.ITxiHandle, error)
- func (tr *Transaction) NthTxo(n int64) (chainreadinterface.ITxoHandle, error)
- func (tr *Transaction) TxiCount() (int64, error)
- func (tr *Transaction) TxoCount() (int64, error)
- type Txi
- func (txi *Txi) IndicesPath() (int64, int64, int64)
- func (txi *Txi) IndicesPathSpecified() bool
- func (txi *Txi) ParentIndex() int64
- func (txi *Txi) ParentSpecified() bool
- func (txi *Txi) ParentTrans() chainreadinterface.ITransHandle
- func (txi *Txi) SourceTxo() (chainreadinterface.ITxoHandle, error)
- func (txi *Txi) TxiHeight() int64
- func (txi *Txi) TxiHeightSpecified() bool
- type TxiHandle
- func (txi *TxiHandle) IndicesPath() (int64, int64, int64)
- func (txi *TxiHandle) IndicesPathSpecified() bool
- func (txi *TxiHandle) ParentIndex() int64
- func (txi *TxiHandle) ParentSpecified() bool
- func (txi *TxiHandle) ParentTrans() chainreadinterface.ITransHandle
- func (txi *TxiHandle) TxiHeight() int64
- func (txi *TxiHandle) TxiHeightSpecified() bool
- type Txo
- func (txo *Txo) Address() (chainreadinterface.IAddressHandle, error)
- func (txo *Txo) IndicesPath() (int64, int64, int64)
- func (txo *Txo) IndicesPathSpecified() bool
- func (txo *Txo) ParentIndex() int64
- func (txo *Txo) ParentSpecified() bool
- func (txo *Txo) ParentTrans() chainreadinterface.ITransHandle
- func (txo *Txo) Satoshis() (int64, error)
- func (txo *Txo) TxoHeight() int64
- func (txo *Txo) TxoHeightSpecified() bool
- type TxoHandle
- func (txo *TxoHandle) IndicesPath() (int64, int64, int64)
- func (txo *TxoHandle) IndicesPathSpecified() bool
- func (txo *TxoHandle) ParentIndex() int64
- func (txo *TxoHandle) ParentSpecified() bool
- func (txo *TxoHandle) ParentTrans() chainreadinterface.ITransHandle
- func (txo *TxoHandle) TxoHeight() int64
- func (txo *TxoHandle) TxoHeightSpecified() bool
- type TxxHandle
Constants ¶
This section is empty.
Variables ¶
View Source
var PrevFirstTxo int64
View Source
var PrevTrans int64
Functions ¶
func CheckAvailableRAM ¶ added in v0.0.25
func CheckAvailableRAM()
func TestBlockNeiExistance_Helper ¶
func TestBlockNeiExistance_Helper(bc chainreadinterface.IBlockChain, neiName string, neiExpectedExistance bool, t *testing.T)
func TestCopyOfJsonRealChain_Helper ¶
func TestCopyOfJsonRealChain_Helper(bc chainreadinterface.IBlockChain, t *testing.T)
func TestCopyOfTinyChain_Helper ¶
func TestCopyOfTinyChain_Helper(bc chainreadinterface.IBlockChain, t *testing.T)
func TestTransactionNeiExistance_Helper ¶
func TestTransactionNeiExistance_Helper(bc chainreadinterface.IBlockChain, neiName string, neiExpectedExistance bool, t *testing.T)
Types ¶
type Address ¶
type Address struct {
// contains filtered or unexported fields
}
Address implements IAddress
func (*Address) Hash ¶ added in v0.0.18
func (adr *Address) Hash() indexedhashes.Sha256
func (*Address) HashSpecified ¶ added in v0.0.18
func (*Address) HeightSpecified ¶ added in v0.0.18
func (*Address) NthTxo ¶
func (adr *Address) NthTxo(n int64) (chainreadinterface.ITxoHandle, error)
type AddressHandle ¶
type AddressHandle struct {
HashHeight
}
AddressHandle implements IAddressHandle
func (*AddressHandle) Hash ¶
func (ah *AddressHandle) Hash() indexedhashes.Sha256
func (*AddressHandle) HashSpecified ¶
func (ah *AddressHandle) HashSpecified() bool
func (*AddressHandle) Height ¶
func (ah *AddressHandle) Height() int64
func (*AddressHandle) HeightSpecified ¶
func (ah *AddressHandle) HeightSpecified() bool
type Block ¶
type Block struct {
// contains filtered or unexported fields
}
func (*Block) HashSpecified ¶
func (*Block) HeightSpecified ¶
func (*Block) IsBlockHandle ¶
func (block *Block) IsBlockHandle()
func (*Block) NthTransaction ¶
func (block *Block) NthTransaction(n int64) (chainreadinterface.ITransHandle, error)
func (*Block) TransactionCount ¶
type BlockHandle ¶
type BlockHandle struct {
HashHeight
// contains filtered or unexported fields
}
BlockHandle in package chainstorage implements IBlockHandle
func (*BlockHandle) Hash ¶
func (bh *BlockHandle) Hash() (indexedhashes.Sha256, error)
func (*BlockHandle) HashSpecified ¶
func (bh *BlockHandle) HashSpecified() bool
func (*BlockHandle) Height ¶
func (bh *BlockHandle) Height() int64
func (*BlockHandle) HeightSpecified ¶
func (bh *BlockHandle) HeightSpecified() bool
func (*BlockHandle) IsBlockHandle ¶
func (bh *BlockHandle) IsBlockHandle()
func (*BlockHandle) IsInvalid ¶
func (bh *BlockHandle) IsInvalid() bool
type ConcreteAppendableChainCreator ¶
type ConcreteAppendableChainCreator struct {
// contains filtered or unexported fields
}
func (*ConcreteAppendableChainCreator) Create ¶
func (cacc *ConcreteAppendableChainCreator) Create() error
func (*ConcreteAppendableChainCreator) CreateFromHashStores ¶ added in v0.0.12
func (cacc *ConcreteAppendableChainCreator) CreateFromHashStores() error
func (*ConcreteAppendableChainCreator) Exists ¶
func (cacc *ConcreteAppendableChainCreator) Exists() bool
func (*ConcreteAppendableChainCreator) Open ¶
func (cacc *ConcreteAppendableChainCreator) Open() (IAppendableChain, error)
func (*ConcreteAppendableChainCreator) OpenReadOnly ¶
func (cacc *ConcreteAppendableChainCreator) OpenReadOnly() (chainreadinterface.IBlockChain, chainreadinterface.IHandleCreator, IParents, IPrivilegedFiles, error)
func (*ConcreteAppendableChainCreator) OpenWithIndexer ¶
func (cacc *ConcreteAppendableChainCreator) OpenWithIndexer() (IAppendableChain, transactionindexing.ITransactionIndexer, error)
type ConcreteHashesChainCreator ¶ added in v0.0.12
type ConcreteHashesChainCreator struct {
// contains filtered or unexported fields
}
func NewConcreteHashesChainCreator ¶ added in v0.0.12
func NewConcreteHashesChainCreator(folder string) *ConcreteHashesChainCreator
func (*ConcreteHashesChainCreator) Create ¶ added in v0.0.12
func (chcc *ConcreteHashesChainCreator) Create() error
func (*ConcreteHashesChainCreator) Exists ¶ added in v0.0.12
func (chcc *ConcreteHashesChainCreator) Exists() bool
func (*ConcreteHashesChainCreator) Open ¶ added in v0.0.12
func (chcc *ConcreteHashesChainCreator) Open() (IAppendableHashesChain, error)
type HashHeight ¶
type HashHeight struct {
// contains filtered or unexported fields
}
HashHeight in package chainstorage
type IAppendableChain ¶
type IAppendableChain interface {
AppendBlock(chainreadinterface.IBlockChain, chainreadinterface.IBlockHandle) error
Close()
Sync() error
GetAsChainReadInterface() chainreadinterface.IBlockChain
SelfTestTransHashes() error
}
type IAppendableChainFactory ¶
type IAppendableChainFactory interface {
Exists() bool
Create() error
CreateFromHashStores() error
Open() (IAppendableChain, error)
OpenReadOnly() (chainreadinterface.IBlockChain, chainreadinterface.IHandleCreator, IParents, IPrivilegedFiles, error)
}
type IAppendableChainFactoryWithIndexer ¶
type IAppendableChainFactoryWithIndexer interface {
IAppendableChainFactory
OpenWithIndexer() (IAppendableChain, transactionindexing.ITransactionIndexer, error)
}
type IAppendableHashesChain ¶ added in v0.0.12
type IAppendableHashesChain interface {
AppendHashes(hashes *jsonblock.JsonBlockHashes) error
Close()
Sync() error
CountHashes() (int64, int64, int64, error)
}
Just stores hashes (block, transaction, address) associated with each appended block
type IAppendableHashesChainFactory ¶ added in v0.0.12
type IAppendableHashesChainFactory interface {
Exists() bool
Create() error
Open() (IAppendableHashesChain, error)
}
type IPrivilegedFiles ¶ added in v0.0.7
type IPrivilegedFiles interface {
TxoSatsFile() wordfile.ReadAtWordCounter
TxiTxFile() wordfile.ReadAtWordCounter
TxiVoutFile() wordfile.ReadAtWordCounter
TransFirstTxiFile() wordfile.ReadAtWordCounter
TransFirstTxoFile() wordfile.ReadAtWordCounter
}
IPrivilegedFiles give access to certain files by a privileged program (pudding-server)
type TransHandle ¶
type TransHandle struct {
HashHeight
// contains filtered or unexported fields
}
TransHandle in package chainstorage implements ITransHandle
func (*TransHandle) Hash ¶
func (th *TransHandle) Hash() (indexedhashes.Sha256, error)
func (*TransHandle) HashSpecified ¶
func (th *TransHandle) HashSpecified() bool
func (*TransHandle) Height ¶
func (th *TransHandle) Height() int64
func (*TransHandle) HeightSpecified ¶
func (th *TransHandle) HeightSpecified() bool
func (*TransHandle) IndicesPath ¶
func (th *TransHandle) IndicesPath() (int64, int64)
func (*TransHandle) IndicesPathSpecified ¶
func (th *TransHandle) IndicesPathSpecified() bool
func (*TransHandle) IsInvalid ¶
func (th *TransHandle) IsInvalid() bool
func (*TransHandle) IsTransHandle ¶
func (th *TransHandle) IsTransHandle()
type TransIndex ¶
type TransIndex struct {
TransHandle
// contains filtered or unexported fields
}
TransIndex in package chainstorage
type Transaction ¶
type Transaction struct {
// contains filtered or unexported fields
}
Transaction implements ITransaction
func (*Transaction) AllTxoSatoshis ¶ added in v0.0.26
func (tr *Transaction) AllTxoSatoshis() ([]int64, error)
func (*Transaction) Hash ¶
func (tr *Transaction) Hash() (indexedhashes.Sha256, error)
func (*Transaction) HashSpecified ¶
func (tr *Transaction) HashSpecified() bool
func (*Transaction) Height ¶
func (tr *Transaction) Height() int64
func (*Transaction) HeightSpecified ¶
func (tr *Transaction) HeightSpecified() bool
func (*Transaction) IndicesPath ¶
func (th *Transaction) IndicesPath() (int64, int64)
func (*Transaction) IndicesPathSpecified ¶
func (th *Transaction) IndicesPathSpecified() bool
func (*Transaction) IsInvalid ¶
func (tr *Transaction) IsInvalid() bool
func (*Transaction) IsTransHandle ¶
func (tr *Transaction) IsTransHandle()
func (*Transaction) NonEssentialInts ¶
func (tr *Transaction) NonEssentialInts() (*map[string]int64, error)
func (*Transaction) NthTxi ¶
func (tr *Transaction) NthTxi(n int64) (chainreadinterface.ITxiHandle, error)
func (*Transaction) NthTxo ¶
func (tr *Transaction) NthTxo(n int64) (chainreadinterface.ITxoHandle, error)
func (*Transaction) TxiCount ¶
func (tr *Transaction) TxiCount() (int64, error)
func (*Transaction) TxoCount ¶
func (tr *Transaction) TxoCount() (int64, error)
type Txi ¶
type Txi struct {
// contains filtered or unexported fields
}
Txi implements ITxi
func (*Txi) IndicesPathSpecified ¶
func (*Txi) ParentIndex ¶
func (*Txi) ParentSpecified ¶
func (*Txi) ParentTrans ¶
func (txi *Txi) ParentTrans() chainreadinterface.ITransHandle
func (*Txi) SourceTxo ¶
func (txi *Txi) SourceTxo() (chainreadinterface.ITxoHandle, error)
func (*Txi) TxiHeightSpecified ¶
type TxiHandle ¶
type TxiHandle struct {
TxxHandle
}
TxiHandle in package chainstorage implements ITxiHandle
func (*TxiHandle) IndicesPathSpecified ¶
func (*TxiHandle) ParentIndex ¶
func (*TxiHandle) ParentSpecified ¶
func (*TxiHandle) ParentTrans ¶
func (txi *TxiHandle) ParentTrans() chainreadinterface.ITransHandle
func (*TxiHandle) TxiHeightSpecified ¶
type Txo ¶
type Txo struct {
// contains filtered or unexported fields
}
Txo implements ITxo
func (*Txo) Address ¶
func (txo *Txo) Address() (chainreadinterface.IAddressHandle, error)
func (*Txo) IndicesPathSpecified ¶
func (*Txo) ParentIndex ¶
func (*Txo) ParentSpecified ¶
func (*Txo) ParentTrans ¶
func (txo *Txo) ParentTrans() chainreadinterface.ITransHandle
func (*Txo) TxoHeightSpecified ¶
type TxoHandle ¶
type TxoHandle struct {
TxxHandle
}
TxoHandle implements ITxoHandle
func (*TxoHandle) IndicesPathSpecified ¶
func (*TxoHandle) ParentIndex ¶
func (*TxoHandle) ParentSpecified ¶
func (*TxoHandle) ParentTrans ¶
func (txo *TxoHandle) ParentTrans() chainreadinterface.ITransHandle
func (*TxoHandle) TxoHeightSpecified ¶
type TxxHandle ¶
type TxxHandle struct {
TransIndex
// contains filtered or unexported fields
}
TxxHandle in package chainstorage
Click to show internal directories.
Click to hide internal directories.