Documentation ¶
Index ¶
- Constants
- func NewMsgServerImpl(k types.Nexus, snapshotter types.Snapshotter) types.MsgServiceServer
- func NewQuerier(k types.Nexus) sdk.Querier
- func QueryChainMaintainersByChain(ctx sdk.Context, k types.Nexus, chainStr string) ([]byte, error)
- type Keeper
- func (k Keeper) ActivateChain(ctx sdk.Context, chain exported.Chain)
- func (k Keeper) AddChainMaintainer(ctx sdk.Context, chain exported.Chain, maintainer sdk.ValAddress) error
- func (k Keeper) AddToChainTotal(ctx sdk.Context, chain exported.Chain, amount sdk.Coin)
- func (k Keeper) ArchivePendingTransfer(ctx sdk.Context, transfer exported.CrossChainTransfer)
- func (k Keeper) EnqueueForTransfer(ctx sdk.Context, sender exported.CrossChainAddress, asset sdk.Coin, ...) error
- func (k Keeper) GetChain(ctx sdk.Context, chainName string) (exported.Chain, bool)
- func (k Keeper) GetChainMaintainers(ctx sdk.Context, chain exported.Chain) []sdk.ValAddress
- func (k Keeper) GetChains(ctx sdk.Context) []exported.Chain
- func (k Keeper) GetParams(ctx sdk.Context) types.Params
- func (k Keeper) GetRecipient(ctx sdk.Context, sender exported.CrossChainAddress) (exported.CrossChainAddress, bool)
- func (k Keeper) GetTransfersForChain(ctx sdk.Context, chain exported.Chain, state exported.TransferState) []exported.CrossChainTransfer
- func (k Keeper) IsAssetRegistered(ctx sdk.Context, chainName, denom string) bool
- func (k Keeper) IsChainActivated(ctx sdk.Context, chain exported.Chain) bool
- func (k Keeper) IsChainMaintainer(ctx sdk.Context, chain exported.Chain, maintainer sdk.ValAddress) bool
- func (k Keeper) LinkAddresses(ctx sdk.Context, sender exported.CrossChainAddress, ...)
- func (k Keeper) Logger(ctx sdk.Context) log.Logger
- func (k Keeper) RegisterAsset(ctx sdk.Context, chainName, denom string)
- func (k Keeper) RemoveChainMaintainer(ctx sdk.Context, chain exported.Chain, maintainer sdk.ValAddress) error
- func (k Keeper) SetChain(ctx sdk.Context, chain exported.Chain)
- func (k Keeper) SetParams(ctx sdk.Context, p types.Params)
Constants ¶
const (
QueryChainMaintainers = "chain-maintainers"
)
Query labels
Variables ¶
This section is empty.
Functions ¶
func NewMsgServerImpl ¶
func NewMsgServerImpl(k types.Nexus, snapshotter types.Snapshotter) types.MsgServiceServer
NewMsgServerImpl returns an implementation of the nexus MsgServiceServer interface for the provided Keeper.
func NewQuerier ¶
NewQuerier returns a new querier for the nexus module
Types ¶
type Keeper ¶
type Keeper struct {
// contains filtered or unexported fields
}
Keeper represents a nexus keeper
func NewKeeper ¶
func NewKeeper(cdc codec.BinaryCodec, storeKey sdk.StoreKey, paramSpace params.Subspace, ak types.AxelarnetKeeper) Keeper
NewKeeper returns a new nexus keeper
func (Keeper) ActivateChain ¶
ActivateChain activates the given chain
func (Keeper) AddChainMaintainer ¶
func (k Keeper) AddChainMaintainer(ctx sdk.Context, chain exported.Chain, maintainer sdk.ValAddress) error
AddChainMaintainer adds the given address to be one of the given chain's maintainers
func (Keeper) AddToChainTotal ¶
AddToChainTotal add balance for an asset for a chain
func (Keeper) ArchivePendingTransfer ¶
func (k Keeper) ArchivePendingTransfer(ctx sdk.Context, transfer exported.CrossChainTransfer)
ArchivePendingTransfer marks the transfer for the given recipient as concluded and archived
func (Keeper) EnqueueForTransfer ¶
func (k Keeper) EnqueueForTransfer(ctx sdk.Context, sender exported.CrossChainAddress, asset sdk.Coin, feeRate sdk.Dec) error
EnqueueForTransfer appoints the amount of tokens to be transfered/minted to the recipient previously linked to the specified sender
func (Keeper) GetChainMaintainers ¶
GetChainMaintainers returns the maintainers of the given chain
func (Keeper) GetRecipient ¶
func (k Keeper) GetRecipient(ctx sdk.Context, sender exported.CrossChainAddress) (exported.CrossChainAddress, bool)
GetRecipient retrieves the cross chain recipient associated to the specified sender
func (Keeper) GetTransfersForChain ¶
func (k Keeper) GetTransfersForChain(ctx sdk.Context, chain exported.Chain, state exported.TransferState) []exported.CrossChainTransfer
GetTransfersForChain returns the current set of transfers with the given state for the given chain
func (Keeper) IsAssetRegistered ¶
IsAssetRegistered returns true if the specified asset is supported by the given chain
func (Keeper) IsChainActivated ¶
IsChainActivated returns true if the given chain is activated; false otherwise
func (Keeper) IsChainMaintainer ¶
func (k Keeper) IsChainMaintainer(ctx sdk.Context, chain exported.Chain, maintainer sdk.ValAddress) bool
IsChainMaintainer returns true if the given address is one of the given chain's maintainers; false otherwise
func (Keeper) LinkAddresses ¶
func (k Keeper) LinkAddresses(ctx sdk.Context, sender exported.CrossChainAddress, recipient exported.CrossChainAddress)
LinkAddresses links a sender address to a cross-chain recipient address
func (Keeper) RegisterAsset ¶
RegisterAsset indicates that the specified asset is supported by the given chain
func (Keeper) RemoveChainMaintainer ¶
func (k Keeper) RemoveChainMaintainer(ctx sdk.Context, chain exported.Chain, maintainer sdk.ValAddress) error
RemoveChainMaintainer removes the given address from the given chain's maintainers