types

package
v0.5.0 Latest Latest
Warning

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

Go to latest
Published: Oct 3, 2024 License: Apache-2.0 Imports: 38 Imported by: 1

Documentation

Overview

Package types is a reverse proxy.

It translates gRPC into RESTful JSON APIs.

Index

Constants

View Source
const (
	// TypeUnrecognized means coin type is unrecognized
	TypeUnrecognized = iota
	// TypeGeneralMessage is a pure message
	TypeGeneralMessage
	// TypeGeneralMessageWithToken is a general message with token
	TypeGeneralMessageWithToken
	// TypeSendToken is a direct token transfer
	TypeSendToken
)
View Source
const (
	// ModuleName is the name of the gmp module
	ModuleName = "gmp"

	// StoreKey is the string store representation
	StoreKey = ModuleName

	// RouterKey is the message route
	RouterKey = ModuleName

	// QuerierRoute is the query router key for the gmp module
	QuerierRoute = ModuleName
)

Variables

View Source
var (
	ErrInvalidLengthAbci        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowAbci          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupAbci = fmt.Errorf("proto: unexpected end of group")
)
View Source
var (
	ErrInvalidDestinationChain = errors.Register(ModuleName, 1, "invalid destination chain")
	ErrEncodeInjVoteExt        = errors.Register(ModuleName, 2, "failed to encode injected vote extension tx")
	ErrNoCommitInfo            = errors.Register(ModuleName, 3, "no commit info")
)
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 (
	ErrInvalidLengthGmp        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowGmp          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupGmp = fmt.Errorf("proto: unexpected end of group")
)
View Source
var (
	ParamsKey        = []byte{0x01}
	PaymentKeyPrefix = []byte{0x02}
)

KVStore key prefixes

View Source
var (
	DefaultGMPAddress   = "axelar1dv4u5k73pzqrxlzujxg3qp8kvc3pje7jtdvu72npnt5zhq05ejcsn5qme5"
	DefaultChannel      = "channel-1"
	DefaultTimeout      = int64(1)
	DefaultFeeRecipient = "axelar1zl3rxpp70lmte2xr6c4lgske2fyuj3hupcsvcd"
	DefaultGasEstimate  = int64(1000000)
	EmptyByteSlice      = []byte{}
	EmptyContract       = "0x0000000000000000000000000000000000000000"
)
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 (

	// ModuleCdc references the global x/gmp module codec. Note, the codec should
	// ONLY be used in certain instances of tests and for JSON encoding as Amino is
	// still used for that purpose.
	//
	// The actual codec used for serialization should be provided to x/staking and
	// defined at the application level.
	ModuleCdc = codec.NewAminoCodec(amino)
)

Functions

func PaymentKey added in v0.5.0

func PaymentKey(originAddress string, denom string) (key []byte)

PaymentKey returns the store key for a payment

func RegisterInterfaces

func RegisterInterfaces(registry codectypes.InterfaceRegistry)

RegisterInterfaces registers the x/gmp interfaces types with the interface registry

func RegisterLegacyAminoCodec

func RegisterLegacyAminoCodec(cdc *codec.LegacyAmino)

RegisterLegacyAminoCodec registers the necessary x/gmp interfaces and concrete types on the provided LegacyAmino codec. These types are used for Amino JSON serialization.

func RegisterMsgServer

func RegisterMsgServer(s grpc1.Server, srv MsgServer)

func RegisterQueryHandler

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

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

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

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 AllPaymentsRequest added in v0.5.0

type AllPaymentsRequest struct {
}

AllPaymentsRequest is the request type for the Query/AllPayments RPC method.

func (*AllPaymentsRequest) Descriptor added in v0.5.0

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

func (*AllPaymentsRequest) Marshal added in v0.5.0

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

func (*AllPaymentsRequest) MarshalTo added in v0.5.0

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

func (*AllPaymentsRequest) MarshalToSizedBuffer added in v0.5.0

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

func (*AllPaymentsRequest) ProtoMessage added in v0.5.0

func (*AllPaymentsRequest) ProtoMessage()

func (*AllPaymentsRequest) Reset added in v0.5.0

func (m *AllPaymentsRequest) Reset()

func (*AllPaymentsRequest) Size added in v0.5.0

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

func (*AllPaymentsRequest) String added in v0.5.0

func (m *AllPaymentsRequest) String() string

func (*AllPaymentsRequest) Unmarshal added in v0.5.0

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

func (*AllPaymentsRequest) XXX_DiscardUnknown added in v0.5.0

func (m *AllPaymentsRequest) XXX_DiscardUnknown()

func (*AllPaymentsRequest) XXX_Marshal added in v0.5.0

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

func (*AllPaymentsRequest) XXX_Merge added in v0.5.0

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

