types

package
v1.0.0-rc0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 2, 2022 License: Apache-2.0 Imports: 46 Imported by: 1

Documentation

Overview

Package types is a reverse proxy.

It translates gRPC into RESTful JSON APIs.

Index

Constants

View Source
const (
	AttributeValueCategory = ModuleName

	AttributeKeyRecipient             = "recipient"
	AttributeKeySender                = "sender"
	AttributeKeyAmount                = "amount"
	AttributeKeyReceiver              = "receiver"
	AttributeKeyEthereumTokenContract = "ethereum_token_contract"

	// events
	EventTypeConvertVouchers             = "convert_vouchers"
	EventTypeTransferTokens              = "transfer_tokens"
	EventTypeEthereumSendToCosmosHandled = "ethereum_send_to_cosmos_handled"
)
View Source
const (
	// ModuleName defines the module name
	ModuleName = "cronos"

	// StoreKey defines the primary module store key
	StoreKey = ModuleName

	// RouterKey is the message route for slashing
	RouterKey = ModuleName

	// QuerierRoute defines the module's query routing key
	QuerierRoute = ModuleName

	// MemStoreKey defines the in-memory store key
	MemStoreKey = "mem_cronos"
)
View Source
const (
	TypeMsgConvertVouchers    = "ConvertVouchers"
	TypeMsgTransferTokens     = "TransferTokens"
	TypeMsgUpdateTokenMapping = "UpdateTokenMapping"
)
View Source
const (
	IbcCroDenomDefaultValue = "ibc/6B5A664BF0AF4F71B2F0BAA33141E2F1321242FBD5D19762F541EC971ACB0865"
	IbcTimeoutDefaultValue  = uint64(86400000000000) // 1 day
)
View Source
const DefaultIndex uint64 = 1

DefaultIndex is the default capability global index

View Source
const EVMModuleName = "cronos-evm"
View Source
const (
	// ProposalTypeTokenMappingChange defines the type for a TokenMappingChangeProposal
	ProposalTypeTokenMappingChange = "TokenMappingChange"
)

Variables

View Source
var (
	ErrInvalidLengthCronos        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowCronos          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupCronos = fmt.Errorf("proto: unexpected end of group")
)
View Source
var (
	ErrIbcCroDenomEmpty   = sdkerrors.Register(ModuleName, codeErrIbcCroDenomEmpty, "ibc cro denom is not set")
	ErrIbcCroDenomInvalid = sdkerrors.Register(ModuleName, codeErrIbcCroDenomInvalid, "ibc cro denom is invalid")
)

x/cronos module sentinel errors

View Source
var (
	ErrInvalidLengthGenesis        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowGenesis          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupGenesis = fmt.Errorf("proto: unexpected end of group")
)
View Source
var (
	KeyPrefixDenomToExternalContract = []byte{prefixDenomToExternalContract}
	KeyPrefixDenomToAutoContract     = []byte{prefixDenomToAutoContract}
	KeyPrefixContractToDenom         = []byte{prefixContractToDenom}
)

KVStore key prefixes

View Source
var (
	// KeyIbcCroDenom is store's key for the IBC Cro denomination
	KeyIbcCroDenom = []byte("IbcCroDenom")
	// KeyIbcTimeout is store's key for the IBC Timeout
	KeyIbcTimeout = []byte("IbcTimeout")
	// KeyCronosAdmin is store's key for the admin address
	KeyCronosAdmin = []byte("CronosAdmin")
	// KeyEnableAutoDeployment is store's key for the EnableAutoDeployment
	KeyEnableAutoDeployment = []byte("EnableAutoDeployment")
)
View Source
var (
	ErrInvalidLengthQuery        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowQuery          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupQuery = fmt.Errorf("proto: unexpected end of group")
)
View Source
var (
	ErrInvalidLengthTx        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowTx          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupTx = fmt.Errorf("proto: unexpected end of group")
)
View Source
var (
	Ten       = big.NewInt(10)
	TenPowTen = Ten.Exp(Ten, Ten, nil)
)

Functions

func ContractToDenomKey added in v0.6.1

func ContractToDenomKey(contract []byte) []byte

ContractToDenomKey defines the store key for contract to denom reverse index

func DenomToAutoContractKey added in v0.6.1

func DenomToAutoContractKey(denom string) []byte

DenomToAutoContractKey defines the store key for denom to auto contract mapping

func DenomToExternalContractKey added in v0.6.1

func DenomToExternalContractKey(denom string) []byte

DenomToExternalContractKey defines the store key for denom to contract mapping

func GetContractAddressFromDenom added in v1.0.0

func GetContractAddressFromDenom(denom string) (string, error)

GetContractAddressFromDenom get the contract address from the coin denom

func IsSourceCoin added in v1.0.0

func IsSourceCoin(denom string) bool

IsSourceCoin returns true if denom is a coin originated from cronos

func IsValidCoinDenom added in v1.0.0

func IsValidCoinDenom(denom string) bool

IsValidCoinDenom returns true if it's ok it is a valid coin denom

func IsValidCronosDenom added in v1.0.0

func IsValidCronosDenom(denom string) bool

IsValidCronosDenom returns true if denom is a valid cronos denom

func IsValidGravityDenom added in v0.6.1

func IsValidGravityDenom(denom string) bool

IsValidGravityDenom returns true if denom is a valid gravity denom

func IsValidIBCDenom added in v0.6.1

func IsValidIBCDenom(denom string) bool

IsValidIBCDenom returns true if denom is a valid ibc denom

func NewConvertVouchersEvent added in v0.6.1

func NewConvertVouchersEvent(sender string, amount fmt.Stringer) sdk.Event

NewConvertVouchersEvent constructs a new voucher convert sdk.Event nolint: interfacer

func NewTransferTokensEvent added in v0.6.1

func NewTransferTokensEvent(sender string, recipient string, amount fmt.Stringer) sdk.Event

NewTransferTokensEvent constructs a new transfer sdk.Event

func ParamKeyTable added in v0.6.1

func ParamKeyTable() paramtypes.KeyTable

ParamKeyTable returns the parameter key table.

func RegisterCodec

func RegisterCodec(cdc *codec.LegacyAmino)

func RegisterInterfaces

func RegisterInterfaces(registry cdctypes.InterfaceRegistry)

func RegisterMsgServer

func RegisterMsgServer(s grpc1.Server, srv MsgServer)

func RegisterQueryHandler added in v0.6.1

func RegisterQueryHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error

RegisterQueryHandler registers the http handlers for service Query to "mux". The handlers forward requests to the grpc endpoint over "conn".

func RegisterQueryHandlerClient added in v0.6.1

func RegisterQueryHandlerClient(ctx context.Context, mux *runtime.ServeMux, client QueryClient) error

RegisterQueryHandlerClient registers the http handlers for service Query to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "QueryClient". Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "QueryClient" doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in "QueryClient" to call the correct interceptors.

func RegisterQueryHandlerFromEndpoint added in v0.6.1

func RegisterQueryHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error)

RegisterQueryHandlerFromEndpoint is same as RegisterQueryHandler but automatically dials to "endpoint" and closes the connection when "ctx" gets done.

func RegisterQueryHandlerServer added in v0.6.1

func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, server QueryServer) error

RegisterQueryHandlerServer registers the http handlers for service Query to "mux". UnaryRPC :call QueryServer directly. StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterQueryHandlerFromEndpoint instead.

func RegisterQueryServer

func RegisterQueryServer(s grpc1.Server, srv QueryServer)

Types

type AccountKeeper added in v0.6.1

type AccountKeeper interface {
	GetModuleAccount(ctx sdk.Context, moduleName string) authtypes.ModuleAccountI

	GetAccount(ctx sdk.Context, addr sdk.AccAddress) authtypes.AccountI
	SetAccount(ctx sdk.Context, account authtypes.AccountI)
}

