Versions in this module Expand all Collapse all v1 v1.0.1 Feb 24, 2023 Changes in this version + const GasPowerConfigs + const LongTermGas + const ShortTermGas + const SigSize + var EmptyTxHash = hash.Hash(types.DeriveSha(types.Transactions{}, new(trie.Trie))) + var ErrSerMalformedEvent = errors.New("serialization of malformed event") + var ErrUnknownTxType = errors.New("unknown tx type") + func FilterSkippedTxs(txs types.Transactions, skippedTxs []uint32) types.Transactions + func TransactionMarshalCSER(w *cser.Writer, tx *types.Transaction) error + func TransactionUnmarshalCSER(r *cser.Reader) (*types.Transaction, error) + type Block struct + Atropos hash.Event + Events hash.Events + GasUsed uint64 + InternalTxs []common.Hash + Root hash.Hash + SkippedTxs []uint32 + Time Timestamp + Txs []common.Hash + func (b *Block) EstimateSize() int + func (b *Block) NotSkippedTxs() []common.Hash + type Event struct + func (e *Event) CreationTime() Timestamp + func (e *Event) Extra() []byte + func (e *Event) GasPowerLeft() GasPowerLeft + func (e *Event) GasPowerUsed() uint64 + func (e *Event) HashToSign() hash.Hash + func (e *Event) MarshalBinary() ([]byte, error) + func (e *Event) MarshalCSER(w *cser.Writer) error + func (e *Event) MedianTime() Timestamp + func (e *Event) NoTxs() bool + func (e *Event) PrevEpochHash() *hash.Hash + func (e *Event) TxHash() hash.Hash + type EventI interface + CreationTime func() Timestamp + Extra func() []byte + GasPowerLeft func() GasPowerLeft + GasPowerUsed func() uint64 + HashToSign func() hash.Hash + MedianTime func() Timestamp + NoTxs func() bool + PrevEpochHash func() *hash.Hash + TxHash func() hash.Hash + type EventIs []EventI + func (ee *EventIs) Add(e ...EventI) + func (ee EventIs) Bases() dag.Events + func (ee EventIs) IDs() hash.Events + func (ee EventIs) String() string + func (hh EventIs) Len() int + func (hh EventIs) Less(i, j int) bool + func (hh EventIs) Swap(i, j int) + type EventPayload struct + func (e *EventPayload) CreationTime() Timestamp + func (e *EventPayload) DecodeRLP(src *rlp.Stream) error + func (e *EventPayload) EncodeRLP(w io.Writer) error + func (e *EventPayload) Extra() []byte + func (e *EventPayload) GasPowerLeft() GasPowerLeft + func (e *EventPayload) GasPowerUsed() uint64 + func (e *EventPayload) MarshalBinary() ([]byte, error) + func (e *EventPayload) MarshalCSER(w *cser.Writer) error + func (e *EventPayload) MedianTime() Timestamp + func (e *EventPayload) NoTxs() bool + func (e *EventPayload) PrevEpochHash() *hash.Hash + func (e *EventPayload) Sig() Signature + func (e *EventPayload) Size() int + func (e *EventPayload) TxHash() hash.Hash + func (e *EventPayload) Txs() types.Transactions + func (e *EventPayload) UnmarshalBinary(raw []byte) (err error) + type EventPayloadI interface + Sig func() Signature + Txs func() types.Transactions + type EventPayloads []*EventPayload + func (ee *EventPayloads) Add(e ...*EventPayload) + func (ee EventPayloads) Bases() dag.Events + func (ee EventPayloads) IDs() hash.Events + func (ee EventPayloads) String() string + func (hh EventPayloads) Len() int + func (hh EventPayloads) Less(i, j int) bool + func (hh EventPayloads) Swap(i, j int) + type Events []*Event + func (ee *Events) Add(e ...*Event) + func (ee Events) Bases() dag.Events + func (ee Events) IDs() hash.Events + func (ee Events) Interfaces() EventIs + func (ee Events) String() string + func (hh Events) Len() int + func (hh Events) Less(i, j int) bool + func (hh Events) Swap(i, j int) + type GasPowerLeft struct + Gas [GasPowerConfigs]uint64 + func (g GasPowerLeft) Add(diff uint64) + func (g GasPowerLeft) Max() uint64 + func (g GasPowerLeft) Min() uint64 + func (g GasPowerLeft) String() string + func (g GasPowerLeft) Sub(diff uint64) GasPowerLeft + type MutableEventPayload struct + func (e *MutableEventPayload) Build() *EventPayload + func (e *MutableEventPayload) CreationTime() Timestamp + func (e *MutableEventPayload) DecodeRLP(src *rlp.Stream) error + func (e *MutableEventPayload) Extra() []byte + func (e *MutableEventPayload) GasPowerLeft() GasPowerLeft + func (e *MutableEventPayload) GasPowerUsed() uint64 + func (e *MutableEventPayload) HashToSign() hash.Hash + func (e *MutableEventPayload) MedianTime() Timestamp + func (e *MutableEventPayload) NoTxs() bool + func (e *MutableEventPayload) PrevEpochHash() *hash.Hash + func (e *MutableEventPayload) SetCreationTime(v Timestamp) + func (e *MutableEventPayload) SetExtra(v []byte) + func (e *MutableEventPayload) SetGasPowerLeft(v GasPowerLeft) + func (e *MutableEventPayload) SetGasPowerUsed(v uint64) + func (e *MutableEventPayload) SetMedianTime(v Timestamp) + func (e *MutableEventPayload) SetPrevEpochHash(v *hash.Hash) + func (e *MutableEventPayload) SetSig(v Signature) + func (e *MutableEventPayload) SetTxHash(v hash.Hash) + func (e *MutableEventPayload) SetTxs(v types.Transactions) + func (e *MutableEventPayload) Sig() Signature + func (e *MutableEventPayload) Size() int + func (e *MutableEventPayload) TxHash() hash.Hash + func (e *MutableEventPayload) Txs() types.Transactions + func (e *MutableEventPayload) UnmarshalBinary(raw []byte) (err error) + func (e *MutableEventPayload) UnmarshalCSER(r *cser.Reader) error + type Signature [SigSize]byte + func BytesToSignature(b []byte) (sig Signature) + func (s Signature) Bytes() []byte + type SignedEvent struct + func (e *SignedEvent) CreationTime() Timestamp + func (e *SignedEvent) Extra() []byte + func (e *SignedEvent) GasPowerLeft() GasPowerLeft + func (e *SignedEvent) GasPowerUsed() uint64 + func (e *SignedEvent) MedianTime() Timestamp + func (e *SignedEvent) NoTxs() bool + func (e *SignedEvent) PrevEpochHash() *hash.Hash + func (e *SignedEvent) Sig() Signature + func (e *SignedEvent) TxHash() hash.Hash + type Timestamp uint64 + func BytesToTimestamp(b []byte) Timestamp + func FromUnix(t int64) Timestamp + func MaxTimestamp(x, y Timestamp) Timestamp + func (t Timestamp) Bytes() []byte + func (t Timestamp) Time() time.Time + func (t Timestamp) Unix() int64