Documentation
¶
Index ¶
- Constants
- func BlockFromCadence(val cadence.Value) (*model.Block, error)
- func BlockRecordsFromCadence(val cadence.Value) ([][]string, error)
- func CreateLedgerConnector(ctx context.Context, params ledger.Parameters, ns notification.Service, ...) (model.Ledger, error)
- func InstallLedgerSchema(bc *utils.BoltClient) error
- func NewInMemoryConnectorEmbedded(enableTxFees bool) (*splash.Connector, error)
- func NewNetworkConnectorEmbedded(network string) (*splash.Connector, error)
- func NewTemplateEngine(client *splash.Connector) (*splash.TemplateEngine, error)
- func RecordFromCadence(val cadence.Value) (*model.Record, error)
- func RecordToCadence(rec *model.Record, contractAddr flow.Address) cadence.Value
- type Ledger
- func (l *Ledger) Close() error
- func (l *Ledger) GetAssetHead(ctx context.Context, headID string) (*model.Record, error)
- func (l *Ledger) GetBlock(ctx context.Context, bn uint64) (*model.Block, error)
- func (l *Ledger) GetBlockRecords(ctx context.Context, bn uint64) ([][]string, error)
- func (l *Ledger) GetChain(ctx context.Context, startNumber uint64, depth int) ([]*model.Block, error)
- func (l *Ledger) GetDataAssetState(ctx context.Context, id string) (model.DataAssetState, error)
- func (l *Ledger) GetGenesisBlock(ctx context.Context) (*model.Block, error)
- func (l *Ledger) GetRecord(ctx context.Context, rid string) (*model.Record, error)
- func (l *Ledger) GetRecordState(ctx context.Context, rid string) (*model.RecordState, error)
- func (l *Ledger) GetTopBlock(ctx context.Context) (*model.Block, error)
- func (l *Ledger) ImportBlock(ctx context.Context, blockNumber uint64, records []*model.Record) error
- func (l *Ledger) StartLedgerEvents(ctx context.Context, syncOnStart bool, syncInterval time.Duration) error
- func (l *Ledger) StopContinuousSync()
- func (l *Ledger) SubmitRecord(ctx context.Context, r *model.Record) error
- func (l *Ledger) Sync(ctx context.Context) error
Constants ¶
View Source
const ( BlocksKey = "blocks" BlockRecordsKey = "block_records" RecordsKey = "records" ControlsKey = "controls" GenesisBlockHeightKey = "genesis_block_height" TopFlowBlockHeightKey = "top_flow_block_height" TopBlockNumberKey = "top_block_number" )
Variables ¶
This section is empty.
Functions ¶
func CreateLedgerConnector ¶
func CreateLedgerConnector(ctx context.Context, params ledger.Parameters, ns notification.Service, resolver cmdbase.ParameterResolver) (model.Ledger, error)
func InstallLedgerSchema ¶
func InstallLedgerSchema(bc *utils.BoltClient) error
func NewInMemoryConnectorEmbedded ¶
NewInMemoryConnectorEmbedded creates a new Splash Connector for in-memory emulator that uses embedded Flow configuration.
func NewNetworkConnectorEmbedded ¶
NewNetworkConnectorEmbedded creates a new Splash Connector that uses embedded Flow configuration.
func NewTemplateEngine ¶
func NewTemplateEngine(client *splash.Connector) (*splash.TemplateEngine, error)
Types ¶
type Ledger ¶
type Ledger struct {
// contains filtered or unexported fields
}
func (*Ledger) GetAssetHead ¶
func (*Ledger) GetBlockRecords ¶
func (*Ledger) GetDataAssetState ¶
func (*Ledger) GetGenesisBlock ¶
func (*Ledger) GetRecordState ¶
func (*Ledger) GetTopBlock ¶
func (*Ledger) ImportBlock ¶
func (*Ledger) StartLedgerEvents ¶
func (*Ledger) StopContinuousSync ¶
func (l *Ledger) StopContinuousSync()
func (*Ledger) SubmitRecord ¶
Click to show internal directories.
Click to hide internal directories.