AccountKeeper defines the expected account keeper interface

type BankKeeper added in v0.6.1

type BankKeeper interface {
	SpendableCoins(ctx sdk.Context, addr sdk.AccAddress) sdk.Coins
	SendCoinsFromModuleToAccount(ctx sdk.Context, senderModule string, recipientAddr sdk.AccAddress, amt sdk.Coins) error
	SendCoinsFromAccountToModule(ctx sdk.Context, senderAddr sdk.AccAddress, recipientModule string, amt sdk.Coins) error
	MintCoins(ctx sdk.Context, moduleName string, amt sdk.Coins) error
	BurnCoins(ctx sdk.Context, moduleName string, amt sdk.Coins) error
	SendCoins(ctx sdk.Context, senderAddr sdk.AccAddress, recipientAddr sdk.AccAddress, amt sdk.Coins) error

	GetDenomMetaData(ctx sdk.Context, denom string) (banktypes.Metadata, bool)
	SetDenomMetaData(ctx sdk.Context, denomMetaData banktypes.Metadata)
}

BankKeeper defines the expected interface needed to retrieve account balances.

type ByteString added in v0.6.1

type ByteString []byte

ByteString is a byte array that serializes to hex

func (ByteString) MarshalJSON added in v0.6.1

func (s ByteString) MarshalJSON() ([]byte, error)

MarshalJSON serializes ByteArray to hex

func (*ByteString) UnmarshalJSON added in v0.6.1

func (s *ByteString) UnmarshalJSON(data []byte) error

UnmarshalJSON deserializes ByteArray to hex

type CompiledContract added in v0.6.1

type CompiledContract struct {
	ABI abi.ABI
	Bin ByteString
}

CompiledContract contains compiled bytecode and abi

var (

	// ModuleCRC20Contract is the compiled cronos crc20 contract
	ModuleCRC20Contract CompiledContract

	// ModuleCRC21Contract is the compiled cronos crc21 contract
	ModuleCRC21Contract CompiledContract

	// EVMModuleAddress is the native module address for EVM
	EVMModuleAddress common.Address
)

type ContractByDenomRequest added in v0.6.1

type ContractByDenomRequest struct {
	Denom string `protobuf:"bytes,1,opt,name=denom,proto3" json:"denom,omitempty"`
}

ContractByDenomRequest is the request type of ContractByDenom call

func (*ContractByDenomRequest) Descriptor added in v0.6.1

func (*ContractByDenomRequest) Descriptor() ([]byte, []int)

func (*ContractByDenomRequest) Marshal added in v0.6.1

func (m *ContractByDenomRequest) Marshal() (dAtA []byte, err error)

func (*ContractByDenomRequest) MarshalTo added in v0.6.1

func (m *ContractByDenomRequest) MarshalTo(dAtA []byte) (int, error)

func (*ContractByDenomRequest) MarshalToSizedBuffer added in v0.6.1

func (m *ContractByDenomRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*ContractByDenomRequest) ProtoMessage added in v0.6.1

func (*ContractByDenomRequest) ProtoMessage()

func (*ContractByDenomRequest) Reset added in v0.6.1

func (m *ContractByDenomRequest) Reset()

func (*ContractByDenomRequest) Size added in v0.6.1

func (m *ContractByDenomRequest) Size() (n int)

func (*ContractByDenomRequest) String added in v0.6.1

func (m *ContractByDenomRequest) String() string

func (*ContractByDenomRequest) Unmarshal added in v0.6.1

func (m *ContractByDenomRequest) Unmarshal(dAtA []byte) error

func (*ContractByDenomRequest) XXX_DiscardUnknown added in v0.6.1

func (m *ContractByDenomRequest) XXX_DiscardUnknown()

func (*ContractByDenomRequest) XXX_Marshal added in v0.6.1

func (m *ContractByDenomRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ContractByDenomRequest) XXX_Merge added in v0.6.1

func (m *ContractByDenomRequest) XXX_Merge(src proto.Message)

func (*ContractByDenomRequest) XXX_Size added in v0.6.1

func (m *ContractByDenomRequest) XXX_Size() int

func (*ContractByDenomRequest) XXX_Unmarshal added in v0.6.1

func (m *ContractByDenomRequest) XXX_Unmarshal(b []byte) error

type ContractByDenomResponse added in v0.6.1

type ContractByDenomResponse struct {
	Contract     string `protobuf:"bytes,1,opt,name=contract,proto3" json:"contract,omitempty"`
	AutoContract string `protobuf:"bytes,2,opt,name=auto_contract,json=autoContract,proto3" json:"auto_contract,omitempty"`
}

ContractByDenomRequest is the response type of ContractByDenom call

func (*ContractByDenomResponse) Descriptor added in v0.6.1

func (*ContractByDenomResponse) Descriptor() ([]byte, []int)

func (*ContractByDenomResponse) GetAutoContract added in v0.6.1

func (m *ContractByDenomResponse) GetAutoContract() string

func (*ContractByDenomResponse) GetContract added in v0.6.1

func (m *ContractByDenomResponse) GetContract() string

func (*ContractByDenomResponse) Marshal added in v0.6.1

func (m *ContractByDenomResponse) Marshal() (dAtA []byte, err error)

func (*ContractByDenomResponse) MarshalTo added in v0.6.1

func (m *ContractByDenomResponse) MarshalTo(dAtA []byte) (int, error)

func (*ContractByDenomResponse) MarshalToSizedBuffer added in v0.6.1

func (m *ContractByDenomResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*ContractByDenomResponse) ProtoMessage added in v0.6.1

func (*ContractByDenomResponse) ProtoMessage()

func (*ContractByDenomResponse) Reset added in v0.6.1

func (m *ContractByDenomResponse) Reset()

func (*ContractByDenomResponse) Size added in v0.6.1

func (m *ContractByDenomResponse) Size() (n int)

func (*ContractByDenomResponse) String added in v0.6.1

func (m *ContractByDenomResponse) String() string

func (*ContractByDenomResponse) Unmarshal added in v0.6.1

func (m *ContractByDenomResponse) Unmarshal(dAtA []byte) error

func (*ContractByDenomResponse) XXX_DiscardUnknown added in v0.6.1

func (m *ContractByDenomResponse) XXX_DiscardUnknown()

func (*ContractByDenomResponse) XXX_Marshal added in v0.6.1

func (m *ContractByDenomResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ContractByDenomResponse) XXX_Merge added in v0.6.1

func (m *ContractByDenomResponse) XXX_Merge(src proto.Message)

func (*ContractByDenomResponse) XXX_Size added in v0.6.1

func (m *ContractByDenomResponse) XXX_Size() int

func (*ContractByDenomResponse) XXX_Unmarshal added in v0.6.1

func (m *ContractByDenomResponse) XXX_Unmarshal(b []byte) error

type DenomByContractRequest added in v0.6.1

type DenomByContractRequest struct {
	Contract string `protobuf:"bytes,1,opt,name=contract,proto3" json:"contract,omitempty"`
}

DenomByContractRequest is the request type of DenomByContract call

func (*DenomByContractRequest) Descriptor added in v0.6.1

func (*DenomByContractRequest) Descriptor() ([]byte, []int)

func (*DenomByContractRequest) Marshal added in v0.6.1

func (m *DenomByContractRequest) Marshal() (dAtA []byte, err error)

func (*DenomByContractRequest) MarshalTo added in v0.6.1

func (m *DenomByContractRequest) MarshalTo(dAtA []byte) (int, error)

func (*DenomByContractRequest) MarshalToSizedBuffer added in v0.6.1

