Documentation ¶
Index ¶
- Constants
- func CheckpointEpoch(epoch, period abi.ChainEpoch) abi.ChainEpoch
- func WindowEpoch(epoch, period abi.ChainEpoch) abi.ChainEpoch
- type AmountParams
- type BatchCrossMsgs
- type BottomUpCheckpoint
- type CheckData
- type ChildCheck
- type ConstructParams
- type CrossMsg
- type CrossMsgParams
- type CrossMsgs
- type FundParams
- type IPCMsgType
- type InitGenesisEpochParams
- type ReleaseParams
- type State
- func (st *State) GetCheckpoints(s adt.Store, e abi.ChainEpoch) (*BottomUpCheckpoint, bool, error)
- func (st *State) GetSubnet(s adt.Store, id sdk.SubnetID) (*Subnet, bool, error)
- func (st *State) GetTopDownMsg(s adt.Store, id sdk.SubnetID, nonce uint64) (*CrossMsg, error)
- func (st *State) GetWindowCheckpoint(s adt.Store, epoch abi.ChainEpoch) (*BottomUpCheckpoint, error)
- func (st *State) ListSubnets(s adt.Store) ([]Subnet, error)
- func (t *State) MarshalCBOR(w io.Writer) error
- func (t *State) UnmarshalCBOR(r io.Reader) (err error)
- type StorableMsg
- type Subnet
- type TopDownCheckpoint
Constants ¶
View Source
const CrossMsgsAMTBitwidth = 3
View Source
const ManifestID = "ipc_gateway"
ManifestID is the id used to index the gateway actor in the builtin-actors bundle.
Variables ¶
This section is empty.
Functions ¶
func CheckpointEpoch ¶
func CheckpointEpoch(epoch, period abi.ChainEpoch) abi.ChainEpoch
func WindowEpoch ¶
func WindowEpoch(epoch, period abi.ChainEpoch) abi.ChainEpoch
Types ¶
type AmountParams ¶ added in v0.1.6
type AmountParams struct {
Value abi.TokenAmount
}
func (*AmountParams) MarshalCBOR ¶ added in v0.1.6
func (t *AmountParams) MarshalCBOR(w io.Writer) error
func (*AmountParams) UnmarshalCBOR ¶ added in v0.1.6
func (t *AmountParams) UnmarshalCBOR(r io.Reader) (err error)
type BatchCrossMsgs ¶ added in v0.1.5
type BatchCrossMsgs struct { CrossMsgs []CrossMsg Fee abi.TokenAmount }
func (*BatchCrossMsgs) MarshalCBOR ¶ added in v0.1.5
func (t *BatchCrossMsgs) MarshalCBOR(w io.Writer) error
func (*BatchCrossMsgs) UnmarshalCBOR ¶ added in v0.1.5
func (t *BatchCrossMsgs) UnmarshalCBOR(r io.Reader) (err error)
type BottomUpCheckpoint ¶ added in v0.1.5
func NewBottomUpCheckpoint ¶ added in v0.1.5
func NewBottomUpCheckpoint(subnet sdk.SubnetID, epoch abi.ChainEpoch) *BottomUpCheckpoint
func (*BottomUpCheckpoint) Cid ¶ added in v0.1.5
func (c *BottomUpCheckpoint) Cid() (cid.Cid, error)
func (*BottomUpCheckpoint) MarshalCBOR ¶ added in v0.1.5
func (t *BottomUpCheckpoint) MarshalCBOR(w io.Writer) error
func (*BottomUpCheckpoint) UnmarshalCBOR ¶ added in v0.1.5
func (t *BottomUpCheckpoint) UnmarshalCBOR(r io.Reader) (err error)
type CheckData ¶
type CheckData struct { Source sdk.SubnetID Proof []byte Epoch abi.ChainEpoch PrevCheck cid.Cid // TCid<TLink<Checkpoint>> Children []ChildCheck CrossMsgs BatchCrossMsgs }
type ChildCheck ¶
func (*ChildCheck) MarshalCBOR ¶
func (t *ChildCheck) MarshalCBOR(w io.Writer) error
func (*ChildCheck) UnmarshalCBOR ¶
func (t *ChildCheck) UnmarshalCBOR(r io.Reader) (err error)
type ConstructParams ¶
type ConstructParams struct { NetworkName string CheckpointPeriod abi.ChainEpoch }
func (*ConstructParams) MarshalCBOR ¶
func (t *ConstructParams) MarshalCBOR(w io.Writer) error
func (*ConstructParams) UnmarshalCBOR ¶
func (t *ConstructParams) UnmarshalCBOR(r io.Reader) (err error)
type CrossMsg ¶
type CrossMsg struct { Msg StorableMsg Wrapped bool }
type CrossMsgParams ¶
func (*CrossMsgParams) MarshalCBOR ¶
func (t *CrossMsgParams) MarshalCBOR(w io.Writer) error
func (*CrossMsgParams) UnmarshalCBOR ¶
func (t *CrossMsgParams) UnmarshalCBOR(r io.Reader) (err error)
type FundParams ¶
func (*FundParams) MarshalCBOR ¶
func (t *FundParams) MarshalCBOR(w io.Writer) error
func (*FundParams) UnmarshalCBOR ¶
func (t *FundParams) UnmarshalCBOR(r io.Reader) (err error)
type IPCMsgType ¶
type IPCMsgType int
const ( IPCMsgTypeUnknown IPCMsgType = iota IPCMsgTypeBottomUp IPCMsgTypeTopDown )
type InitGenesisEpochParams ¶ added in v0.1.5
type InitGenesisEpochParams struct {
GenesisEpoch abi.ChainEpoch
}
func (*InitGenesisEpochParams) MarshalCBOR ¶ added in v0.1.5
func (t *InitGenesisEpochParams) MarshalCBOR(w io.Writer) error
func (*InitGenesisEpochParams) UnmarshalCBOR ¶ added in v0.1.5
func (t *InitGenesisEpochParams) UnmarshalCBOR(r io.Reader) (err error)
type ReleaseParams ¶ added in v0.1.6
type ReleaseParams struct {
To address.Address
}
func (*ReleaseParams) MarshalCBOR ¶ added in v0.1.6
func (t *ReleaseParams) MarshalCBOR(w io.Writer) error
func (*ReleaseParams) UnmarshalCBOR ¶ added in v0.1.6
func (t *ReleaseParams) UnmarshalCBOR(r io.Reader) (err error)
type State ¶
type State struct { NetworkName sdk.SubnetID TotalSubnets uint64 MinStake abi.TokenAmount Subnets cid.Cid // TCid<THamt<SubnetID, Subnet>> BottomUpCheckPeriod abi.ChainEpoch TopDownCheckPeriod abi.ChainEpoch BottomUpCheckpoints cid.Cid // TCid<THamt<ChainEpoch, Checkpoint>> Postbox cid.Cid // TCid<THamt<Cid, Vec<u8>>> BottomupNonce uint64 AppliedTopdownNonce uint64 TopDownCheckpointVoting voting.Voting Validators validator.OnChainValidators Initialized bool }
func (*State) GetCheckpoints ¶
func (st *State) GetCheckpoints(s adt.Store, e abi.ChainEpoch) (*BottomUpCheckpoint, bool, error)
func (*State) GetTopDownMsg ¶
func (*State) GetWindowCheckpoint ¶ added in v0.1.2
func (st *State) GetWindowCheckpoint(s adt.Store, epoch abi.ChainEpoch) (*BottomUpCheckpoint, error)
GetWindowCheckpoint gets the template for a specific epoch. If no template is persisted yet, an empty template is provided. Here we get the checkpoint template for an epoch that is already finished and ready to be populated
NOTE: This function doesn't check if a template from the future is being requested.
func (*State) ListSubnets ¶ added in v0.1.3
ListSubnets lists subnets registered in the gateway
type StorableMsg ¶
type StorableMsg struct { From sdk.IPCAddress To sdk.IPCAddress Method abi.MethodNum Params []byte Value abi.TokenAmount Nonce uint64 }
func (*StorableMsg) IPCType ¶
func (sm *StorableMsg) IPCType() IPCMsgType
func (*StorableMsg) MarshalCBOR ¶
func (t *StorableMsg) MarshalCBOR(w io.Writer) error
func (*StorableMsg) UnmarshalCBOR ¶
func (t *StorableMsg) UnmarshalCBOR(r io.Reader) (err error)
type Subnet ¶
type Subnet struct { ID sdk.SubnetID Stake abi.TokenAmount TopDownMsgs cid.Cid // TCid<TAmt<CrossMsg, CROSSMSG_AMT_BITWIDTH>>, Nonce uint64 CircSupply abi.TokenAmount Status sdk.Status PrevCheckpoint *BottomUpCheckpoint AppliedBottomupNonce uint64 GenesisEpoch abi.ChainEpoch }
func (*Subnet) GetTopDownMsg ¶
func (*Subnet) TopDownMsgsFromNonce ¶ added in v0.1.4
TopDownMsgFromNonce gets the latest topDownMessages from a specific nonce (including the one specified, i.e. [nonce, latest], both limits included).
type TopDownCheckpoint ¶ added in v0.1.5
type TopDownCheckpoint struct { Epoch abi.ChainEpoch TopDownMsgs []CrossMsgs }
func (*TopDownCheckpoint) MarshalCBOR ¶ added in v0.1.5
func (t *TopDownCheckpoint) MarshalCBOR(w io.Writer) error
func (*TopDownCheckpoint) UnmarshalCBOR ¶ added in v0.1.5
func (t *TopDownCheckpoint) UnmarshalCBOR(r io.Reader) (err error)
Click to show internal directories.
Click to hide internal directories.