func (*AllPaymentsRequest) XXX_Size added in v0.5.0

func (m *AllPaymentsRequest) XXX_Size() int

func (*AllPaymentsRequest) XXX_Unmarshal added in v0.5.0

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

type AllPaymentsResponse added in v0.5.0

type AllPaymentsResponse struct {
	Payments []Payment `protobuf:"bytes,1,rep,name=payments,proto3" json:"payments"`
}

AllPaymentsResponse is the response type for the Query/AllPayments RPC method.

func (*AllPaymentsResponse) Descriptor added in v0.5.0

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

func (*AllPaymentsResponse) GetPayments added in v0.5.0

func (m *AllPaymentsResponse) GetPayments() []Payment

func (*AllPaymentsResponse) Marshal added in v0.5.0

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

func (*AllPaymentsResponse) MarshalTo added in v0.5.0

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

func (*AllPaymentsResponse) MarshalToSizedBuffer added in v0.5.0

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

func (*AllPaymentsResponse) ProtoMessage added in v0.5.0

func (*AllPaymentsResponse) ProtoMessage()

func (*AllPaymentsResponse) Reset added in v0.5.0

func (m *AllPaymentsResponse) Reset()

func (*AllPaymentsResponse) Size added in v0.5.0

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

func (*AllPaymentsResponse) String added in v0.5.0

func (m *AllPaymentsResponse) String() string

func (*AllPaymentsResponse) Unmarshal added in v0.5.0

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

func (*AllPaymentsResponse) XXX_DiscardUnknown added in v0.5.0

func (m *AllPaymentsResponse) XXX_DiscardUnknown()

func (*AllPaymentsResponse) XXX_Marshal added in v0.5.0

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

func (*AllPaymentsResponse) XXX_Merge added in v0.5.0

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

func (*AllPaymentsResponse) XXX_Size added in v0.5.0

func (m *AllPaymentsResponse) XXX_Size() int

func (*AllPaymentsResponse) XXX_Unmarshal added in v0.5.0

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

type BankKeeper added in v0.5.0

type BankKeeper interface {
	GetBalance(ctx context.Context, addr sdk.AccAddress, denom string) sdk.Coin
	GetAllBalances(ctx context.Context, addr sdk.AccAddress) sdk.Coins
	SendCoinsFromModuleToModule(ctx context.Context, senderModule, recipientModule string, amt sdk.Coins) error
	GetDenomMetaData(ctx context.Context, denom string) (banktypes.Metadata, bool)
	SetDenomMetaData(ctx context.Context, denomMetaData banktypes.Metadata)
	SendCoinsFromAccountToModule(
		ctx context.Context,
		senderAddr sdk.AccAddress,
		recipientModule string,
		amt sdk.Coins,
	) error
	SendCoinsFromModuleToAccount(
		ctx context.Context,
		senderModule string,
		recipientAddr sdk.AccAddress,
		amt sdk.Coins,
	) error
}

type GasEstimateKeeper added in v0.5.0

type GasEstimateKeeper interface {
	GetParams(ctx sdk.Context) (params gasestimatetypes.Params)
	GetGasEstimate(ctx sdk.Context, network string) (gasestimatetypes.GasEstimate, error)
}

type GenesisState

type GenesisState struct {
	Params Params `protobuf:"bytes,1,opt,name=params,proto3" json:"params"`
}

GenesisState represents the genesis state of the gmp module.

func DefaultGenesisState

func DefaultGenesisState() *GenesisState

func NewGenesisState

func NewGenesisState(
	params Params,
) *GenesisState

func (*GenesisState) Descriptor

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

func (*GenesisState) GetParams

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) 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 GmpDecoder

type GmpDecoder struct {
	AssetNames      [][32]byte
	ContractAddress common.Address
	CommandSelector [4]byte
	CommandParams   []byte
	Timestamp       *big.Int
}

GmpDecoder is the payload sent from Axelar to IBC middleware. It needs to be decoded using the ABI.

func NewGmpDecoder

func NewGmpDecoder(payload []byte) (GmpDecoder, error)

NewGmpDecoder decodes a payload from GMP given a byte array

func (GmpDecoder) GetDenoms

func (g GmpDecoder) GetDenoms() []string

type GmpEncoder

type GmpEncoder struct {
	PriceData       []PriceData
	AssetNames      [][32]byte
	ContractAddress common.Address
	CommandSelector [4]byte
	CommandParams   []byte
}

GmpEncoder is the struct we use to encode the data we want to send to the GMP.

func NewGMPEncoder

func NewGMPEncoder(
	priceData []PriceData,
	assetName []string,
	contractAddress common.Address,
	commandSelector [4]byte,
	commandParams []byte,
) GmpEncoder

func (GmpEncoder) GMPEncode