func (m *DenomByContractRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*DenomByContractRequest) ProtoMessage added in v0.6.1

func (*DenomByContractRequest) ProtoMessage()

func (*DenomByContractRequest) Reset added in v0.6.1

func (m *DenomByContractRequest) Reset()

func (*DenomByContractRequest) Size added in v0.6.1

func (m *DenomByContractRequest) Size() (n int)

func (*DenomByContractRequest) String added in v0.6.1

func (m *DenomByContractRequest) String() string

func (*DenomByContractRequest) Unmarshal added in v0.6.1

func (m *DenomByContractRequest) Unmarshal(dAtA []byte) error

func (*DenomByContractRequest) XXX_DiscardUnknown added in v0.6.1

func (m *DenomByContractRequest) XXX_DiscardUnknown()

func (*DenomByContractRequest) XXX_Marshal added in v0.6.1

func (m *DenomByContractRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*DenomByContractRequest) XXX_Merge added in v0.6.1

func (m *DenomByContractRequest) XXX_Merge(src proto.Message)

func (*DenomByContractRequest) XXX_Size added in v0.6.1

func (m *DenomByContractRequest) XXX_Size() int

func (*DenomByContractRequest) XXX_Unmarshal added in v0.6.1

func (m *DenomByContractRequest) XXX_Unmarshal(b []byte) error

type DenomByContractResponse added in v0.6.1

type DenomByContractResponse struct {
	Denom string `protobuf:"bytes,1,opt,name=denom,proto3" json:"denom,omitempty"`
}

DenomByContractResponse is the response type of DenomByContract call

func (*DenomByContractResponse) Descriptor added in v0.6.1

func (*DenomByContractResponse) Descriptor() ([]byte, []int)

func (*DenomByContractResponse) GetDenom added in v0.6.1

func (m *DenomByContractResponse) GetDenom() string

func (*DenomByContractResponse) Marshal added in v0.6.1

func (m *DenomByContractResponse) Marshal() (dAtA []byte, err error)

func (*DenomByContractResponse) MarshalTo added in v0.6.1

func (m *DenomByContractResponse) MarshalTo(dAtA []byte) (int, error)

func (*DenomByContractResponse) MarshalToSizedBuffer added in v0.6.1

func (m *DenomByContractResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*DenomByContractResponse) ProtoMessage added in v0.6.1

func (*DenomByContractResponse) ProtoMessage()

func (*DenomByContractResponse) Reset added in v0.6.1

func (m *DenomByContractResponse) Reset()

func (*DenomByContractResponse) Size added in v0.6.1

func (m *DenomByContractResponse) Size() (n int)

func (*DenomByContractResponse) String added in v0.6.1

func (m *DenomByContractResponse) String() string

func (*DenomByContractResponse) Unmarshal added in v0.6.1

func (m *DenomByContractResponse) Unmarshal(dAtA []byte) error

func (*DenomByContractResponse) XXX_DiscardUnknown added in v0.6.1

func (m *DenomByContractResponse) XXX_DiscardUnknown()

func (*DenomByContractResponse) XXX_Marshal added in v0.6.1

func (m *DenomByContractResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*DenomByContractResponse) XXX_Merge added in v0.6.1

func (m *DenomByContractResponse) XXX_Merge(src proto.Message)

func (*DenomByContractResponse) XXX_Size added in v0.6.1

func (m *DenomByContractResponse) XXX_Size() int

func (*DenomByContractResponse) XXX_Unmarshal added in v0.6.1

func (m *DenomByContractResponse) XXX_Unmarshal(b []byte) error

type DummyTracer added in v0.6.1

type DummyTracer struct{}

func NewDummyTracer added in v0.6.1

func NewDummyTracer() *DummyTracer

func (DummyTracer) CaptureEnd added in v0.6.1

func (dt DummyTracer) CaptureEnd(output []byte, gasUsed uint64, t time.Duration, err error)

func (DummyTracer) CaptureFault added in v0.6.1

func (dt DummyTracer) CaptureFault(env *vm.EVM, pc uint64, op vm.OpCode, gas, cost uint64, scope *vm.ScopeContext, depth int, err error)

func (DummyTracer) CaptureStart added in v0.6.1

func (dt DummyTracer) CaptureStart(env *vm.EVM, from common.Address, to common.Address, create bool, input []byte, gas uint64, value *big.Int)

func (DummyTracer) CaptureState added in v0.6.1

func (dt DummyTracer) CaptureState(env *vm.EVM, pc uint64, op vm.OpCode, gas, cost uint64, scope *vm.ScopeContext, rData []byte, depth int, err error)

type EvmKeeper added in v0.7.0

type EvmKeeper interface {
	GetNonce(ctx sdk.Context, addr common.Address) uint64
	ApplyMessage(ctx sdk.Context, msg core.Message, tracer vm.EVMLogger, commit bool) (*evmtypes.MsgEthereumTxResponse, error)
	GetParams(ctx sdk.Context) evmtypes.Params

	// to replay the messages
	EthereumTx(goCtx context.Context, msg *evmtypes.MsgEthereumTx) (*evmtypes.MsgEthereumTxResponse, error)
	DeductTxCostsFromUserBalance(
		ctx sdk.Context, msgEthTx evmtypes.MsgEthereumTx, txData evmtypes.TxData, denom string, homestead, istanbul, london bool,
	) (fees sdk.Coins, priority int64, err error)
	ChainID() *big.Int
}

EvmKeeper defines the interface for evm keeper

type EvmLogHandler added in v0.6.1

type EvmLogHandler interface {
	// Return the id of the log signature it handles
	EventID() common.Hash
	// Process the log
	Handle(ctx sdk.Context, contract common.Address, data []byte,
		addLogToReceipt func(contractAddress common.Address, logSig common.Hash, logData []byte)) error
}

EvmLogHandler defines the interface for evm log handler

type GenesisState

type GenesisState struct {
	// params defines all the paramaters of the module.
	Params            Params         `protobuf:"bytes,1,opt,name=params,proto3" json:"params"`
	ExternalContracts []TokenMapping `protobuf:"bytes,2,rep,name=external_contracts,json=externalContracts,proto3" json:"external_contracts"`
	AutoContracts     []TokenMapping `protobuf:"bytes,3,rep,name=auto_contracts,json=autoContracts,proto3" json:"auto_contracts"`
}

GenesisState defines the cronos module's genesis state.

func DefaultGenesis

func DefaultGenesis() *GenesisState

DefaultGenesis returns the default Capability genesis state

func (*GenesisState) Descriptor

func (*GenesisState) Descriptor() ([]byte, []int)

func (*GenesisState) GetAutoContracts added in v0.6.1

func (m *GenesisState) GetAutoContracts() []TokenMapping

func (*GenesisState) GetExternalContracts added in v0.6.1

func (m *GenesisState) GetExternalContracts() []TokenMapping

func (*GenesisState) GetParams added in v0.6.1

func (m *GenesisState) GetParams() Params

func (*GenesisState) Marshal

func (m *GenesisState) Marshal() (dAtA []byte, err error)

func (*GenesisState) MarshalTo

func (m *GenesisState) MarshalTo(dAtA []byte) (int, error)

func (*GenesisState) MarshalToSizedBuffer

func (m *GenesisState) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*GenesisState) ProtoMessage

func (*GenesisState) ProtoMessage()

func (*GenesisState) Reset

func (m *GenesisState) Reset()

func (*GenesisState) Size

func (m *GenesisState) Size() (n int)

func (*GenesisState) String

func (m *GenesisState) String() string

func (*GenesisState) Unmarshal

func (m *GenesisState) Unmarshal(dAtA []byte) error

func (GenesisState) Validate

func (gs GenesisState) Validate() error

Validate performs basic genesis state validation returning an error upon any failure.

