Versions in this module Expand all Collapse all v1 v1.0.0 Aug 15, 2021 Changes in this version + const BigIntMaxSerializedLen + const MessageVersion + const TestGasLimit + var EmptyInt = BigInt + var EmptyTSK = TipSetKey + var ErrActorNotFound = errors.New("actor not found") + var ErrKeyExists = fmt.Errorf("key already exists") + var ErrKeyInfoNotFound = fmt.Errorf("key info not found") + var MaxWinCount = 3 * int64(build.BlocksPerEpoch) + var TotalEpkInt = FromEpk(build.EpkBase) + func BigCmp(a, b BigInt) int + func CidArrsContains(a []cid.Cid, b cid.Cid) bool + func CidArrsEqual(a, b []cid.Cid) bool + func CidArrsSubset(a, b []cid.Cid) bool + func DeciStr(bi BigInt) string + func IsTicketWinner(vrfTicket []byte, mypow BigInt, totpow BigInt) bool + func SizeStr(bi BigInt) string + type Actor struct + Balance BigInt + Code cid.Cid + Head cid.Cid + Nonce uint64 + func (t *Actor) MarshalCBOR(w io.Writer) error + func (t *Actor) UnmarshalCBOR(r io.Reader) error + type BeaconEntry struct + Data []byte + Round uint64 + func NewBeaconEntry(round uint64, data []byte) BeaconEntry + func (t *BeaconEntry) MarshalCBOR(w io.Writer) error + func (t *BeaconEntry) UnmarshalCBOR(r io.Reader) error + type BigInt = big2.Int + func BigAdd(a, b BigInt) BigInt + func BigDiv(a, b BigInt) BigInt + func BigFromBytes(b []byte) BigInt + func BigFromString(s string) (BigInt, error) + func BigMod(a, b BigInt) BigInt + func BigMul(a, b BigInt) BigInt + func BigSub(a, b BigInt) BigInt + func FromEpk(i uint64) BigInt + func NewInt(i uint64) BigInt + type BlockHeader struct + BLSAggregate *crypto.Signature + BeaconEntries []BeaconEntry + BlockSig *crypto.Signature + ElectionProof *ElectionProof + ForkSignaling uint64 + Height abi.ChainEpoch + Messages cid.Cid + Miner address.Address + ParentBaseFee abi.TokenAmount + ParentMessageReceipts cid.Cid + ParentStateRoot cid.Cid + ParentWeight BigInt + Parents []cid.Cid + Ticket *Ticket + Timestamp uint64 + WinPoStProof []proof2.PoStProof + func DecodeBlock(b []byte) (*BlockHeader, error) + func (blk *BlockHeader) Cid() cid.Cid + func (blk *BlockHeader) IsValidated() bool + func (blk *BlockHeader) LastTicket() *Ticket + func (blk *BlockHeader) Serialize() ([]byte, error) + func (blk *BlockHeader) SetValidated() + func (blk *BlockHeader) SigningBytes() ([]byte, error) + func (blk *BlockHeader) ToStorageBlock() (block.Block, error) + func (t *BlockHeader) MarshalCBOR(w io.Writer) error + func (t *BlockHeader) UnmarshalCBOR(r io.Reader) error + type BlockMsg struct + BlsMessages []cid.Cid + Header *BlockHeader + SecpkMessages []cid.Cid + func DecodeBlockMsg(b []byte) (*BlockMsg, error) + func (bm *BlockMsg) Cid() cid.Cid + func (bm *BlockMsg) Serialize() ([]byte, error) + func (t *BlockMsg) MarshalCBOR(w io.Writer) error + func (t *BlockMsg) UnmarshalCBOR(r io.Reader) error + type ChainMsg interface + ChainLength func() int + Cid func() cid.Cid + ToStorageBlock func() (block.Block, error) + VMMessage func() *Message + type EPK BigInt + func MustParseEPK(s string) EPK + func ParseEPK(s string) (EPK, error) + func (f EPK) Format(s fmt.State, ch rune) + func (f EPK) MarshalText() (text []byte, err error) + func (f EPK) Short() string + func (f EPK) String() string + func (f EPK) Unitless() string + func (f EPK) UnmarshalText(text []byte) error + type ElectionProof struct + VRFProof []byte + WinCount int64 + func (ep *ElectionProof) ComputeWinCount(power BigInt, totalPower BigInt) int64 + func (t *ElectionProof) MarshalCBOR(w io.Writer) error + func (t *ElectionProof) UnmarshalCBOR(r io.Reader) error + type ExecutionTrace struct + Duration time.Duration + Error string + GasCharges []*GasTrace + Msg *Message + MsgRct *MessageReceipt + Subcalls []ExecutionTrace + type ExpTipSet struct + Blocks []*BlockHeader + Cids []cid.Cid + Height abi.ChainEpoch + func (t *ExpTipSet) MarshalCBOR(w io.Writer) error + func (t *ExpTipSet) UnmarshalCBOR(r io.Reader) error + type FullBlock struct + BlsMessages []*Message + Header *BlockHeader + SecpkMessages []*SignedMessage + func (fb *FullBlock) Cid() cid.Cid + type GasTrace struct + Callers []uintptr + ComputeGas int64 + Extra interface{} + Location []Loc + Name string + StorageGas int64 + TimeTaken time.Duration + TotalGas int64 + TotalVirtualGas int64 + VirtualComputeGas int64 + VirtualStorageGas int64 + func (gt *GasTrace) MarshalJSON() ([]byte, error) + type KeyInfo struct + PrivateKey []byte + Type KeyType + type KeyStore interface + Delete func(string) error + Get func(string) (KeyInfo, error) + List func() ([]string, error) + Put func(string, KeyInfo) error + type KeyType string + const KTBLS + const KTSecp256k1 + const KTSecp256k1Ledger + func (kt *KeyType) UnmarshalJSON(bb []byte) error + type Loc struct + File string + Function string + Line int + func (l Loc) Important() bool + func (l Loc) Show() bool + func (l Loc) String() string + type LogCids []cid.Cid + func (cids LogCids) MarshalLogArray(ae zapcore.ArrayEncoder) error + type Message struct + From address.Address + GasFeeCap abi.TokenAmount + GasLimit int64 + GasPremium abi.TokenAmount + Method abi.MethodNum + Nonce uint64 + Params []byte + To address.Address + Value abi.TokenAmount + Version uint64 + func DecodeMessage(b []byte) (*Message, error) + func (m *Message) Caller() address.Address + func (m *Message) ChainLength() int + func (m *Message) Cid() cid.Cid + func (m *Message) EqualCall(o *Message) bool + func (m *Message) Equals(o *Message) bool + func (m *Message) MarshalJSON() ([]byte, error) + func (m *Message) Receiver() address.Address + func (m *Message) RequiredFunds() BigInt + func (m *Message) Serialize() ([]byte, error) + func (m *Message) ToStorageBlock() (block.Block, error) + func (m *Message) VMMessage() *Message + func (m *Message) ValidForBlockInclusion(minGas int64, version network.Version) error + func (m *Message) ValueReceived() abi.TokenAmount + func (t *Message) MarshalCBOR(w io.Writer) error + func (t *Message) UnmarshalCBOR(r io.Reader) error + type MessageReceipt struct + ExitCode exitcode.ExitCode + GasUsed int64 + Return []byte + func (mr *MessageReceipt) Equals(o *MessageReceipt) bool + func (t *MessageReceipt) MarshalCBOR(w io.Writer) error + func (t *MessageReceipt) UnmarshalCBOR(r io.Reader) error + type MpoolConfig struct + GasLimitOverestimation float64 + PriorityAddrs []address.Address + PruneCooldown time.Duration + ReplaceByFeeRatio float64 + SizeLimitHigh int + SizeLimitLow int + func (mc *MpoolConfig) Clone() *MpoolConfig + type MsgMeta struct + BlsMessages cid.Cid + SecpkMessages cid.Cid + func (mm *MsgMeta) Cid() cid.Cid + func (mm *MsgMeta) ToStorageBlock() (block.Block, error) + func (t *MsgMeta) MarshalCBOR(w io.Writer) error + func (t *MsgMeta) UnmarshalCBOR(r io.Reader) error + type RawMessage Message + type RawSignedMessage SignedMessage + type SignedMessage struct + Message Message + Signature crypto.Signature + func DecodeSignedMessage(data []byte) (*SignedMessage, error) + func (sm *SignedMessage) ChainLength() int + func (sm *SignedMessage) Cid() cid.Cid + func (sm *SignedMessage) MarshalJSON() ([]byte, error) + func (sm *SignedMessage) Serialize() ([]byte, error) + func (sm *SignedMessage) Size() int + func (sm *SignedMessage) ToStorageBlock() (block.Block, error) + func (sm *SignedMessage) VMMessage() *Message + func (t *SignedMessage) MarshalCBOR(w io.Writer) error + func (t *SignedMessage) UnmarshalCBOR(r io.Reader) error + type StateInfo0 struct + func (t *StateInfo0) MarshalCBOR(w io.Writer) error + func (t *StateInfo0) UnmarshalCBOR(r io.Reader) error + type StateRoot struct + Actors cid.Cid + Info cid.Cid + Version StateTreeVersion + func (t *StateRoot) MarshalCBOR(w io.Writer) error + func (t *StateRoot) UnmarshalCBOR(r io.Reader) error + type StateTree interface + GetActor func(addr address.Address) (*Actor, error) + SetActor func(addr address.Address, act *Actor) error + type StateTreeVersion uint64 + const StateTreeVersion0 + const StateTreeVersion1 + const StateTreeVersion2 + type Storage interface + Commit func(oldh cid.Cid, newh cid.Cid) aerrors.ActorError + Get func(cid.Cid, cbg.CBORUnmarshaler) aerrors.ActorError + GetHead func() cid.Cid + Put func(cbg.CBORMarshaler) (cid.Cid, aerrors.ActorError) + type Ticket struct + VRFProof []byte + func (t *Ticket) Equals(ot *Ticket) bool + func (t *Ticket) Less(o *Ticket) bool + func (t *Ticket) MarshalCBOR(w io.Writer) error + func (t *Ticket) Quality() float64 + func (t *Ticket) UnmarshalCBOR(r io.Reader) error + type TipSet struct + func NewTipSet(blks []*BlockHeader) (*TipSet, error) + func (ts *TipSet) Blocks() []*BlockHeader + func (ts *TipSet) Cids() []cid.Cid + func (ts *TipSet) Contains(oc cid.Cid) bool + func (ts *TipSet) Equals(ots *TipSet) bool + func (ts *TipSet) Height() abi.ChainEpoch + func (ts *TipSet) IsChildOf(parent *TipSet) bool + func (ts *TipSet) Key() TipSetKey + func (ts *TipSet) MarshalCBOR(w io.Writer) error + func (ts *TipSet) MarshalJSON() ([]byte, error) + func (ts *TipSet) MinTicket() *Ticket + func (ts *TipSet) MinTicketBlock() *BlockHeader + func (ts *TipSet) MinTimestamp() uint64 + func (ts *TipSet) ParentState() cid.Cid + func (ts *TipSet) ParentWeight() BigInt + func (ts *TipSet) Parents() TipSetKey + func (ts *TipSet) String() string + func (ts *TipSet) UnmarshalCBOR(r io.Reader) error + func (ts *TipSet) UnmarshalJSON(b []byte) error + type TipSetKey struct + func NewTipSetKey(cids ...cid.Cid) TipSetKey + func TipSetKeyFromBytes(encoded []byte) (TipSetKey, error) + func (k *TipSetKey) UnmarshalJSON(b []byte) error + func (k TipSetKey) Bytes() []byte + func (k TipSetKey) Cids() []cid.Cid + func (k TipSetKey) IsEmpty() bool + func (k TipSetKey) MarshalJSON() ([]byte, error) + func (k TipSetKey) String() string