func (g GmpEncoder) GMPEncode() ([]byte, error)

GMPEncode encodes the GMP data into a byte array.

type GmpFee

type GmpFee struct {
	// Fee amount
	Amount string `json:"amount"`
	// Recipient of fee; should be fee_recipient.
	Recipient string `json:"recipient"`
}

GMPFee defines the fee field message inside of GMPMessage.

type GmpMessage

type GmpMessage struct {
	// DestinationChain is the destination chain of the message
	DestinationChain string `json:"destination_chain"`
	// DestinationAddress is the destination address of the message
	DestinationAddress string `json:"destination_address"`
	// Payload is the encoded payload of the message (exchange rates)
	Payload []byte `json:"payload"`
	// Type is an enum that specifies the type of message
	Type int64 `json:"type"`
	// Fee is the fee paid to a relayer on the Axelar network
	Fee *GmpFee `json:"fee"`
}

GmpMessage defines the GMP message that we encode in the IBC memo field and send to Axelar.

Ref: https://github.com/axelarnetwork/evm-cosmos-gmp-sample

type GmpVoteExtension added in v0.5.0

type GmpVoteExtension struct {
	Height        int64 `protobuf:"varint,1,opt,name=height,proto3" json:"height,omitempty"`
	GasEstimation int64 `protobuf:"varint,2,opt,name=gas_estimation,json=gasEstimation,proto3" json:"gas_estimation,omitempty"`
}

GmpVoteExtension defines the vote extension structure used by the gmp module.

func (*GmpVoteExtension) Descriptor added in v0.5.0

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

func (*GmpVoteExtension) Marshal added in v0.5.0

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

func (*GmpVoteExtension) MarshalTo added in v0.5.0

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

func (*GmpVoteExtension) MarshalToSizedBuffer added in v0.5.0

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

func (*GmpVoteExtension) ProtoMessage added in v0.5.0

func (*GmpVoteExtension) ProtoMessage()

func (*GmpVoteExtension) Reset added in v0.5.0

func (m *GmpVoteExtension) Reset()

func (*GmpVoteExtension) Size added in v0.5.0

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

func (*GmpVoteExtension) String added in v0.5.0

func (m *GmpVoteExtension) String() string

func (*GmpVoteExtension) Unmarshal added in v0.5.0

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

func (*GmpVoteExtension) XXX_DiscardUnknown added in v0.5.0

func (m *GmpVoteExtension) XXX_DiscardUnknown()

func (*GmpVoteExtension) XXX_Marshal added in v0.5.0

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

func (*GmpVoteExtension) XXX_Merge added in v0.5.0

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

func (*GmpVoteExtension) XXX_Size added in v0.5.0

func (m *GmpVoteExtension) XXX_Size() int

func (*GmpVoteExtension) XXX_Unmarshal added in v0.5.0

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

type IBCTransferKeeper

type IBCTransferKeeper interface {
	Transfer(goCtx context.Context, msg *ibctransfertypes.MsgTransfer) (*ibctransfertypes.MsgTransferResponse, error)
}

type InjectedVoteExtensionTx added in v0.5.0

type InjectedVoteExtensionTx struct {
	MedianGasEstimation int64  `protobuf:"varint,1,opt,name=median_gas_estimation,json=medianGasEstimation,proto3" json:"median_gas_estimation,omitempty"`
	ExtendedCommitInfo  []byte `protobuf:"bytes,2,opt,name=extended_commit_info,json=extendedCommitInfo,proto3" json:"extended_commit_info,omitempty"`
}

InjectedVoteExtensionTx defines the vote extension tx injected by the prepare proposal handler.

func (*InjectedVoteExtensionTx) Descriptor added in v0.5.0

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

func (*InjectedVoteExtensionTx) Marshal added in v0.5.0

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

func (*InjectedVoteExtensionTx) MarshalTo added in v0.5.0

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

func (*InjectedVoteExtensionTx) MarshalToSizedBuffer added in v0.5.0

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

func (*InjectedVoteExtensionTx) ProtoMessage added in v0.5.0

func (*InjectedVoteExtensionTx) ProtoMessage()

func (*InjectedVoteExtensionTx) Reset added in v0.5.0

func (m *InjectedVoteExtensionTx) Reset()

func (*InjectedVoteExtensionTx) Size added in v0.5.0

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

func (*InjectedVoteExtensionTx) String added in v0.5.0

func (m *InjectedVoteExtensionTx) String() string

func (*InjectedVoteExtensionTx) Unmarshal added in v0.5.0

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

func (*InjectedVoteExtensionTx) XXX_DiscardUnknown added in v0.5.0

func (m *InjectedVoteExtensionTx) XXX_DiscardUnknown()

func (*InjectedVoteExtensionTx) XXX_Marshal added in v0.5.0

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