func (*GenesisState) XXX_DiscardUnknown

func (m *GenesisState) XXX_DiscardUnknown()

func (*GenesisState) XXX_Marshal

func (m *GenesisState) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*GenesisState) XXX_Merge

func (m *GenesisState) XXX_Merge(src proto.Message)

func (*GenesisState) XXX_Size

func (m *GenesisState) XXX_Size() int

func (*GenesisState) XXX_Unmarshal

func (m *GenesisState) XXX_Unmarshal(b []byte) error

type GravityKeeper added in v0.7.0

type GravityKeeper interface {
	ERC20ToDenomLookup(ctx sdk.Context, tokenContract common.Address) (bool, string)
	IterateUnbatchedSendToEthereums(ctx sdk.Context, cb func(*gravitytypes.SendToEthereum) bool)
	GetParams(ctx sdk.Context) (params gravitytypes.Params)
}

GravityKeeper defines the expected gravity keeper interface

type MsgClient

type MsgClient interface {
	// ConvertVouchers defines a method for converting ibc voucher to cronos evm coins.
	ConvertVouchers(ctx context.Context, in *MsgConvertVouchers, opts ...grpc.CallOption) (*MsgConvertVouchersResponse, error)
	// TransferTokens defines a method to transfer cronos evm coins to another chain through IBC
	TransferTokens(ctx context.Context, in *MsgTransferTokens, opts ...grpc.CallOption) (*MsgTransferTokensResponse, error)
	// UpdateTokenMapping defines a method to update token mapping
	UpdateTokenMapping(ctx context.Context, in *MsgUpdateTokenMapping, opts ...grpc.CallOption) (*MsgUpdateTokenMappingResponse, error)
}

MsgClient is the client API for Msg service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.

func NewMsgClient

func NewMsgClient(cc grpc1.ClientConn) MsgClient

type MsgConvertVouchers added in v0.6.1

type MsgConvertVouchers struct {
	Address string                                   `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"`
	Coins   github_com_cosmos_cosmos_sdk_types.Coins `protobuf:"bytes,2,rep,name=coins,proto3,castrepeated=github.com/cosmos/cosmos-sdk/types.Coins" json:"coins"`
}

MsgConvertVouchers represents a message to convert ibc voucher coins to cronos evm coins.

func NewMsgConvertVouchers added in v0.6.1

func NewMsgConvertVouchers(address string, coins sdk.Coins) *MsgConvertVouchers

func (*MsgConvertVouchers) Descriptor added in v0.6.1

func (*MsgConvertVouchers) Descriptor() ([]byte, []int)

func (*MsgConvertVouchers) GetAddress added in v0.6.1

func (m *MsgConvertVouchers) GetAddress() string

func (*MsgConvertVouchers) GetCoins added in v0.6.1

func (*MsgConvertVouchers) GetSignBytes added in v0.6.1

func (msg *MsgConvertVouchers) GetSignBytes() []byte

GetSignBytes ...

func (*MsgConvertVouchers) GetSigners added in v0.6.1

func (msg *MsgConvertVouchers) GetSigners() []sdk.AccAddress

GetSigners ...

func (*MsgConvertVouchers) Marshal added in v0.6.1

func (m *MsgConvertVouchers) Marshal() (dAtA []byte, err error)

func (*MsgConvertVouchers) MarshalTo added in v0.6.1

func (m *MsgConvertVouchers) MarshalTo(dAtA []byte) (int, error)

func (*MsgConvertVouchers) MarshalToSizedBuffer added in v0.6.1

func (m *MsgConvertVouchers) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*MsgConvertVouchers) ProtoMessage added in v0.6.1

func (*MsgConvertVouchers) ProtoMessage()

func (*MsgConvertVouchers) Reset added in v0.6.1

func (m *MsgConvertVouchers) Reset()

func (MsgConvertVouchers) Route added in v0.6.1

func (msg MsgConvertVouchers) Route() string

Route ...

func (*MsgConvertVouchers) Size added in v0.6.1

func (m *MsgConvertVouchers) Size() (n int)

func (*MsgConvertVouchers) String added in v0.6.1

func (m *MsgConvertVouchers) String() string

func (MsgConvertVouchers) Type added in v0.6.1

func (msg MsgConvertVouchers) Type() string

Type ...

func (*MsgConvertVouchers) Unmarshal added in v0.6.1

func (m *MsgConvertVouchers) Unmarshal(dAtA []byte) error

func (*MsgConvertVouchers) ValidateBasic added in v0.6.1

func (msg *MsgConvertVouchers) ValidateBasic() error

ValidateBasic ...

func (*MsgConvertVouchers) XXX_DiscardUnknown added in v0.6.1

func (m *MsgConvertVouchers) XXX_DiscardUnknown()

func (*MsgConvertVouchers) XXX_Marshal added in v0.6.1

func (m *MsgConvertVouchers) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*MsgConvertVouchers) XXX_Merge added in v0.6.1

func (m *MsgConvertVouchers) XXX_Merge(src proto.Message)

func (*MsgConvertVouchers) XXX_Size added in v0.6.1

func (m *MsgConvertVouchers) XXX_Size() int

func (*MsgConvertVouchers) XXX_Unmarshal added in v0.6.1

func (m *MsgConvertVouchers) XXX_Unmarshal(b []byte) error

type MsgConvertVouchersResponse added in v0.6.1

type MsgConvertVouchersResponse struct {
}

MsgConvertVouchersResponse defines the ConvertVouchers response type.

func (*MsgConvertVouchersResponse) Descriptor added in v0.6.1

func (*MsgConvertVouchersResponse) Descriptor() ([]byte, []int)

func (*MsgConvertVouchersResponse) Marshal added in v0.6.1

func (m *MsgConvertVouchersResponse) Marshal() (dAtA []byte, err error)

func (*MsgConvertVouchersResponse) MarshalTo added in v0.6.1

func (m *MsgConvertVouchersResponse) MarshalTo(dAtA []byte) (int, error)

func (*MsgConvertVouchersResponse) MarshalToSizedBuffer added in v0.6.1

func (m *MsgConvertVouchersResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*MsgConvertVouchersResponse) ProtoMessage added in v0.6.1

func (*MsgConvertVouchersResponse) ProtoMessage()

func (*MsgConvertVouchersResponse) Reset added in v0.6.1

func (m *MsgConvertVouchersResponse) Reset()

func (*MsgConvertVouchersResponse) Size added in v0.6.1

func (m *MsgConvertVouchersResponse) Size() (n int)

func (*MsgConvertVouchersResponse) String added in v0.6.1

func (m *MsgConvertVouchersResponse) String() string

func (*MsgConvertVouchersResponse) Unmarshal added in v0.6.1

func (m *MsgConvertVouchersResponse) Unmarshal(dAtA []byte) error

func (*MsgConvertVouchersResponse) XXX_DiscardUnknown added in v0.6.1

func (m *MsgConvertVouchersResponse) XXX_DiscardUnknown()

func (*MsgConvertVouchersResponse) XXX_Marshal added in v0.6.1

func (m *MsgConvertVouchersResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*MsgConvertVouchersResponse) XXX_Merge added in v0.6.1

func (m *MsgConvertVouchersResponse) XXX_Merge(src proto.Message)

func (*MsgConvertVouchersResponse) XXX_Size added in v0.6.1

func (m *MsgConvertVouchersResponse) XXX_Size() int

func (*MsgConvertVouchersResponse) XXX_Unmarshal added in v0.6.1

func (m *MsgConvertVouchersResponse) XXX_Unmarshal(b []byte) error

type MsgServer

