Documentation
¶
Index ¶
- type Commitments
- func (c *Commitments) Close() (err error)
- func (c *Commitments) Export(writer io.WriteSeeker, targetSlot slot.Index) (err error)
- func (c *Commitments) FilePath() (filePath string)
- func (c *Commitments) Import(reader io.ReadSeeker) (err error)
- func (c *Commitments) Load(index slot.Index) (commitment *commitment.Commitment, err error)
- func (c *Commitments) Store(commitment *commitment.Commitment) (err error)
- type Permanent
- func (p *Permanent) Attestations(optRealm ...byte) kvstore.KVStore
- func (p *Permanent) SettingsAndCommitmentsSize() int64
- func (p *Permanent) SybilProtection(optRealm ...byte) kvstore.KVStore
- func (p *Permanent) ThroughputQuota(optRealm ...byte) kvstore.KVStore
- func (p *Permanent) UnspentOutputIDs(optRealm ...byte) kvstore.KVStore
- type Settings
- func (s Settings) Bytes() ([]byte, error)
- func (s *Settings) ChainID() commitment.ID
- func (s *Settings) Export(writer io.WriteSeeker) (err error)
- func (s Settings) FromBytes(bytes []byte) (int, error)
- func (s *Settings) GenesisUnixTime() int64
- func (s *Settings) Import(reader io.ReadSeeker) (err error)
- func (s *Settings) LatestCommitment() (latestCommitment *commitment.Commitment)
- func (s *Settings) LatestConfirmedSlot() slot.Index
- func (s *Settings) LatestStateMutationSlot() slot.Index
- func (s *Settings) SetChainID(id commitment.ID) (err error)
- func (s *Settings) SetGenesisUnixTime(unixTime int64) (err error)
- func (s *Settings) SetLatestCommitment(latestCommitment *commitment.Commitment) (err error)
- func (s *Settings) SetLatestConfirmedSlot(latestConfirmedSlot slot.Index) (err error)
- func (s *Settings) SetLatestStateMutationSlot(latestStateMutationSlot slot.Index) (err error)
- func (s *Settings) SetSlotDuration(duration int64) (err error)
- func (s *Settings) SetSnapshotImported(initialized bool) (err error)
- func (s *Settings) SlotDuration() int64
- func (s *Settings) SlotTimeProvider() *slot.TimeProvider
- func (s *Settings) SnapshotImported() (initialized bool)
- func (s *Settings) String() string
- func (s *Settings) UpdateSlotTimeProvider()
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Commitments ¶
func NewCommitments ¶
func NewCommitments(path string) (newCommitment *Commitments)
func (*Commitments) Close ¶
func (c *Commitments) Close() (err error)
func (*Commitments) Export ¶
func (c *Commitments) Export(writer io.WriteSeeker, targetSlot slot.Index) (err error)
func (*Commitments) FilePath ¶
func (c *Commitments) FilePath() (filePath string)
FilePath returns the path that this is associated to.
func (*Commitments) Import ¶
func (c *Commitments) Import(reader io.ReadSeeker) (err error)
func (*Commitments) Load ¶
func (c *Commitments) Load(index slot.Index) (commitment *commitment.Commitment, err error)
func (*Commitments) Store ¶
func (c *Commitments) Store(commitment *commitment.Commitment) (err error)
type Permanent ¶
type Permanent struct {
Settings *Settings
Commitments *Commitments
UnspentOutputs kvstore.KVStore
// contains filtered or unexported fields
}
func (*Permanent) Attestations ¶
Attestations returns the "attestations" storage (or a specialized sub-storage if a realm is provided).
func (*Permanent) SettingsAndCommitmentsSize ¶
SettingsAndCommitmentsSize returns the total size of the binary files.
func (*Permanent) SybilProtection ¶
SybilProtection returns the sybil protection storage (or a specialized sub-storage if a realm is provided).
func (*Permanent) ThroughputQuota ¶
ThroughputQuota returns the throughput quota storage (or a specialized sub-storage if a realm is provided).
type Settings ¶
func NewSettings ¶
func (*Settings) ChainID ¶
func (s *Settings) ChainID() commitment.ID
func (*Settings) GenesisUnixTime ¶
func (*Settings) LatestCommitment ¶
func (s *Settings) LatestCommitment() (latestCommitment *commitment.Commitment)
func (*Settings) LatestConfirmedSlot ¶
func (*Settings) LatestStateMutationSlot ¶
func (*Settings) SetChainID ¶
func (s *Settings) SetChainID(id commitment.ID) (err error)
func (*Settings) SetGenesisUnixTime ¶
func (*Settings) SetLatestCommitment ¶
func (s *Settings) SetLatestCommitment(latestCommitment *commitment.Commitment) (err error)
func (*Settings) SetLatestConfirmedSlot ¶
func (*Settings) SetLatestStateMutationSlot ¶
func (*Settings) SetSlotDuration ¶
func (*Settings) SetSnapshotImported ¶
func (*Settings) SlotDuration ¶
func (*Settings) SlotTimeProvider ¶
func (s *Settings) SlotTimeProvider() *slot.TimeProvider
func (*Settings) SnapshotImported ¶
func (*Settings) UpdateSlotTimeProvider ¶
func (s *Settings) UpdateSlotTimeProvider()
Click to show internal directories.
Click to hide internal directories.