Documentation
¶
Index ¶
- type CCIPView
- type ContractMetaData
- type DestChainSpecificData
- type FeeQuoterDestChainConfig
- type FeeQuoterStaticConfig
- type FeeQuoterView
- type ITokenPoolDevInspect
- type MCMSWithTimelockView
- type NonceManagerView
- type OffRampDynamicConfig
- type OffRampSourceChainConfig
- type OffRampStaticConfig
- type OffRampView
- type OnRampDestChainConfig
- type OnRampDynamicConfig
- type OnRampStaticConfig
- type OnRampView
- type RMNRemoteCurseEntry
- type RMNRemoteSigner
- type RMNRemoteVersionedConfig
- type RMNRemoteView
- type RateLimiterConfig
- type ReceiverRegistryView
- type RemoteChainConfig
- type RouterView
- type TimelockBlockedFunction
- type TokenAdminRegistryView
- type TokenBucketWrapper
- type TokenConfigView
- type TokenPoolView
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CCIPView ¶
type CCIPView struct {
ContractMetaData
FeeQuoter FeeQuoterView `json:"feeQuoter"`
RMNRemote RMNRemoteView `json:"rmnRemote"`
TokenAdminRegistry TokenAdminRegistryView `json:"tokenAdminRegistry"`
NonceManager NonceManagerView `json:"nonceManager"`
ReceiverRegistry ReceiverRegistryView `json:"receiverRegistry"`
}
type ContractMetaData ¶
type DestChainSpecificData ¶
type DestChainSpecificData struct {
AllowedSendersList []string `json:"allowedSendersList"`
DestChainConfig OnRampDestChainConfig `json:"destChainConfig"`
ExpectedNextSeqNum uint64 `json:"expectedNextSeqNum"`
}
type FeeQuoterDestChainConfig ¶
type FeeQuoterDestChainConfig struct {
IsEnabled bool `json:"isEnabled"`
MaxNumberOfTokensPerMsg uint16 `json:"maxNumberOfTokensPerMsg"`
MaxDataBytes uint32 `json:"maxDataBytes"`
MaxPerMsgGasLimit uint32 `json:"maxPerMsgGasLimit"`
DestGasOverhead uint32 `json:"destGasOverhead"`
DestGasPerPayloadByteBase uint8 `json:"destGasPerPayloadByteBase"`
DestGasPerPayloadByteHigh uint8 `json:"destGasPerPayloadByteHigh"`
DestGasPerPayloadByteThreshold uint16 `json:"destGasPerPayloadByteThreshold"`
DestDataAvailabilityOverheadGas uint32 `json:"destDataAvailabilityOverheadGas"`
DestGasPerDataAvailabilityByte uint16 `json:"destGasPerDataAvailabilityByte"`
DestDataAvailabilityMultiplierBps uint16 `json:"destDataAvailabilityMultiplierBps"`
ChainFamilySelector string `json:"chainFamilySelector"`
EnforceOutOfOrder bool `json:"enforceOutOfOrder"`
DefaultTokenFeeUsdCents uint16 `json:"defaultTokenFeeUsdCents"`
DefaultTokenDestGasOverhead uint32 `json:"defaultTokenDestGasOverhead"`
DefaultTxGasLimit uint32 `json:"defaultTxGasLimit"`
GasMultiplierWeiPerEth uint64 `json:"gasMultiplierWeiPerEth"`
GasPriceStalenessThreshold uint32 `json:"gasPriceStalenessThreshold"`
NetworkFeeUsdCents uint32 `json:"networkFeeUsdCents"`
}
type FeeQuoterStaticConfig ¶
type FeeQuoterView ¶
type FeeQuoterView struct {
ContractMetaData
FeeTokens []string `json:"feeTokens"`
StaticConfig FeeQuoterStaticConfig `json:"staticConfig"`
DestinationChainConfigs map[uint64]FeeQuoterDestChainConfig `json:"destinationChainConfigs"`
}
type ITokenPoolDevInspect ¶
type ITokenPoolDevInspect[T TokenBucketWrapper] interface { TypeAndVersion(ctx context.Context, opts *bind.CallOpts) (string, error) Owner(ctx context.Context, opts *bind.CallOpts, typeArgs []string, state bind.Object) (string, error) GetToken(ctx context.Context, opts *bind.CallOpts, typeArgs []string, state bind.Object) (string, error) GetAllowlistEnabled(ctx context.Context, opts *bind.CallOpts, typeArgs []string, state bind.Object) (bool, error) GetAllowlist(ctx context.Context, opts *bind.CallOpts, typeArgs []string, state bind.Object) ([]string, error) GetSupportedChains(ctx context.Context, opts *bind.CallOpts, typeArgs []string, state bind.Object) ([]uint64, error) GetRemotePools(ctx context.Context, opts *bind.CallOpts, typeArgs []string, state bind.Object, remoteChainSelector uint64) ([][]byte, error) GetRemoteToken(ctx context.Context, opts *bind.CallOpts, typeArgs []string, state bind.Object, remoteChainSelector uint64) ([]byte, error) GetCurrentInboundRateLimiterState(ctx context.Context, opts *bind.CallOpts, typeArgs []string, clock bind.Object, state bind.Object, remoteChainSelector uint64) (T, error) GetCurrentOutboundRateLimiterState(ctx context.Context, opts *bind.CallOpts, typeArgs []string, clock bind.Object, state bind.Object, remoteChainSelector uint64) (T, error) }
ITokenPoolDevInspect defines the common DevInspect methods across pool types
type MCMSWithTimelockView ¶
type MCMSWithTimelockView struct {
ContractMetaData
Bypasser mcmstypes.Config `json:"bypasser"`
Proposer mcmstypes.Config `json:"proposer"`
Canceller mcmstypes.Config `json:"canceller"`
TimelockMinDelay uint64 `json:"timelockMinDelay"`
TimelockBlockedFunctions []TimelockBlockedFunction `json:"timelockBlockedFunctions"`
}
func GenerateMCMSWithTimelockView ¶
func GenerateMCMSWithTimelockView( ctx context.Context, chain sui.Chain, mcmsPackageID string, mcmsStateObjectID string, timelockObjectID string, accountStateObjectID string, ) (MCMSWithTimelockView, error)
GenerateMCMSWithTimelockView generates an MCMS with timelock view by querying the on-chain state
type NonceManagerView ¶
type NonceManagerView struct {
ContractMetaData
}
type OffRampDynamicConfig ¶
type OffRampStaticConfig ¶
type OffRampView ¶
type OffRampView struct {
ContractMetaData
StaticConfig OffRampStaticConfig `json:"staticConfig"`
DynamicConfig OffRampDynamicConfig `json:"dynamicConfig"`
SourceChainConfigs map[uint64]OffRampSourceChainConfig `json:"sourceChainConfigs"`
}
type OnRampDestChainConfig ¶
type OnRampDynamicConfig ¶
type OnRampStaticConfig ¶
type OnRampStaticConfig struct {
ChainSelector uint64 `json:"chainSelector"`
}
type OnRampView ¶
type OnRampView struct {
ContractMetaData
StaticConfig OnRampStaticConfig `json:"staticConfig"`
DynamicConfig OnRampDynamicConfig `json:"dynamicConfig"`
DestChainSpecificData map[uint64]DestChainSpecificData `json:"destChainSpecificData"`
}
func GenerateOnRampView ¶
func GenerateOnRampView( ctx context.Context, chain sui.Chain, onRampPackageID string, onRampStateObjectID string, routerPackageID string, routerStateObjectID string, ) (OnRampView, error)
GenerateOnRampView generates an onramp view for a given onramp by querying the on-chain state
type RMNRemoteCurseEntry ¶
type RMNRemoteSigner ¶
type RMNRemoteVersionedConfig ¶
type RMNRemoteVersionedConfig struct {
Version uint32 `json:"version"`
Signers []RMNRemoteSigner `json:"signers"`
Fsign uint64 `json:"fSign"`
}
type RMNRemoteView ¶
type RMNRemoteView struct {
ContractMetaData
IsCursed bool `json:"isCursed"`
Config RMNRemoteVersionedConfig `json:"config"`
CursedSubjectEntries []RMNRemoteCurseEntry `json:"cursedSubjectEntries"`
}
type RateLimiterConfig ¶
type ReceiverRegistryView ¶
type ReceiverRegistryView struct {
ContractMetaData
}
type RemoteChainConfig ¶
type RemoteChainConfig struct {
RemoteTokenAddress string `json:"remoteTokenAddress"`
RemotePoolAddresses []string `json:"remotePoolAddresses"`
InboundRateLimiterConfig RateLimiterConfig `json:"inboundRateLimiterConfig"`
OutboundRateLimiterConfig RateLimiterConfig `json:"outboundRateLimiterConfig"`
}
type RouterView ¶
type RouterView struct {
ContractMetaData
IsTestRouter bool `json:"isTestRouter"`
OnRamps map[uint64]string `json:"onRamps"` // Map of DestinationChainSelector to OnRampAddress
OffRamps map[uint64]string `json:"offRamps"` // Map of DestinationChainSelector to OffRampAddress
}
func GenerateRouterView ¶
func GenerateRouterView( ctx context.Context, chain sui.Chain, routerPackageID string, routerStateObjectID string, ) (RouterView, error)
GenerateRouterView generates a router view for a given router by querying the on-chain state
type TimelockBlockedFunction ¶
type TokenAdminRegistryView ¶
type TokenAdminRegistryView struct {
ContractMetaData
TokenConfigs map[string]TokenConfigView `json:"tokenConfigs"` // Token address => config
}
type TokenBucketWrapper ¶
type TokenBucketWrapper interface {
module_burn_mint_token_pool.TokenBucketWrapper |
module_lock_release_token_pool.TokenBucketWrapper |
module_managed_token_pool.TokenBucketWrapper |
module_usdc_token_pool.TokenBucketWrapper
}
type TokenConfigView ¶
type TokenConfigView struct {
TokenPoolPackageId string `json:"tokenPoolPackageId"`
TokenPoolModule string `json:"tokenPoolModule"`
TokenType string `json:"tokenType"`
Administrator string `json:"administrator"`
TokenPoolTypeProof string `json:"tokenPoolTypeProof"`
LockOrBurnParams []string `json:"lockOrBurnParams"`
ReleaseOrMintParams []string `json:"releaseOrMintParams"`
}
type TokenPoolView ¶
type TokenPoolView struct {
ContractMetaData
Token string `json:"token"`
RemoteChainConfigs map[uint64]RemoteChainConfig `json:"remoteChainConfigs"`
AllowList []string `json:"allowList"`
AllowListEnabled bool `json:"allowListEnabled"`
RebalancerCapIds []string `json:"rebalancerCapIds,omitempty"` // only applicable for LR TP
}
func GenerateTokenPoolView ¶
func GenerateTokenPoolView[T TokenBucketWrapper]( ctx context.Context, chain sui.Chain, poolPackageID string, poolStateObjectID string, tokenConfigs map[string]TokenConfigView, poolDevInspect ITokenPoolDevInspect[T], lggr logger.Logger, ) (TokenPoolView, error)
Click to show internal directories.
Click to hide internal directories.