type MsgServer interface {
	// ConvertVouchers defines a method for converting ibc voucher to cronos evm coins.
	ConvertVouchers(context.Context, *MsgConvertVouchers) (*MsgConvertVouchersResponse, error)
	// TransferTokens defines a method to transfer cronos evm coins to another chain through IBC
	TransferTokens(context.Context, *MsgTransferTokens) (*MsgTransferTokensResponse, error)
	// UpdateTokenMapping defines a method to update token mapping
	UpdateTokenMapping(context.Context, *MsgUpdateTokenMapping) (*MsgUpdateTokenMappingResponse, error)
}

MsgServer is the server API for Msg service.

type MsgTransferTokens added in v0.6.1

type MsgTransferTokens struct {
	From  string                                   `protobuf:"bytes,1,opt,name=from,proto3" json:"from,omitempty"`
	To    string                                   `protobuf:"bytes,2,opt,name=to,proto3" json:"to,omitempty"`
	Coins github_com_cosmos_cosmos_sdk_types.Coins `protobuf:"bytes,3,rep,name=coins,proto3,castrepeated=github.com/cosmos/cosmos-sdk/types.Coins" json:"coins"`
}

MsgTransferTokens represents a message to transfer cronos evm coins through ibc.

func NewMsgTransferTokens added in v0.6.1

func NewMsgTransferTokens(from string, to string, coins sdk.Coins) *MsgTransferTokens

func (*MsgTransferTokens) Descriptor added in v0.6.1

func (*MsgTransferTokens) Descriptor() ([]byte, []int)

func (*MsgTransferTokens) GetCoins added in v0.6.1

func (*MsgTransferTokens) GetFrom added in v0.6.1

func (m *MsgTransferTokens) GetFrom() string

func (*MsgTransferTokens) GetSignBytes added in v0.6.1

func (msg *MsgTransferTokens) GetSignBytes() []byte

GetSignBytes ...

func (*MsgTransferTokens) GetSigners added in v0.6.1

func (msg *MsgTransferTokens) GetSigners() []sdk.AccAddress

GetSigners ...

func (*MsgTransferTokens) GetTo added in v0.6.1

func (m *MsgTransferTokens) GetTo() string

func (*MsgTransferTokens) Marshal added in v0.6.1

func (m *MsgTransferTokens) Marshal() (dAtA []byte, err error)

func (*MsgTransferTokens) MarshalTo added in v0.6.1

func (m *MsgTransferTokens) MarshalTo(dAtA []byte) (int, error)

func (*MsgTransferTokens) MarshalToSizedBuffer added in v0.6.1

func (m *MsgTransferTokens) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*MsgTransferTokens) ProtoMessage added in v0.6.1

func (*MsgTransferTokens) ProtoMessage()

func (*MsgTransferTokens) Reset added in v0.6.1

func (m *MsgTransferTokens) Reset()

func (MsgTransferTokens) Route added in v0.6.1

func (msg MsgTransferTokens) Route() string

Route ...

func (*MsgTransferTokens) Size added in v0.6.1

func (m *MsgTransferTokens) Size() (n int)

func (*MsgTransferTokens) String added in v0.6.1

func (m *MsgTransferTokens) String() string

func (MsgTransferTokens) Type added in v0.6.1

func (msg MsgTransferTokens) Type() string

Type ...

func (*MsgTransferTokens) Unmarshal added in v0.6.1

func (m *MsgTransferTokens) Unmarshal(dAtA []byte) error

func (*MsgTransferTokens) ValidateBasic added in v0.6.1

func (msg *MsgTransferTokens) ValidateBasic() error

ValidateBasic ...

func (*MsgTransferTokens) XXX_DiscardUnknown added in v0.6.1

func (m *MsgTransferTokens) XXX_DiscardUnknown()

func (*MsgTransferTokens) XXX_Marshal added in v0.6.1

func (m *MsgTransferTokens) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*MsgTransferTokens) XXX_Merge added in v0.6.1

func (m *MsgTransferTokens) XXX_Merge(src proto.Message)

func (*MsgTransferTokens) XXX_Size added in v0.6.1

func (m *MsgTransferTokens) XXX_Size() int

func (*MsgTransferTokens) XXX_Unmarshal added in v0.6.1

func (m *MsgTransferTokens) XXX_Unmarshal(b []byte) error

type MsgTransferTokensResponse added in v0.6.1

type MsgTransferTokensResponse struct {
}

MsgTransferTokensResponse defines the TransferTokens response type.

func (*MsgTransferTokensResponse) Descriptor added in v0.6.1

func (*MsgTransferTokensResponse) Descriptor() ([]byte, []int)

func (*MsgTransferTokensResponse) Marshal added in v0.6.1

func (m *MsgTransferTokensResponse) Marshal() (dAtA []byte, err error)

func (*MsgTransferTokensResponse) MarshalTo added in v0.6.1

func (m *MsgTransferTokensResponse) MarshalTo(dAtA []byte) (int, error)

func (*MsgTransferTokensResponse) MarshalToSizedBuffer added in v0.6.1

func (m *MsgTransferTokensResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*MsgTransferTokensResponse) ProtoMessage added in v0.6.1

func (*MsgTransferTokensResponse) ProtoMessage()

func (*MsgTransferTokensResponse) Reset added in v0.6.1

func (m *MsgTransferTokensResponse) Reset()

func (*MsgTransferTokensResponse) Size added in v0.6.1

func (m *MsgTransferTokensResponse) Size() (n int)

func (*MsgTransferTokensResponse) String added in v0.6.1

func (m *MsgTransferTokensResponse) String() string

func (*MsgTransferTokensResponse) Unmarshal added in v0.6.1

func (m *MsgTransferTokensResponse) Unmarshal(dAtA []byte) error

func (*MsgTransferTokensResponse) XXX_DiscardUnknown added in v0.6.1

func (m *MsgTransferTokensResponse) XXX_DiscardUnknown()

func (*MsgTransferTokensResponse) XXX_Marshal added in v0.6.1

func (m *MsgTransferTokensResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*MsgTransferTokensResponse) XXX_Merge added in v0.6.1

func (m *MsgTransferTokensResponse) XXX_Merge(src proto.Message)

func (*MsgTransferTokensResponse) XXX_Size added in v0.6.1

func (m *MsgTransferTokensResponse) XXX_Size() int

func (*MsgTransferTokensResponse) XXX_Unmarshal added in v0.6.1

func (m *MsgTransferTokensResponse) XXX_Unmarshal(b []byte) error

type MsgUpdateTokenMapping added in v0.6.1

type MsgUpdateTokenMapping struct {
	Sender   string `protobuf:"bytes,1,opt,name=sender,proto3" json:"sender,omitempty"`
	Denom    string `protobuf:"bytes,2,opt,name=denom,proto3" json:"denom,omitempty"`
	Contract string `protobuf:"bytes,3,opt,name=contract,proto3" json:"contract,omitempty"`
	// only when updating cronos (source) tokens
	Symbol  string `protobuf:"bytes,4,opt,name=symbol,proto3" json:"symbol,omitempty"`
	Decimal uint32 `protobuf:"varint,5,opt,name=decimal,proto3" json:"decimal,omitempty"`
}

MsgUpdateTokenMapping defines the request type

func NewMsgUpdateTokenMapping added in v0.6.1

func NewMsgUpdateTokenMapping(admin string, denom string, contract string, symbol string, decimal uint32) *MsgUpdateTokenMapping

NewMsgUpdateTokenMapping ...

func (*MsgUpdateTokenMapping) Descriptor added in v0.6.1

func (*MsgUpdateTokenMapping) Descriptor() ([]byte, []int)

func (*MsgUpdateTokenMapping) GetContract added in v0.6.1

func (m *MsgUpdateTokenMapping) GetContract() string

