Documentation ¶
Index ¶
- Constants
- func New(data []byte) (module.GenesisStorage, error)
- func NewDatabaseWithStorage(s module.GenesisStorage) db.Database
- func NewDatabaseWithWriter(w module.GenesisStorageWriter) db.Database
- func NewFromFile(fd *os.File) (module.GenesisStorage, error)
- func NewFromTx(tx []byte) module.GenesisStorage
- func NewGenesisStorageWriter(w io.Writer) module.GenesisStorageWriter
- func WriteFromPath(w io.Writer, p string) error
- type PrunedGenesis
Constants ¶
View Source
const (
GenesisChunkSize = 1024 * 10
)
View Source
const (
GenesisFileName = "genesis.json"
)
Variables ¶
This section is empty.
Functions ¶
func NewDatabaseWithStorage ¶
func NewDatabaseWithStorage(s module.GenesisStorage) db.Database
func NewDatabaseWithWriter ¶
func NewDatabaseWithWriter(w module.GenesisStorageWriter) db.Database
func NewFromFile ¶
func NewFromFile(fd *os.File) (module.GenesisStorage, error)
func NewFromTx ¶
func NewFromTx(tx []byte) module.GenesisStorage
func NewGenesisStorageWriter ¶
func NewGenesisStorageWriter(w io.Writer) module.GenesisStorageWriter
Types ¶
type PrunedGenesis ¶
type PrunedGenesis struct { CID common.HexInt32 `json:"cid"` NID common.HexInt32 `json:"nid"` Height common.HexInt64 `json:"height"` Block common.HexBytes `json:"block"` Votes common.HexBytes `json:"votes"` }
func NewPrunedGenesis ¶ added in v1.2.11
func NewPrunedGenesis(js []byte) (*PrunedGenesis, error)
func (*PrunedGenesis) Verify ¶
func (g *PrunedGenesis) Verify() error
Click to show internal directories.
Click to hide internal directories.