func (*InjectedVoteExtensionTx) XXX_Merge added in v0.5.0

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

func (*InjectedVoteExtensionTx) XXX_Size added in v0.5.0

func (m *InjectedVoteExtensionTx) XXX_Size() int

func (*InjectedVoteExtensionTx) XXX_Unmarshal added in v0.5.0

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

type MedianData

type MedianData struct {
	BlockNums  []*big.Int
	Medians    []*big.Int
	Deviations []*big.Int
}

MedianData is the struct that represents the MedianData tuple in Solidity.

func NewMedianData

func NewMedianData(medians oracletypes.PriceStamps, deviations oracletypes.PriceStamps) (MedianData, error)

NewMedianData creates a MedianData object of medians and deviations and their block numbers.

type MsgClient

type MsgClient interface {
	// SetParams sets the parameters for the gmp module.
	SetParams(ctx context.Context, in *MsgSetParams, opts ...grpc.CallOption) (*MsgSetParamsResponse, error)
	// Relay relays Ojo data via GMP.
	RelayPrice(ctx context.Context, in *MsgRelayPrice, opts ...grpc.CallOption) (*MsgRelayPriceResponse, error)
	// CreatePayment creates a payment to Axelar.
	CreatePayment(ctx context.Context, in *MsgCreatePayment, opts ...grpc.CallOption) (*MsgCreatePaymentResponse, 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 MsgCreatePayment added in v0.5.0

type MsgCreatePayment struct {
	// relayer is the address that signs the message.
	Relayer string `protobuf:"bytes,1,opt,name=relayer,proto3" json:"relayer,omitempty"`
	// payment defines the payment to create.
	Payment *Payment `protobuf:"bytes,2,opt,name=payment,proto3" json:"payment,omitempty"`
}

MsgRelay defines the Relay message type.

func NewMsgCreatePayment added in v0.5.0

func NewMsgCreatePayment(
	relayer string,
	destinationChain string,
	denom string,
	token sdk.Coin,
	deviation math.LegacyDec,
	heartbeat int64,
) *MsgCreatePayment

func (*MsgCreatePayment) Descriptor added in v0.5.0

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

func (*MsgCreatePayment) Marshal added in v0.5.0

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

func (*MsgCreatePayment) MarshalTo added in v0.5.0

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

func (*MsgCreatePayment) MarshalToSizedBuffer added in v0.5.0

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

func (*MsgCreatePayment) ProtoMessage added in v0.5.0

func (*MsgCreatePayment) ProtoMessage()

func (*MsgCreatePayment) Reset added in v0.5.0

func (m *MsgCreatePayment) Reset()

func (*MsgCreatePayment) Size added in v0.5.0

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

func (*MsgCreatePayment) String added in v0.5.0

func (m *MsgCreatePayment) String() string

func (MsgCreatePayment) Type added in v0.5.0

func (msg MsgCreatePayment) Type() string

Type implements LegacyMsg interface

func (*MsgCreatePayment) Unmarshal added in v0.5.0

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

func (MsgCreatePayment) ValidateBasic added in v0.5.0

func (msg MsgCreatePayment) ValidateBasic() error

ValidateBasic Implements sdk.Msg

func (*MsgCreatePayment) XXX_DiscardUnknown added in v0.5.0

func (m *MsgCreatePayment) XXX_DiscardUnknown()

func (*MsgCreatePayment) XXX_Marshal added in v0.5.0

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

func (*MsgCreatePayment) XXX_Merge added in v0.5.0

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

func (*MsgCreatePayment) XXX_Size added in v0.5.0

func (m *MsgCreatePayment) XXX_Size() int

func (*MsgCreatePayment) XXX_Unmarshal added in v0.5.0

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

type MsgCreatePaymentResponse added in v0.5.0

type MsgCreatePaymentResponse struct {
}

MsgRelay defines the Relay response type.

func (*MsgCreatePaymentResponse) Descriptor added in v0.5.0

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

func (*MsgCreatePaymentResponse) Marshal added in v0.5.0

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

func (*MsgCreatePaymentResponse) MarshalTo added in v0.5.0

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

func (*MsgCreatePaymentResponse) MarshalToSizedBuffer added in v0.5.0

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

func (*MsgCreatePaymentResponse) ProtoMessage added in v0.5.0

func (*MsgCreatePaymentResponse) ProtoMessage()

func (*MsgCreatePaymentResponse) Reset added in v0.5.0

func (m *MsgCreatePaymentResponse) Reset()

func (*MsgCreatePaymentResponse) Size added in v0.5.0

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

func (*MsgCreatePaymentResponse) String added in v0.5.0

func (m *MsgCreatePaymentResponse) String() string

func (*MsgCreatePaymentResponse) Unmarshal added in v0.5.0

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

func (*MsgCreatePaymentResponse) XXX_DiscardUnknown added in v0.5.0

func (m *MsgCreatePaymentResponse) XXX_DiscardUnknown()

func (*MsgCreatePaymentResponse) XXX_Marshal added in v0.5.0

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

func (*MsgCreatePaymentResponse) XXX_Merge added in v0.5.0

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

func (*MsgCreatePaymentResponse) XXX_Size added in v0.5.0

func (m *MsgCreatePaymentResponse) XXX_Size() int

func (*MsgCreatePaymentResponse) XXX_Unmarshal added in v0.5.0

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

type MsgRelayPrice

type MsgRelayPrice struct {
	// authority is the address that signs the message.
	Relayer string `protobuf:"bytes,1,opt,name=relayer,proto3" json:"relayer,omitempty"`
	// destination_chain defines the chain which this will be relayed to.
	DestinationChain string `protobuf:"bytes,2,opt,name=destination_chain,json=destinationChain,proto3" json:"destination_chain,omitempty"`
	// ojo_contract_address defines the ojo contract that GMP is calling.
	OjoContractAddress string `protobuf:"bytes,3,opt,name=ojo_contract_address,json=ojoContractAddress,proto3" json:"ojo_contract_address,omitempty"`
	// client_contract_address defines the client contract that Ojo is calling.
	ClientContractAddress string `` /* 126-byte string literal not displayed */
	// denoms defines the denoms that the user wants to relay via GMP.
	Denoms []string `protobuf:"bytes,5,rep,name=denoms,proto3" json:"denoms,omitempty"`
	// token determines the IBC token that the user wants to relay via GMP.
	Token types.Coin `protobuf:"bytes,6,opt,name=token,proto3,castrepeated=github.com/cosmos/cosmos-sdk/types.Coins" json:"token"`
	// command_selector defines the command to call.
	CommandSelector []byte `protobuf:"bytes,7,opt,name=command_selector,json=commandSelector,proto3" json:"command_selector,omitempty"`
	// command_params defines the command parameters to call.
	CommandParams []byte `protobuf:"bytes,8,opt,name=command_params,json=commandParams,proto3" json:"command_params,omitempty"`
	// timestamp defines the timestamp of the message in terms of the source evm chain block time.
	Timestamp int64 `protobuf:"varint,9,opt,name=timestamp,proto3" json:"timestamp,omitempty"`
}

MsgRelay defines the Relay message type.

func NewMsgRelay

func NewMsgRelay(
	relayer string,
	destinationChain string,
	ojoContractAddress string,
	clientContractAddress string,
	token sdk.Coin,
	denoms []string,
	commandSelector []byte,
	commandParams []byte,
	timestamp int64,
) *MsgRelayPrice

func (*MsgRelayPrice) Descriptor

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

func (MsgRelayPrice) GetSigners

func (msg MsgRelayPrice) GetSigners() []sdk.AccAddress

GetSigners implements sdk.Msg

func (*MsgRelayPrice) Marshal

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

func (*MsgRelayPrice) MarshalTo

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

func (*MsgRelayPrice) MarshalToSizedBuffer

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

func (MsgRelayPrice) MsgCreatePayment added in v0.5.0

func (msg MsgRelayPrice) MsgCreatePayment() []sdk.AccAddress

GetSigners implements sdk.Msg

func (*MsgRelayPrice) ProtoMessage

func (*MsgRelayPrice) ProtoMessage()

func (*MsgRelayPrice) Reset

func (m *MsgRelayPrice) Reset()

func (*MsgRelayPrice) Size

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

func (*MsgRelayPrice) String

func (m *MsgRelayPrice) String() string

func (MsgRelayPrice) Type

func (msg MsgRelayPrice) Type() string

Type implements LegacyMsg interface

func (*MsgRelayPrice) Unmarshal

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

func (MsgRelayPrice) ValidateBasic

func (msg MsgRelayPrice) ValidateBasic() error

ValidateBasic Implements sdk.Msg

func (*MsgRelayPrice) XXX_DiscardUnknown

func (m *MsgRelayPrice) XXX_DiscardUnknown()

func (*MsgRelayPrice) XXX_Marshal

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

func (*MsgRelayPrice) XXX_Merge

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

func (*MsgRelayPrice) XXX_Size

func (m *MsgRelayPrice) XXX_Size() int

func (*MsgRelayPrice) XXX_Unmarshal

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

type MsgRelayPriceResponse

type MsgRelayPriceResponse struct {
}

MsgRelay defines the Relay response type.

func (*MsgRelayPriceResponse) Descriptor

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

func (*MsgRelayPriceResponse) Marshal

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

func (*MsgRelayPriceResponse) MarshalTo

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

func (*MsgRelayPriceResponse) MarshalToSizedBuffer

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

func (*MsgRelayPriceResponse) ProtoMessage

func (*MsgRelayPriceResponse) ProtoMessage()

func (*MsgRelayPriceResponse) Reset

func (m *MsgRelayPriceResponse) Reset()

func (*MsgRelayPriceResponse) Size

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

func (*MsgRelayPriceResponse) String

func (m *MsgRelayPriceResponse) String() string

func (*MsgRelayPriceResponse) Unmarshal

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

func (*MsgRelayPriceResponse) XXX_DiscardUnknown

func (m *MsgRelayPriceResponse) XXX_DiscardUnknown()

func (*MsgRelayPriceResponse) XXX_Marshal

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

func (*MsgRelayPriceResponse) XXX_Merge

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

func (*MsgRelayPriceResponse) XXX_Size

func (m *MsgRelayPriceResponse) XXX_Size() int

func (*MsgRelayPriceResponse) XXX_Unmarshal

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

type MsgServer

type MsgServer interface {
	// SetParams sets the parameters for the gmp module.
	SetParams(context.Context, *MsgSetParams) (*MsgSetParamsResponse, error)
	// Relay relays Ojo data via GMP.
	RelayPrice(context.Context, *MsgRelayPrice) (*MsgRelayPriceResponse, error)
	// CreatePayment creates a payment to Axelar.
	CreatePayment(context.Context, *MsgCreatePayment) (*MsgCreatePaymentResponse, error)
}

MsgServer is the server API for Msg service.

type MsgSetParams

type MsgSetParams struct {
	// authority is the address that controls the module (defaults to x/gov unless overwritten).
	Authority string `protobuf:"bytes,1,opt,name=authority,proto3" json:"authority,omitempty"`
	// params defines the gmp parameters to update.
	Params *Params `protobuf:"bytes,2,opt,name=params,proto3" json:"params,omitempty"`
}

MsgSetParams defines the SetParams message type.

func NewMsgSetParams

func NewMsgSetParams(
	gmpAddress string,
	gmpChannel string,
	gmpTimeout int64,
	feeRecipient string,
	govAddress string,
	defaultGasEstimate int64,
) *MsgSetParams

func (*MsgSetParams) Descriptor

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

func (MsgSetParams) GetSigners

func (msg MsgSetParams) GetSigners() []sdk.AccAddress

GetSigners implements sdk.Msg

func (*MsgSetParams) Marshal

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

func (*MsgSetParams) MarshalTo

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

func (*MsgSetParams) MarshalToSizedBuffer

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

func (*MsgSetParams) ProtoMessage

func (*MsgSetParams) ProtoMessage()

func (*MsgSetParams) Reset

func (m *MsgSetParams) Reset()

func (*MsgSetParams) Size

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

func (*MsgSetParams) String

func (m *MsgSetParams) String() string

func (MsgSetParams) Type

func (msg MsgSetParams) Type() string

Type implements LegacyMsg interface

func (*MsgSetParams) Unmarshal

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

func (MsgSetParams) ValidateBasic

func (msg MsgSetParams) ValidateBasic() error

ValidateBasic Implements sdk.Msg

func (*MsgSetParams) XXX_DiscardUnknown

func (m *MsgSetParams) XXX_DiscardUnknown()

func (*MsgSetParams) XXX_Marshal

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

func (*MsgSetParams) XXX_Merge

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

func (*MsgSetParams) XXX_Size

func (m *MsgSetParams) XXX_Size() int

func (*MsgSetParams) XXX_Unmarshal

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

type MsgSetParamsResponse

type MsgSetParamsResponse struct {
}

MsgSetParamsResponse defines the SetParams response type.

func (*MsgSetParamsResponse) Descriptor

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

func (*MsgSetParamsResponse) Marshal

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

func (*MsgSetParamsResponse) MarshalTo

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

func (*MsgSetParamsResponse) MarshalToSizedBuffer

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

func (*MsgSetParamsResponse) ProtoMessage

func (*MsgSetParamsResponse) ProtoMessage()

func (*MsgSetParamsResponse) Reset

func (m *MsgSetParamsResponse) Reset()

func (*MsgSetParamsResponse) Size

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

func (*MsgSetParamsResponse) String

func (m *MsgSetParamsResponse) String() string

func (*MsgSetParamsResponse) Unmarshal

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

func (*MsgSetParamsResponse) XXX_DiscardUnknown

func (m *MsgSetParamsResponse) XXX_DiscardUnknown()

func (*MsgSetParamsResponse) XXX_Marshal

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

func (*MsgSetParamsResponse) XXX_Merge

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

func (*MsgSetParamsResponse) XXX_Size

func (m *MsgSetParamsResponse) XXX_Size() int

func (*MsgSetParamsResponse) XXX_Unmarshal

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

type OracleKeeper

type OracleKeeper interface {
	GetExchangeRate(ctx sdk.Context, symbol string) (math.LegacyDec, error)
	GetExponent(ctx sdk.Context, denom string) (uint32, error)
	MaximumMedianStamps(ctx sdk.Context) uint64
	HistoricMedians(ctx sdk.Context, denom string, numStamps uint64) oracletypes.PriceStamps
	HistoricDeviations(ctx sdk.Context, denom string, numStamps uint64) oracletypes.PriceStamps
}

OracleKeeper defines the expected Oracle interface that is needed by the gmp module.

type Params

type Params struct {
	// The axelar address that we'll send IBC transactions to.
	GmpAddress string `protobuf:"bytes,1,opt,name=gmp_address,json=gmpAddress,proto3" json:"gmp_address,omitempty"`
	// The channel over which we communicate with axelar.
	GmpChannel string `protobuf:"bytes,2,opt,name=gmp_channel,json=gmpChannel,proto3" json:"gmp_channel,omitempty"`
	// The amount of time we'll wait for a response from axelar before timing out.
	GmpTimeout int64 `protobuf:"varint,3,opt,name=gmp_timeout,json=gmpTimeout,proto3" json:"gmp_timeout,omitempty"`
	// The axelar address of the fee recipient.
	FeeRecipient       string `protobuf:"bytes,4,opt,name=fee_recipient,json=feeRecipient,proto3" json:"fee_recipient,omitempty"`
	DefaultGasEstimate int64  `protobuf:"varint,5,opt,name=default_gas_estimate,json=defaultGasEstimate,proto3" json:"default_gas_estimate,omitempty"`
}

Params defines the parameters for the gmp module.

func DefaultParams

func DefaultParams() Params

func (*Params) Descriptor

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

func (*Params) Marshal

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

func (*Params) MarshalTo

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

func (*Params) MarshalToSizedBuffer

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

func (*Params) ProtoMessage

func (*Params) ProtoMessage()

func (*Params) Reset

func (m *Params) Reset()

func (*Params) Size

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

func (*Params) String

func (m *Params) String() string

func (*Params) Unmarshal

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

func (Params) Validate

func (p Params) Validate() error

func (*Params) XXX_DiscardUnknown

func (m *Params) XXX_DiscardUnknown()

func (*Params) XXX_Marshal

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

func (*Params) XXX_Merge

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

func (*Params) XXX_Size

func (m *Params) XXX_Size() int

func (*Params) XXX_Unmarshal

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

type ParamsRequest

type ParamsRequest struct {
}

ParamsRequest is the request type for the Query/Params RPC method.

func (*ParamsRequest) Descriptor

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

func (*ParamsRequest) Marshal

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

func (*ParamsRequest) MarshalTo

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

func (*ParamsRequest) MarshalToSizedBuffer

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

func (*ParamsRequest) ProtoMessage

func (*ParamsRequest) ProtoMessage()

func (*ParamsRequest) Reset

func (m *ParamsRequest) Reset()

func (*ParamsRequest) Size

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

func (*ParamsRequest) String

func (m *ParamsRequest) String() string

func (*ParamsRequest) Unmarshal

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

func (*ParamsRequest) XXX_DiscardUnknown

func (m *ParamsRequest) XXX_DiscardUnknown()

func (*ParamsRequest) XXX_Marshal

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

func (*ParamsRequest) XXX_Merge

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

func (*ParamsRequest) XXX_Size

func (m *ParamsRequest) XXX_Size() int

func (*ParamsRequest) XXX_Unmarshal

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

type ParamsResponse

type ParamsResponse struct {
	// params defines the parameters of the module.
	Params Params `protobuf:"bytes,1,opt,name=params,proto3" json:"params"`
}

ParamsResponse is the response type for the Query/Params RPC method.

func (*ParamsResponse) Descriptor

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

func (*ParamsResponse) GetParams

func (m *ParamsResponse) GetParams() Params

func (*ParamsResponse) Marshal

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

func (*ParamsResponse) MarshalTo

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

func (*ParamsResponse) MarshalToSizedBuffer

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

func (*ParamsResponse) ProtoMessage

func (*ParamsResponse) ProtoMessage()

func (*ParamsResponse) Reset

func (m *ParamsResponse) Reset()

func (*ParamsResponse) Size

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

func (*ParamsResponse) String

func (m *ParamsResponse) String() string

func (*ParamsResponse) Unmarshal

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

func (*ParamsResponse) XXX_DiscardUnknown

func (m *ParamsResponse) XXX_DiscardUnknown()

func (*ParamsResponse) XXX_Marshal

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

func (*ParamsResponse) XXX_Merge

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

func (*ParamsResponse) XXX_Size

func (m *ParamsResponse) XXX_Size() int

func (*ParamsResponse) XXX_Unmarshal

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

type Payment added in v0.5.0

type Payment struct {
	// relayer is the address that signs the message.
	Relayer string `protobuf:"bytes,1,opt,name=relayer,proto3" json:"relayer,omitempty"`
	// destination_chain defines the chain which this will be relayed to.
	DestinationChain string `protobuf:"bytes,2,opt,name=destination_chain,json=destinationChain,proto3" json:"destination_chain,omitempty"`
	// denom defines the price feed denom to be relayed to the contract
	Denom string `protobuf:"bytes,3,opt,name=denom,proto3" json:"denom,omitempty"`
	// token determines the IBC token that will be used for payment to Axelar.
	Token types.Coin `protobuf:"bytes,4,opt,name=token,proto3,castrepeated=github.com/cosmos/cosmos-sdk/types.Coins" json:"token"`
	// deviation is a percentage of how much the price can deviate before triggering an update.
	// 100 = 100%.
	Deviation cosmossdk_io_math.LegacyDec `protobuf:"bytes,5,opt,name=deviation,proto3,customtype=cosmossdk.io/math.LegacyDec" json:"deviation" yaml:"deviation"`
	// heartbeat is how often the price will be updated in Ojo blocks, regardless of whether the price has deviated or not.
	Heartbeat int64 `protobuf:"varint,6,opt,name=heartbeat,proto3" json:"heartbeat,omitempty"`
	// last_price is the last price that was sent to the smart contract..
	LastPrice cosmossdk_io_math.LegacyDec `` /* 135-byte string literal not displayed */
	// last_block is the last Ojo block at which the price was pushed.
	LastBlock int64 `protobuf:"varint,8,opt,name=last_block,json=lastBlock,proto3" json:"last_block,omitempty"`
}

Payment is a data structure that holds information about a payment that has beenn made.

func (*Payment) Descriptor added in v0.5.0

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

func (*Payment) Marshal added in v0.5.0

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

func (*Payment) MarshalTo added in v0.5.0

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

func (*Payment) MarshalToSizedBuffer added in v0.5.0

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

func (*Payment) ProtoMessage added in v0.5.0

func (*Payment) ProtoMessage()

func (*Payment) Reset added in v0.5.0

func (m *Payment) Reset()

func (*Payment) Size added in v0.5.0

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

func (*Payment) String added in v0.5.0

func (m *Payment) String() string

func (Payment) TriggerUpdate added in v0.5.0

func (p Payment) TriggerUpdate(rate math.LegacyDec, ctx sdk.Context) bool

func (*Payment) Unmarshal added in v0.5.0

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

func (*Payment) XXX_DiscardUnknown added in v0.5.0

func (m *Payment) XXX_DiscardUnknown()

func (*Payment) XXX_Marshal added in v0.5.0

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

func (*Payment) XXX_Merge added in v0.5.0

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

func (*Payment) XXX_Size added in v0.5.0

func (m *Payment) XXX_Size() int

func (*Payment) XXX_Unmarshal added in v0.5.0

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

type PriceData

type PriceData struct {
	AssetName   [32]byte
	Price       *big.Int
	ResolveTime *big.Int
	MedianData  MedianData
}

PriceData is the struct that represents the PriceData tuple in Solidity.

func NewPriceData

func NewPriceData(
	assetName string,
	price math.LegacyDec,
	resolveTime *big.Int,
	medianData MedianData,
) (PriceData, error)

type QueryClient

type QueryClient interface {
	// Params queries all parameters.
	Params(ctx context.Context, in *ParamsRequest, opts ...grpc.CallOption) (*ParamsResponse, error)
	// AllPayments queries all payments.
	AllPayments(ctx context.Context, in *AllPaymentsRequest, opts ...grpc.CallOption) (*AllPaymentsResponse, 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 {
	// Params queries all parameters.
	Params(context.Context, *ParamsRequest) (*ParamsResponse, error)
	// AllPayments queries all payments.
	AllPayments(context.Context, *AllPaymentsRequest) (*AllPaymentsResponse, error)
}

QueryServer is the server API for Query service.

type UnimplementedMsgServer

type UnimplementedMsgServer struct {
}

UnimplementedMsgServer can be embedded to have forward compatible implementations.

func (*UnimplementedMsgServer) CreatePayment added in v0.5.0

func (*UnimplementedMsgServer) RelayPrice

func (*UnimplementedMsgServer) SetParams

type UnimplementedQueryServer

type UnimplementedQueryServer struct {
}

UnimplementedQueryServer can be embedded to have forward compatible implementations.

func (*UnimplementedQueryServer) AllPayments added in v0.5.0

func (*UnimplementedQueryServer) Params

Jump to

Keyboard shortcuts

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