func (*MsgUpdateTokenMapping) GetDecimal added in v1.0.0

func (m *MsgUpdateTokenMapping) GetDecimal() uint32

func (*MsgUpdateTokenMapping) GetDenom added in v0.6.1

func (m *MsgUpdateTokenMapping) GetDenom() string

func (*MsgUpdateTokenMapping) GetSender added in v0.6.1

func (m *MsgUpdateTokenMapping) GetSender() string

func (*MsgUpdateTokenMapping) GetSignBytes added in v0.6.1

func (msg *MsgUpdateTokenMapping) GetSignBytes() []byte

GetSignBytes ...

func (*MsgUpdateTokenMapping) GetSigners added in v0.6.1

func (msg *MsgUpdateTokenMapping) GetSigners() []sdk.AccAddress

GetSigners ...

func (*MsgUpdateTokenMapping) GetSymbol added in v1.0.0

func (m *MsgUpdateTokenMapping) GetSymbol() string

func (*MsgUpdateTokenMapping) Marshal added in v0.6.1

func (m *MsgUpdateTokenMapping) Marshal() (dAtA []byte, err error)

func (*MsgUpdateTokenMapping) MarshalTo added in v0.6.1

func (m *MsgUpdateTokenMapping) MarshalTo(dAtA []byte) (int, error)

func (*MsgUpdateTokenMapping) MarshalToSizedBuffer added in v0.6.1

func (m *MsgUpdateTokenMapping) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*MsgUpdateTokenMapping) ProtoMessage added in v0.6.1

func (*MsgUpdateTokenMapping) ProtoMessage()

func (*MsgUpdateTokenMapping) Reset added in v0.6.1

func (m *MsgUpdateTokenMapping) Reset()

func (MsgUpdateTokenMapping) Route added in v0.6.1

func (msg MsgUpdateTokenMapping) Route() string

Route ...

func (*MsgUpdateTokenMapping) Size added in v0.6.1

func (m *MsgUpdateTokenMapping) Size() (n int)

func (*MsgUpdateTokenMapping) String added in v0.6.1

func (m *MsgUpdateTokenMapping) String() string

func (MsgUpdateTokenMapping) Type added in v0.6.1

func (msg MsgUpdateTokenMapping) Type() string

Type ...

func (*MsgUpdateTokenMapping) Unmarshal added in v0.6.1

func (m *MsgUpdateTokenMapping) Unmarshal(dAtA []byte) error

func (*MsgUpdateTokenMapping) ValidateBasic added in v0.6.1

func (msg *MsgUpdateTokenMapping) ValidateBasic() error

ValidateBasic ...

func (*MsgUpdateTokenMapping) XXX_DiscardUnknown added in v0.6.1

func (m *MsgUpdateTokenMapping) XXX_DiscardUnknown()

func (*MsgUpdateTokenMapping) XXX_Marshal added in v0.6.1

func (m *MsgUpdateTokenMapping) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*MsgUpdateTokenMapping) XXX_Merge added in v0.6.1

func (m *MsgUpdateTokenMapping) XXX_Merge(src proto.Message)

func (*MsgUpdateTokenMapping) XXX_Size added in v0.6.1

func (m *MsgUpdateTokenMapping) XXX_Size() int

func (*MsgUpdateTokenMapping) XXX_Unmarshal added in v0.6.1

func (m *MsgUpdateTokenMapping) XXX_Unmarshal(b []byte) error

type MsgUpdateTokenMappingResponse added in v0.6.1

type MsgUpdateTokenMappingResponse struct {
}

MsgUpdateTokenMappingResponse defines the response type

func (*MsgUpdateTokenMappingResponse) Descriptor added in v0.6.1

func (*MsgUpdateTokenMappingResponse) Descriptor() ([]byte, []int)

func (*MsgUpdateTokenMappingResponse) Marshal added in v0.6.1

func (m *MsgUpdateTokenMappingResponse) Marshal() (dAtA []byte, err error)

func (*MsgUpdateTokenMappingResponse) MarshalTo added in v0.6.1

func (m *MsgUpdateTokenMappingResponse) MarshalTo(dAtA []byte) (int, error)

func (*MsgUpdateTokenMappingResponse) MarshalToSizedBuffer added in v0.6.1

func (m *MsgUpdateTokenMappingResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*MsgUpdateTokenMappingResponse) ProtoMessage added in v0.6.1

func (*MsgUpdateTokenMappingResponse) ProtoMessage()

func (*MsgUpdateTokenMappingResponse) Reset added in v0.6.1

func (m *MsgUpdateTokenMappingResponse) Reset()

func (*MsgUpdateTokenMappingResponse) Size added in v0.6.1

func (m *MsgUpdateTokenMappingResponse) Size() (n int)

func (*MsgUpdateTokenMappingResponse) String added in v0.6.1

func (*MsgUpdateTokenMappingResponse) Unmarshal added in v0.6.1

func (m *MsgUpdateTokenMappingResponse) Unmarshal(dAtA []byte) error

func (*MsgUpdateTokenMappingResponse) XXX_DiscardUnknown added in v0.6.1

func (m *MsgUpdateTokenMappingResponse) XXX_DiscardUnknown()

func (*MsgUpdateTokenMappingResponse) XXX_Marshal added in v0.6.1

func (m *MsgUpdateTokenMappingResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*MsgUpdateTokenMappingResponse) XXX_Merge added in v0.6.1

func (m *MsgUpdateTokenMappingResponse) XXX_Merge(src proto.Message)

func (*MsgUpdateTokenMappingResponse) XXX_Size added in v0.6.1

func (m *MsgUpdateTokenMappingResponse) XXX_Size() int

func (*MsgUpdateTokenMappingResponse) XXX_Unmarshal added in v0.6.1

func (m *MsgUpdateTokenMappingResponse) XXX_Unmarshal(b []byte) error

type Params added in v0.6.1

type Params struct {
	IbcCroDenom string `` /* 127-byte string literal not displayed */
	IbcTimeout  uint64 `protobuf:"varint,2,opt,name=ibc_timeout,json=ibcTimeout,proto3" json:"ibc_timeout,omitempty"`
	// the admin address who can update token mapping
	CronosAdmin          string `protobuf:"bytes,3,opt,name=cronos_admin,json=cronosAdmin,proto3" json:"cronos_admin,omitempty"`
	EnableAutoDeployment bool   `protobuf:"varint,4,opt,name=enable_auto_deployment,json=enableAutoDeployment,proto3" json:"enable_auto_deployment,omitempty"`
}

Params defines the parameters for the cronos module.

func DefaultParams added in v0.6.1

func DefaultParams() Params

DefaultParams is the default parameter configuration for the cronos module

func NewParams added in v0.6.1

func NewParams(ibcCroDenom string, ibcTimeout uint64, cronosAdmin string, enableAutoDeployment bool) Params

NewParams creates a new parameter configuration for the cronos module

func (*Params) Descriptor added in v0.6.1

func (*Params) Descriptor() ([]byte, []int)

func (*Params) GetCronosAdmin added in v0.6.1

func (m *Params) GetCronosAdmin() string

func (*Params) GetEnableAutoDeployment added in v0.6.1

func (m *Params) GetEnableAutoDeployment() bool

func (*Params) GetIbcCroDenom added in v0.6.1

func (m *Params) GetIbcCroDenom() string

func (*Params) GetIbcTimeout added in v0.6.1

func (m *Params) GetIbcTimeout() uint64

func (*Params) Marshal added in v0.6.1

func (m *Params) Marshal() (dAtA []byte, err error)

func (*Params) MarshalTo added in v0.6.1

func (m *Params) MarshalTo(dAtA []byte) (int, error)

func (*Params) MarshalToSizedBuffer added in v0.6.1

