Documentation ¶
Index ¶
- Constants
- Variables
- func RegisterInterfaces(registry types.InterfaceRegistry)
- func RegisterLegacyAminoCodec(cdc *codec.LegacyAmino)
- func RegisterMsgServer(s grpc1.Server, srv MsgServer)
- type AccountKeeper
- type MsgClient
- type MsgLockedSend
- func (*MsgLockedSend) Descriptor() ([]byte, []int)
- func (m MsgLockedSend) GetSignBytes() []byte
- func (m MsgLockedSend) GetSigners() []sdk.AccAddress
- func (m *MsgLockedSend) Marshal() (dAtA []byte, err error)
- func (m *MsgLockedSend) MarshalTo(dAtA []byte) (int, error)
- func (m *MsgLockedSend) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*MsgLockedSend) ProtoMessage()
- func (m *MsgLockedSend) Reset()
- func (m MsgLockedSend) Route() string
- func (m *MsgLockedSend) Size() (n int)
- func (m *MsgLockedSend) String() string
- func (m MsgLockedSend) Type() string
- func (m *MsgLockedSend) Unmarshal(dAtA []byte) error
- func (m MsgLockedSend) ValidateBasic() error
- func (m *MsgLockedSend) XXX_DiscardUnknown()
- func (m *MsgLockedSend) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *MsgLockedSend) XXX_Merge(src proto.Message)
- func (m *MsgLockedSend) XXX_Size() int
- func (m *MsgLockedSend) XXX_Unmarshal(b []byte) error
- type MsgLockedSendResponse
- func (*MsgLockedSendResponse) Descriptor() ([]byte, []int)
- func (m *MsgLockedSendResponse) Marshal() (dAtA []byte, err error)
- func (m *MsgLockedSendResponse) MarshalTo(dAtA []byte) (int, error)
- func (m *MsgLockedSendResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*MsgLockedSendResponse) ProtoMessage()
- func (m *MsgLockedSendResponse) Reset()
- func (m *MsgLockedSendResponse) Size() (n int)
- func (m *MsgLockedSendResponse) String() string
- func (m *MsgLockedSendResponse) Unmarshal(dAtA []byte) error
- func (m *MsgLockedSendResponse) XXX_DiscardUnknown()
- func (m *MsgLockedSendResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *MsgLockedSendResponse) XXX_Merge(src proto.Message)
- func (m *MsgLockedSendResponse) XXX_Size() int
- func (m *MsgLockedSendResponse) XXX_Unmarshal(b []byte) error
- type MsgServer
- type UnimplementedMsgServer
Constants ¶
const ( EventTypeLockedSendToVestingAccount = "locked_send_to_vesting_account" AttributeKeyUnlocker = "unlocker" )
const (
TypeMsgLockedSend = "locked_send"
)
TypeMsgLockedSend bank message types
Variables ¶
var ( ErrInvalidLengthTx = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowTx = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupTx = fmt.Errorf("proto: unexpected end of group") )
var ( // ModuleCdc references the global x/bank 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 RegisterInterfaces ¶
func RegisterInterfaces(registry types.InterfaceRegistry)
func RegisterLegacyAminoCodec ¶
func RegisterLegacyAminoCodec(cdc *codec.LegacyAmino)
func RegisterMsgServer ¶
Types ¶
type AccountKeeper ¶
type AccountKeeper interface { AddressCodec() address.Codec NewAccount(context.Context, sdk.AccountI) sdk.AccountI NewAccountWithAddress(ctx context.Context, addr sdk.AccAddress) sdk.AccountI GetAccount(ctx context.Context, addr sdk.AccAddress) sdk.AccountI GetAllAccounts(ctx context.Context) []sdk.AccountI HasAccount(ctx context.Context, addr sdk.AccAddress) bool SetAccount(ctx context.Context, acc sdk.AccountI) IterateAccounts(ctx context.Context, process func(sdk.AccountI) bool) ValidatePermissions(macc sdk.ModuleAccountI) error GetModuleAddress(moduleName string) sdk.AccAddress GetModuleAddressAndPermissions(moduleName string) (addr sdk.AccAddress, permissions []string) GetModuleAccountAndPermissions(ctx context.Context, moduleName string) (sdk.ModuleAccountI, []string) GetModuleAccount(ctx context.Context, moduleName string) sdk.ModuleAccountI SetModuleAccount(ctx context.Context, macc sdk.ModuleAccountI) GetModulePermissions() map[string]types.PermissionsForAddress }
AccountKeeper defines the account contract that must be fulfilled when creating an x/bank keeper.
type MsgClient ¶
type MsgClient interface { // LockedSend defines a method for sending coins and locking them from one // account to another account. LockedSend(ctx context.Context, in *MsgLockedSend, opts ...grpc.CallOption) (*MsgLockedSendResponse, 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 MsgLockedSend ¶
type MsgLockedSend struct { FromAddress string `protobuf:"bytes,1,opt,name=from_address,json=fromAddress,proto3" json:"from_address,omitempty" yaml:"from_address"` ToAddress string `protobuf:"bytes,2,opt,name=to_address,json=toAddress,proto3" json:"to_address,omitempty" yaml:"to_address"` UnlockerAddress string `` /* 130-byte string literal not displayed */ Amount github_com_cosmos_cosmos_sdk_types.Coins `protobuf:"bytes,4,rep,name=amount,proto3,castrepeated=github.com/cosmos/cosmos-sdk/types.Coins" json:"amount"` }
MsgLockedSend represents a message to send and lock coins from one account to another.
func NewMsgLockedSend ¶
func NewMsgLockedSend(from, to sdk.AccAddress, unlocker string, amount sdk.Coins) *MsgLockedSend
NewMsgLockedSend returns a MsgLockedSend object.
func (*MsgLockedSend) Descriptor ¶
func (*MsgLockedSend) Descriptor() ([]byte, []int)
func (MsgLockedSend) GetSignBytes ¶
func (m MsgLockedSend) GetSignBytes() []byte
GetSignBytes encodes the message for signing.
func (MsgLockedSend) GetSigners ¶
func (m MsgLockedSend) GetSigners() []sdk.AccAddress
GetSigners defines whose signature is required.
func (*MsgLockedSend) Marshal ¶
func (m *MsgLockedSend) Marshal() (dAtA []byte, err error)
func (*MsgLockedSend) MarshalToSizedBuffer ¶
func (m *MsgLockedSend) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*MsgLockedSend) ProtoMessage ¶
func (*MsgLockedSend) ProtoMessage()
func (*MsgLockedSend) Reset ¶
func (m *MsgLockedSend) Reset()
func (MsgLockedSend) Route ¶
func (m MsgLockedSend) Route() string
Route returns the name of the module.
func (*MsgLockedSend) Size ¶
func (m *MsgLockedSend) Size() (n int)
func (*MsgLockedSend) String ¶
func (m *MsgLockedSend) String() string
func (MsgLockedSend) Type ¶
func (m MsgLockedSend) Type() string
Type returns a human-readable string for the message.
func (*MsgLockedSend) Unmarshal ¶
func (m *MsgLockedSend) Unmarshal(dAtA []byte) error
func (MsgLockedSend) ValidateBasic ¶
func (m MsgLockedSend) ValidateBasic() error
ValidateBasic runs stateless checks on the message.
func (*MsgLockedSend) XXX_DiscardUnknown ¶
func (m *MsgLockedSend) XXX_DiscardUnknown()
func (*MsgLockedSend) XXX_Marshal ¶
func (m *MsgLockedSend) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*MsgLockedSend) XXX_Merge ¶
func (m *MsgLockedSend) XXX_Merge(src proto.Message)
func (*MsgLockedSend) XXX_Size ¶
func (m *MsgLockedSend) XXX_Size() int
func (*MsgLockedSend) XXX_Unmarshal ¶
func (m *MsgLockedSend) XXX_Unmarshal(b []byte) error
type MsgLockedSendResponse ¶
type MsgLockedSendResponse struct { }
MsgLockedSendResponse defines the Msg/LockedSend response type.
func (*MsgLockedSendResponse) Descriptor ¶
func (*MsgLockedSendResponse) Descriptor() ([]byte, []int)
func (*MsgLockedSendResponse) Marshal ¶
func (m *MsgLockedSendResponse) Marshal() (dAtA []byte, err error)
func (*MsgLockedSendResponse) MarshalTo ¶
func (m *MsgLockedSendResponse) MarshalTo(dAtA []byte) (int, error)
func (*MsgLockedSendResponse) MarshalToSizedBuffer ¶
func (m *MsgLockedSendResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*MsgLockedSendResponse) ProtoMessage ¶
func (*MsgLockedSendResponse) ProtoMessage()
func (*MsgLockedSendResponse) Reset ¶
func (m *MsgLockedSendResponse) Reset()
func (*MsgLockedSendResponse) Size ¶
func (m *MsgLockedSendResponse) Size() (n int)
func (*MsgLockedSendResponse) String ¶
func (m *MsgLockedSendResponse) String() string
func (*MsgLockedSendResponse) Unmarshal ¶
func (m *MsgLockedSendResponse) Unmarshal(dAtA []byte) error
func (*MsgLockedSendResponse) XXX_DiscardUnknown ¶
func (m *MsgLockedSendResponse) XXX_DiscardUnknown()
func (*MsgLockedSendResponse) XXX_Marshal ¶
func (m *MsgLockedSendResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*MsgLockedSendResponse) XXX_Merge ¶
func (m *MsgLockedSendResponse) XXX_Merge(src proto.Message)
func (*MsgLockedSendResponse) XXX_Size ¶
func (m *MsgLockedSendResponse) XXX_Size() int
func (*MsgLockedSendResponse) XXX_Unmarshal ¶
func (m *MsgLockedSendResponse) XXX_Unmarshal(b []byte) error
type MsgServer ¶
type MsgServer interface { // LockedSend defines a method for sending coins and locking them from one // account to another account. LockedSend(context.Context, *MsgLockedSend) (*MsgLockedSendResponse, error) }
MsgServer is the server API for Msg service.
type UnimplementedMsgServer ¶
type UnimplementedMsgServer struct { }
UnimplementedMsgServer can be embedded to have forward compatible implementations.
func (*UnimplementedMsgServer) LockedSend ¶
func (*UnimplementedMsgServer) LockedSend(ctx context.Context, req *MsgLockedSend) (*MsgLockedSendResponse, error)