func (m *Params) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*Params) ParamSetPairs added in v0.6.1

func (p *Params) ParamSetPairs() paramtypes.ParamSetPairs

ParamSetPairs implements params.ParamSet

func (*Params) ProtoMessage added in v0.6.1

func (*Params) ProtoMessage()

func (*Params) Reset added in v0.6.1

func (m *Params) Reset()

func (*Params) Size added in v0.6.1

func (m *Params) Size() (n int)

func (Params) String added in v0.6.1

func (p Params) String() string

String implements the fmt.Stringer interface

func (*Params) Unmarshal added in v0.6.1

func (m *Params) Unmarshal(dAtA []byte) error

func (Params) Validate added in v0.6.1

func (p Params) Validate() error

Validate all cronos module parameters

func (*Params) XXX_DiscardUnknown added in v0.6.1

func (m *Params) XXX_DiscardUnknown()

func (*Params) XXX_Marshal added in v0.6.1

func (m *Params) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Params) XXX_Merge added in v0.6.1

func (m *Params) XXX_Merge(src proto.Message)

func (*Params) XXX_Size added in v0.6.1

func (m *Params) XXX_Size() int

func (*Params) XXX_Unmarshal added in v0.6.1

func (m *Params) XXX_Unmarshal(b []byte) error

type QueryClient

type QueryClient interface {
	// ContractByDenom queries contract addresses by native denom
	ContractByDenom(ctx context.Context, in *ContractByDenomRequest, opts ...grpc.CallOption) (*ContractByDenomResponse, error)
	// DenomByContract queries native denom by contract address
	DenomByContract(ctx context.Context, in *DenomByContractRequest, opts ...grpc.CallOption) (*DenomByContractResponse, error)
	// ReplayBlock replay the eth messages in the block to recover the results of false-failed txs.
	ReplayBlock(ctx context.Context, in *ReplayBlockRequest, opts ...grpc.CallOption) (*ReplayBlockResponse, error)
}

QueryClient is the client API for Query service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.

func NewQueryClient

func NewQueryClient(cc grpc1.ClientConn) QueryClient

type QueryServer

type QueryServer interface {
	// ContractByDenom queries contract addresses by native denom
	ContractByDenom(context.Context, *ContractByDenomRequest) (*ContractByDenomResponse, error)
	// DenomByContract queries native denom by contract address
	DenomByContract(context.Context, *DenomByContractRequest) (*DenomByContractResponse, error)
	// ReplayBlock replay the eth messages in the block to recover the results of false-failed txs.
	ReplayBlock(context.Context, *ReplayBlockRequest) (*ReplayBlockResponse, error)
}

QueryServer is the server API for Query service.

type ReplayBlockRequest added in v0.6.10

type ReplayBlockRequest struct {
	// the eth messages in the block
	Msgs        []*types.MsgEthereumTx `protobuf:"bytes,1,rep,name=msgs,proto3" json:"msgs,omitempty"`
	BlockNumber int64                  `protobuf:"varint,2,opt,name=block_number,json=blockNumber,proto3" json:"block_number,omitempty"`
	BlockHash   string                 `protobuf:"bytes,3,opt,name=block_hash,json=blockHash,proto3" json:"block_hash,omitempty"`
	BlockTime   time.Time              `protobuf:"bytes,4,opt,name=block_time,json=blockTime,proto3,stdtime" json:"block_time"`
}

ReplayBlockRequest

func (*ReplayBlockRequest) Descriptor added in v0.6.10

func (*ReplayBlockRequest) Descriptor() ([]byte, []int)

func (*ReplayBlockRequest) Marshal added in v0.6.10

func (m *ReplayBlockRequest) Marshal() (dAtA []byte, err error)

func (*ReplayBlockRequest) MarshalTo added in v0.6.10

func (m *ReplayBlockRequest) MarshalTo(dAtA []byte) (int, error)

func (*ReplayBlockRequest) MarshalToSizedBuffer added in v0.6.10

func (m *ReplayBlockRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*ReplayBlockRequest) ProtoMessage added in v0.6.10

func (*ReplayBlockRequest) ProtoMessage()

func (*ReplayBlockRequest) Reset added in v0.6.10

func (m *ReplayBlockRequest) Reset()

func (*ReplayBlockRequest) Size added in v0.6.10

func (m *ReplayBlockRequest) Size() (n int)

func (*ReplayBlockRequest) String added in v0.6.10

func (m *ReplayBlockRequest) String() string

func (*ReplayBlockRequest) Unmarshal added in v0.6.10

func (m *ReplayBlockRequest) Unmarshal(dAtA []byte) error

func (ReplayBlockRequest) UnpackInterfaces added in v0.6.10

func (m ReplayBlockRequest) UnpackInterfaces(unpacker codectypes.AnyUnpacker) error

func (*ReplayBlockRequest) XXX_DiscardUnknown added in v0.6.10

func (m *ReplayBlockRequest) XXX_DiscardUnknown()

func (*ReplayBlockRequest) XXX_Marshal added in v0.6.10

func (m *ReplayBlockRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ReplayBlockRequest) XXX_Merge added in v0.6.10

func (m *ReplayBlockRequest) XXX_Merge(src proto.Message)

func (*ReplayBlockRequest) XXX_Size added in v0.6.10

func (m *ReplayBlockRequest) XXX_Size() int

func (*ReplayBlockRequest) XXX_Unmarshal added in v0.6.10

func (m *ReplayBlockRequest) XXX_Unmarshal(b []byte) error

type ReplayBlockResponse added in v0.6.10

type ReplayBlockResponse struct {
	Responses []*types.MsgEthereumTxResponse `protobuf:"bytes,1,rep,name=responses,proto3" json:"responses,omitempty"`
}

ReplayBlockResponse

func (*ReplayBlockResponse) Descriptor added in v0.6.10

func (*ReplayBlockResponse) Descriptor() ([]byte, []int)

func (*ReplayBlockResponse) GetResponses added in v0.6.10

func (m *ReplayBlockResponse) GetResponses() []*types.MsgEthereumTxResponse

func (*ReplayBlockResponse) Marshal added in v0.6.10

func (m *ReplayBlockResponse) Marshal() (dAtA []byte, err error)

func (*ReplayBlockResponse) MarshalTo added in v0.6.10

func (m *ReplayBlockResponse) MarshalTo(dAtA []byte) (int, error)

func (*ReplayBlockResponse) MarshalToSizedBuffer added in v0.6.10

func (m *ReplayBlockResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*ReplayBlockResponse) ProtoMessage added in v0.6.10

func (*ReplayBlockResponse) ProtoMessage()

func (*ReplayBlockResponse) Reset added in v0.6.10

func (m *ReplayBlockResponse) Reset()

func (*ReplayBlockResponse) Size added in v0.6.10

func (m *ReplayBlockResponse) Size() (n int)

func (*ReplayBlockResponse) String added in v0.6.10

func (m *ReplayBlockResponse) String() string

func (*ReplayBlockResponse) Unmarshal added in v0.6.10

func (m *ReplayBlockResponse) Unmarshal(dAtA []byte) error

func (*ReplayBlockResponse) XXX_DiscardUnknown added in v0.6.10

func (m *ReplayBlockResponse) XXX_DiscardUnknown()

func (*ReplayBlockResponse) XXX_Marshal added in v0.6.10

func (m *ReplayBlockResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ReplayBlockResponse) XXX_Merge added in v0.6.10

func (m *ReplayBlockResponse) XXX_Merge(src proto.Message)

func (*ReplayBlockResponse) XXX_Size added in v0.6.10

func (m *ReplayBlockResponse) XXX_Size() int

func (*ReplayBlockResponse) XXX_Unmarshal added in v0.6.10

func (m *ReplayBlockResponse) XXX_Unmarshal(b []byte) error

type TokenMapping added in v0.6.1

type TokenMapping struct {
	Denom    string `protobuf:"bytes,1,opt,name=denom,proto3" json:"denom,omitempty"`
	Contract string `protobuf:"bytes,2,opt,name=contract,proto3" json:"contract,omitempty"`
}

TokenMapping defines a mapping between native denom and contract

func (*TokenMapping) Descriptor added in v0.6.1

func (*TokenMapping) Descriptor() ([]byte, []int)

func (*TokenMapping) GetContract added in v0.6.1

func (m *TokenMapping) GetContract() string

func (*TokenMapping) GetDenom added in v0.6.1

func (m *TokenMapping) GetDenom() string

func (*TokenMapping) Marshal added in v0.6.1

func (m *TokenMapping) Marshal() (dAtA []byte, err error)

func (*TokenMapping) MarshalTo added in v0.6.1

func (m *TokenMapping) MarshalTo(dAtA []byte) (int, error)

func (*TokenMapping) MarshalToSizedBuffer added in v0.6.1

func (m *TokenMapping) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*TokenMapping) ProtoMessage added in v0.6.1

func (*TokenMapping) ProtoMessage()

func (*TokenMapping) Reset added in v0.6.1

func (m *TokenMapping) Reset()

func (*TokenMapping) Size added in v0.6.1

func (m *TokenMapping) Size() (n int)

func (*TokenMapping) String added in v0.6.1

func (m *TokenMapping) String() string

func (*TokenMapping) Unmarshal added in v0.6.1

func (m *TokenMapping) Unmarshal(dAtA []byte) error

func (*TokenMapping) XXX_DiscardUnknown added in v0.6.1

func (m *TokenMapping) XXX_DiscardUnknown()

func (*TokenMapping) XXX_Marshal added in v0.6.1

func (m *TokenMapping) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*TokenMapping) XXX_Merge added in v0.6.1

func (m *TokenMapping) XXX_Merge(src proto.Message)

func (*TokenMapping) XXX_Size added in v0.6.1

func (m *TokenMapping) XXX_Size() int

func (*TokenMapping) XXX_Unmarshal added in v0.6.1

func (m *TokenMapping) XXX_Unmarshal(b []byte) error

type TokenMappingChangeProposal added in v0.6.1

type TokenMappingChangeProposal struct {
	Title       string `protobuf:"bytes,1,opt,name=title,proto3" json:"title,omitempty"`
	Description string `protobuf:"bytes,2,opt,name=description,proto3" json:"description,omitempty"`
	Denom       string `protobuf:"bytes,3,opt,name=denom,proto3" json:"denom,omitempty"`
	Contract    string `protobuf:"bytes,4,opt,name=contract,proto3" json:"contract,omitempty"`
	// only when updating cronos (source) tokens
	Symbol  string `protobuf:"bytes,5,opt,name=symbol,proto3" json:"symbol,omitempty"`
	Decimal uint32 `protobuf:"varint,6,opt,name=decimal,proto3" json:"decimal,omitempty"`
}

TokenMappingChangeProposal defines a proposal to change one token mapping.

func NewTokenMappingChangeProposal added in v0.6.1

func NewTokenMappingChangeProposal(title, description, denom, symbol string, decimal uint32, contractAddr *common.Address) *TokenMappingChangeProposal

func (*TokenMappingChangeProposal) Descriptor added in v0.6.1

func (*TokenMappingChangeProposal) Descriptor() ([]byte, []int)

func (*TokenMappingChangeProposal) GetDescription added in v0.6.1

func (tcp *TokenMappingChangeProposal) GetDescription() string

GetDescription returns the description of a parameter change proposal.

func (*TokenMappingChangeProposal) GetTitle added in v0.6.1

func (tcp *TokenMappingChangeProposal) GetTitle() string

GetTitle returns the title of a parameter change proposal.

func (*TokenMappingChangeProposal) Marshal added in v0.6.1

func (m *TokenMappingChangeProposal) Marshal() (dAtA []byte, err error)

func (*TokenMappingChangeProposal) MarshalTo added in v0.6.1

func (m *TokenMappingChangeProposal) MarshalTo(dAtA []byte) (int, error)

func (*TokenMappingChangeProposal) MarshalToSizedBuffer added in v0.6.1

func (m *TokenMappingChangeProposal) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*TokenMappingChangeProposal) ProposalRoute added in v0.6.1

func (tcp *TokenMappingChangeProposal) ProposalRoute() string

ProposalRoute returns the routing key of a parameter change proposal.

func (*TokenMappingChangeProposal) ProposalType added in v0.6.1

func (tcp *TokenMappingChangeProposal) ProposalType() string

ProposalType returns the type of a parameter change proposal.

func (*TokenMappingChangeProposal) ProtoMessage added in v0.6.1

func (*TokenMappingChangeProposal) ProtoMessage()

func (*TokenMappingChangeProposal) Reset added in v0.6.1

func (m *TokenMappingChangeProposal) Reset()

func (*TokenMappingChangeProposal) Size added in v0.6.1

func (m *TokenMappingChangeProposal) Size() (n int)

func (TokenMappingChangeProposal) String added in v0.6.1

func (tcp TokenMappingChangeProposal) String() string

String implements the Stringer interface.

func (*TokenMappingChangeProposal) Unmarshal added in v0.6.1

func (m *TokenMappingChangeProposal) Unmarshal(dAtA []byte) error

func (*TokenMappingChangeProposal) ValidateBasic added in v0.6.1

func (tcp *TokenMappingChangeProposal) ValidateBasic() error

ValidateBasic validates the parameter change proposal

func (*TokenMappingChangeProposal) XXX_DiscardUnknown added in v0.6.1

func (m *TokenMappingChangeProposal) XXX_DiscardUnknown()

func (*TokenMappingChangeProposal) XXX_Marshal added in v0.6.1

func (m *TokenMappingChangeProposal) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*TokenMappingChangeProposal) XXX_Merge added in v0.6.1

func (m *TokenMappingChangeProposal) XXX_Merge(src proto.Message)

func (*TokenMappingChangeProposal) XXX_Size added in v0.6.1

func (m *TokenMappingChangeProposal) XXX_Size() int

func (*TokenMappingChangeProposal) XXX_Unmarshal added in v0.6.1

func (m *TokenMappingChangeProposal) XXX_Unmarshal(b []byte) error

type TransferKeeper added in v0.6.1

type TransferKeeper interface {
	SendTransfer(
		ctx sdk.Context,
		sourcePort,
		sourceChannel string,
		token sdk.Coin,
		sender sdk.AccAddress,
		receiver string,
		timeoutHeight clienttypes.Height,
		timeoutTimestamp uint64,
	) error
	GetDenomTrace(ctx sdk.Context, denomTraceHash tmbytes.HexBytes) (types.DenomTrace, bool)
}

TransferKeeper defines the expected interface needed to transfer coin through IBC.

type UnimplementedMsgServer

type UnimplementedMsgServer struct {
}

UnimplementedMsgServer can be embedded to have forward compatible implementations.

func (*UnimplementedMsgServer) ConvertVouchers added in v0.6.1

func (*UnimplementedMsgServer) TransferTokens added in v0.6.1

func (*UnimplementedMsgServer) UpdateTokenMapping added in v0.6.1

type UnimplementedQueryServer

type UnimplementedQueryServer struct {
}

UnimplementedQueryServer can be embedded to have forward compatible implementations.

func (*UnimplementedQueryServer) ContractByDenom added in v0.6.1

func (*UnimplementedQueryServer) DenomByContract added in v0.6.1

func (*UnimplementedQueryServer) ReplayBlock added in v0.6.10

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL