types

package
v0.1.2 Latest Latest
Warning

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

Go to latest
Published: Jan 9, 2023 License: Apache-2.0 Imports: 26 Imported by: 0

Documentation

Overview

Package types is a reverse proxy.

It translates gRPC into RESTful JSON APIs.

Index

Constants

View Source
const (
	// ModuleName defines the module name
	ModuleName = "token"

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

	// RouterKey defines the module's message routing key
	RouterKey = ModuleName

	// MemStoreKey defines the in-memory store key
	MemStoreKey = "mem_token"
)
View Source
const (
	TokenKey      = "TokenKey"
	TokenOwnerKey = "TokenOwnerKey"
)
View Source
const DefaultIndex uint64 = 1

DefaultIndex is the default global index

View Source
const TypeMsgBurn = "burn"
View Source
const TypeMsgCreateToken = "create_token"
View Source
const TypeMsgMint = "mint"

Variables

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 (
	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 (
	ErrInvalidLengthToken        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowToken          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupToken = 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 (
	ErrSample = sdkerrors.Register(ModuleName, 1100, "sample error")
)

x/token module sentinel errors

Functions

func KeyPrefix

func KeyPrefix(p string) []byte

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

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)

func TokenKeyPrefix

func TokenKeyPrefix(tokenId string) []byte

Types

type BankKeeper

type BankKeeper interface {
	MintCoins(ctx sdk.Context, moduleName string, amt sdk.Coins) error
	BurnCoins(ctx sdk.Context, moduleName string, amt sdk.Coins) error
	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
	GetSupply(ctx sdk.Context, denom string) sdk.Coin
	GetBalance(ctx sdk.Context, addr sdk.AccAddress, denom string) sdk.Coin
}

BankKeeper defines the expected interface needed to retrieve account balances.

type GenesisState

type GenesisState struct {
	TokenList []Token `protobuf:"bytes,1,rep,name=tokenList,proto3" json:"tokenList"`
}

GenesisState defines the token module's genesis state.

func DefaultGenesis

func DefaultGenesis() *GenesisState

DefaultGenesis returns the default genesis state

func (*GenesisState) Descriptor

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

func (*GenesisState) GetTokenList

func (m *GenesisState) GetTokenList() []Token

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 MsgBurn

type MsgBurn struct {
	Owner   string `protobuf:"bytes,1,opt,name=owner,proto3" json:"owner,omitempty"`
	TokenID string `protobuf:"bytes,2,opt,name=tokenID,proto3" json:"tokenID,omitempty"`
	Amount  uint64 `protobuf:"varint,3,opt,name=amount,proto3" json:"amount,omitempty"`
}

func NewMsgBurn

func NewMsgBurn(owner string, tokenID string, amount uint64) *MsgBurn

func (*MsgBurn) Descriptor

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

func (*MsgBurn) GetAmount

func (m *MsgBurn) GetAmount() uint64

func (*MsgBurn) GetOwner

func (m *MsgBurn) GetOwner() string

func (*MsgBurn) GetSignBytes

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

func (*MsgBurn) GetSigners

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

func (*MsgBurn) GetTokenID

func (m *MsgBurn) GetTokenID() string

func (*MsgBurn) Marshal

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

func (*MsgBurn) MarshalTo

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

func (*MsgBurn) MarshalToSizedBuffer

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

func (*MsgBurn) ProtoMessage

func (*MsgBurn) ProtoMessage()

func (*MsgBurn) Reset

func (m *MsgBurn) Reset()

func (*MsgBurn) Route

func (msg *MsgBurn) Route() string

func (*MsgBurn) Size

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

func (*MsgBurn) String

func (m *MsgBurn) String() string

func (*MsgBurn) Type

func (msg *MsgBurn) Type() string

func (*MsgBurn) Unmarshal

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

func (*MsgBurn) ValidateBasic

func (msg *MsgBurn) ValidateBasic() error

func (*MsgBurn) XXX_DiscardUnknown

func (m *MsgBurn) XXX_DiscardUnknown()

func (*MsgBurn) XXX_Marshal

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

func (*MsgBurn) XXX_Merge

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

func (*MsgBurn) XXX_Size

func (m *MsgBurn) XXX_Size() int

func (*MsgBurn) XXX_Unmarshal

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

type MsgBurnResponse

type MsgBurnResponse struct {
}

func (*MsgBurnResponse) Descriptor

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

func (*MsgBurnResponse) Marshal

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

func (*MsgBurnResponse) MarshalTo

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

func (*MsgBurnResponse) MarshalToSizedBuffer

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

func (*MsgBurnResponse) ProtoMessage

func (*MsgBurnResponse) ProtoMessage()

func (*MsgBurnResponse) Reset

func (m *MsgBurnResponse) Reset()

func (*MsgBurnResponse) Size

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

func (*MsgBurnResponse) String

func (m *MsgBurnResponse) String() string

func (*MsgBurnResponse) Unmarshal

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

func (*MsgBurnResponse) XXX_DiscardUnknown

func (m *MsgBurnResponse) XXX_DiscardUnknown()

func (*MsgBurnResponse) XXX_Marshal

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

func (*MsgBurnResponse) XXX_Merge

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

func (*MsgBurnResponse) XXX_Size

func (m *MsgBurnResponse) XXX_Size() int

func (*MsgBurnResponse) XXX_Unmarshal

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

type MsgClient

type MsgClient interface {
	CreateToken(ctx context.Context, in *MsgCreateToken, opts ...grpc.CallOption) (*MsgCreateTokenResponse, error)
	Mint(ctx context.Context, in *MsgMint, opts ...grpc.CallOption) (*MsgMintResponse, error)
	Burn(ctx context.Context, in *MsgBurn, opts ...grpc.CallOption) (*MsgBurnResponse, 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 MsgCreateToken

type MsgCreateToken struct {
	Owner    string `protobuf:"bytes,1,opt,name=owner,proto3" json:"owner,omitempty"`
	Name     string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`
	Symbol   string `protobuf:"bytes,3,opt,name=symbol,proto3" json:"symbol,omitempty"`
	Supply   uint64 `protobuf:"varint,4,opt,name=supply,proto3" json:"supply,omitempty"`
	Decimal  uint64 `protobuf:"varint,5,opt,name=decimal,proto3" json:"decimal,omitempty"`
	Mintable bool   `protobuf:"varint,6,opt,name=mintable,proto3" json:"mintable,omitempty"`
	Burnable bool   `protobuf:"varint,7,opt,name=burnable,proto3" json:"burnable,omitempty"`
}

func NewMsgCreateToken

func NewMsgCreateToken(owner string, name string, symbol string, supply uint64, decimal uint64, mintable bool, burnable bool) *MsgCreateToken

func (*MsgCreateToken) Descriptor

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

func (*MsgCreateToken) GetBurnable

func (m *MsgCreateToken) GetBurnable() bool

func (*MsgCreateToken) GetDecimal

func (m *MsgCreateToken) GetDecimal() uint64

func (*MsgCreateToken) GetMintable

func (m *MsgCreateToken) GetMintable() bool

func (*MsgCreateToken) GetName

func (m *MsgCreateToken) GetName() string

func (*MsgCreateToken) GetOwner

func (m *MsgCreateToken) GetOwner() string

func (*MsgCreateToken) GetSignBytes

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

func (*MsgCreateToken) GetSigners

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

func (*MsgCreateToken) GetSupply

func (m *MsgCreateToken) GetSupply() uint64

func (*MsgCreateToken) GetSymbol

func (m *MsgCreateToken) GetSymbol() string

func (*MsgCreateToken) Marshal

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

func (*MsgCreateToken) MarshalTo

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

func (*MsgCreateToken) MarshalToSizedBuffer

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

func (*MsgCreateToken) ProtoMessage

func (*MsgCreateToken) ProtoMessage()

func (*MsgCreateToken) Reset

func (m *MsgCreateToken) Reset()

func (*MsgCreateToken) Route

func (msg *MsgCreateToken) Route() string

func (*MsgCreateToken) Size

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

func (*MsgCreateToken) String

func (m *MsgCreateToken) String() string

func (*MsgCreateToken) Type

func (msg *MsgCreateToken) Type() string

func (*MsgCreateToken) Unmarshal

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

func (*MsgCreateToken) ValidateBasic

func (msg *MsgCreateToken) ValidateBasic() error

func (*MsgCreateToken) XXX_DiscardUnknown

func (m *MsgCreateToken) XXX_DiscardUnknown()

func (*MsgCreateToken) XXX_Marshal

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

func (*MsgCreateToken) XXX_Merge

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

func (*MsgCreateToken) XXX_Size

func (m *MsgCreateToken) XXX_Size() int

func (*MsgCreateToken) XXX_Unmarshal

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

type MsgCreateTokenResponse

type MsgCreateTokenResponse struct {
}

func (*MsgCreateTokenResponse) Descriptor

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

func (*MsgCreateTokenResponse) Marshal

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

func (*MsgCreateTokenResponse) MarshalTo

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

func (*MsgCreateTokenResponse) MarshalToSizedBuffer

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

func (*MsgCreateTokenResponse) ProtoMessage

func (*MsgCreateTokenResponse) ProtoMessage()

func (*MsgCreateTokenResponse) Reset

func (m *MsgCreateTokenResponse) Reset()

func (*MsgCreateTokenResponse) Size

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

func (*MsgCreateTokenResponse) String

func (m *MsgCreateTokenResponse) String() string

func (*MsgCreateTokenResponse) Unmarshal

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

func (*MsgCreateTokenResponse) XXX_DiscardUnknown

func (m *MsgCreateTokenResponse) XXX_DiscardUnknown()

func (*MsgCreateTokenResponse) XXX_Marshal

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

func (*MsgCreateTokenResponse) XXX_Merge

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

func (*MsgCreateTokenResponse) XXX_Size

func (m *MsgCreateTokenResponse) XXX_Size() int

func (*MsgCreateTokenResponse) XXX_Unmarshal

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

type MsgMint

type MsgMint struct {
	Owner   string `protobuf:"bytes,1,opt,name=owner,proto3" json:"owner,omitempty"`
	TokenID string `protobuf:"bytes,2,opt,name=tokenID,proto3" json:"tokenID,omitempty"`
	Amount  uint64 `protobuf:"varint,3,opt,name=amount,proto3" json:"amount,omitempty"`
	To      string `protobuf:"bytes,4,opt,name=to,proto3" json:"to,omitempty"`
}

func NewMsgMint

func NewMsgMint(owner string, tokenID string, amount uint64, to string) *MsgMint

func (*MsgMint) Descriptor

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

func (*MsgMint) GetAmount

func (m *MsgMint) GetAmount() uint64

func (*MsgMint) GetOwner

func (m *MsgMint) GetOwner() string

func (*MsgMint) GetSignBytes

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

func (*MsgMint) GetSigners

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

func (*MsgMint) GetTo

func (m *MsgMint) GetTo() string

func (*MsgMint) GetTokenID

func (m *MsgMint) GetTokenID() string

func (*MsgMint) Marshal

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

func (*MsgMint) MarshalTo

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

func (*MsgMint) MarshalToSizedBuffer

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

func (*MsgMint) ProtoMessage

func (*MsgMint) ProtoMessage()

func (*MsgMint) Reset

func (m *MsgMint) Reset()

func (*MsgMint) Route

func (msg *MsgMint) Route() string

func (*MsgMint) Size

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

func (*MsgMint) String

func (m *MsgMint) String() string

func (*MsgMint) Type

func (msg *MsgMint) Type() string

func (*MsgMint) Unmarshal

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

func (*MsgMint) ValidateBasic

func (msg *MsgMint) ValidateBasic() error

func (*MsgMint) XXX_DiscardUnknown

func (m *MsgMint) XXX_DiscardUnknown()

func (*MsgMint) XXX_Marshal

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

func (*MsgMint) XXX_Merge

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

func (*MsgMint) XXX_Size

func (m *MsgMint) XXX_Size() int

func (*MsgMint) XXX_Unmarshal

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

type MsgMintResponse

type MsgMintResponse struct {
}

func (*MsgMintResponse) Descriptor

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

func (*MsgMintResponse) Marshal

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

func (*MsgMintResponse) MarshalTo

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

func (*MsgMintResponse) MarshalToSizedBuffer

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

func (*MsgMintResponse) ProtoMessage

func (*MsgMintResponse) ProtoMessage()

func (*MsgMintResponse) Reset

func (m *MsgMintResponse) Reset()

func (*MsgMintResponse) Size

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

func (*MsgMintResponse) String

func (m *MsgMintResponse) String() string

func (*MsgMintResponse) Unmarshal

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

func (*MsgMintResponse) XXX_DiscardUnknown

func (m *MsgMintResponse) XXX_DiscardUnknown()

func (*MsgMintResponse) XXX_Marshal

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

func (*MsgMintResponse) XXX_Merge

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

func (*MsgMintResponse) XXX_Size

func (m *MsgMintResponse) XXX_Size() int

func (*MsgMintResponse) XXX_Unmarshal

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

type MsgServer

MsgServer is the server API for Msg service.

type QueryAllTokenRequest

type QueryAllTokenRequest struct {
	Pagination *query.PageRequest `protobuf:"bytes,1,opt,name=pagination,proto3" json:"pagination,omitempty"`
}

func (*QueryAllTokenRequest) Descriptor

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

func (*QueryAllTokenRequest) GetPagination

func (m *QueryAllTokenRequest) GetPagination() *query.PageRequest

func (*QueryAllTokenRequest) Marshal

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

func (*QueryAllTokenRequest) MarshalTo

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

func (*QueryAllTokenRequest) MarshalToSizedBuffer

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

func (*QueryAllTokenRequest) ProtoMessage

func (*QueryAllTokenRequest) ProtoMessage()

func (*QueryAllTokenRequest) Reset

func (m *QueryAllTokenRequest) Reset()

func (*QueryAllTokenRequest) Size

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

func (*QueryAllTokenRequest) String

func (m *QueryAllTokenRequest) String() string

func (*QueryAllTokenRequest) Unmarshal

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

func (*QueryAllTokenRequest) XXX_DiscardUnknown

func (m *QueryAllTokenRequest) XXX_DiscardUnknown()

func (*QueryAllTokenRequest) XXX_Marshal

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

func (*QueryAllTokenRequest) XXX_Merge

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

func (*QueryAllTokenRequest) XXX_Size

func (m *QueryAllTokenRequest) XXX_Size() int

func (*QueryAllTokenRequest) XXX_Unmarshal

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

type QueryAllTokenResponse

type QueryAllTokenResponse struct {
	Token      []Token             `protobuf:"bytes,1,rep,name=Token,proto3" json:"Token"`
	Pagination *query.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"`
}

func (*QueryAllTokenResponse) Descriptor

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

func (*QueryAllTokenResponse) GetPagination

func (m *QueryAllTokenResponse) GetPagination() *query.PageResponse

func (*QueryAllTokenResponse) GetToken

func (m *QueryAllTokenResponse) GetToken() []Token

func (*QueryAllTokenResponse) Marshal

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

func (*QueryAllTokenResponse) MarshalTo

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

func (*QueryAllTokenResponse) MarshalToSizedBuffer

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

func (*QueryAllTokenResponse) ProtoMessage

func (*QueryAllTokenResponse) ProtoMessage()

func (*QueryAllTokenResponse) Reset

func (m *QueryAllTokenResponse) Reset()

func (*QueryAllTokenResponse) Size

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

func (*QueryAllTokenResponse) String

func (m *QueryAllTokenResponse) String() string

func (*QueryAllTokenResponse) Unmarshal

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

func (*QueryAllTokenResponse) XXX_DiscardUnknown

func (m *QueryAllTokenResponse) XXX_DiscardUnknown()

func (*QueryAllTokenResponse) XXX_Marshal

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

func (*QueryAllTokenResponse) XXX_Merge

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

func (*QueryAllTokenResponse) XXX_Size

func (m *QueryAllTokenResponse) XXX_Size() int

func (*QueryAllTokenResponse) XXX_Unmarshal

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

type QueryClient

type QueryClient interface {
	// Queries a Token by id.
	Token(ctx context.Context, in *QueryGetTokenRequest, opts ...grpc.CallOption) (*QueryGetTokenResponse, error)
	// Queries a list of Token items.
	TokenAll(ctx context.Context, in *QueryAllTokenRequest, opts ...grpc.CallOption) (*QueryAllTokenResponse, error)
	// Queries a list of Token items for owner.
	TokenList(ctx context.Context, in *QueryTokenListRequest, opts ...grpc.CallOption) (*QueryTokenListResponse, 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 QueryGetTokenRequest

type QueryGetTokenRequest struct {
	Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
}

func (*QueryGetTokenRequest) Descriptor

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

func (*QueryGetTokenRequest) GetId

func (m *QueryGetTokenRequest) GetId() string

func (*QueryGetTokenRequest) Marshal

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

func (*QueryGetTokenRequest) MarshalTo

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

func (*QueryGetTokenRequest) MarshalToSizedBuffer

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

func (*QueryGetTokenRequest) ProtoMessage

func (*QueryGetTokenRequest) ProtoMessage()

func (*QueryGetTokenRequest) Reset

func (m *QueryGetTokenRequest) Reset()

func (*QueryGetTokenRequest) Size

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

func (*QueryGetTokenRequest) String

func (m *QueryGetTokenRequest) String() string

func (*QueryGetTokenRequest) Unmarshal

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

func (*QueryGetTokenRequest) XXX_DiscardUnknown

func (m *QueryGetTokenRequest) XXX_DiscardUnknown()

func (*QueryGetTokenRequest) XXX_Marshal

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

func (*QueryGetTokenRequest) XXX_Merge

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

func (*QueryGetTokenRequest) XXX_Size

func (m *QueryGetTokenRequest) XXX_Size() int

func (*QueryGetTokenRequest) XXX_Unmarshal

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

type QueryGetTokenResponse

type QueryGetTokenResponse struct {
	Token Token `protobuf:"bytes,1,opt,name=Token,proto3" json:"Token"`
}

func (*QueryGetTokenResponse) Descriptor

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

func (*QueryGetTokenResponse) GetToken

func (m *QueryGetTokenResponse) GetToken() Token

func (*QueryGetTokenResponse) Marshal

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

func (*QueryGetTokenResponse) MarshalTo

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

func (*QueryGetTokenResponse) MarshalToSizedBuffer

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

func (*QueryGetTokenResponse) ProtoMessage

func (*QueryGetTokenResponse) ProtoMessage()

func (*QueryGetTokenResponse) Reset

func (m *QueryGetTokenResponse) Reset()

func (*QueryGetTokenResponse) Size

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

func (*QueryGetTokenResponse) String

func (m *QueryGetTokenResponse) String() string

func (*QueryGetTokenResponse) Unmarshal

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

func (*QueryGetTokenResponse) XXX_DiscardUnknown

func (m *QueryGetTokenResponse) XXX_DiscardUnknown()

func (*QueryGetTokenResponse) XXX_Marshal

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

func (*QueryGetTokenResponse) XXX_Merge

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

func (*QueryGetTokenResponse) XXX_Size

func (m *QueryGetTokenResponse) XXX_Size() int

func (*QueryGetTokenResponse) XXX_Unmarshal

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

type QueryServer

type QueryServer interface {
	// Queries a Token by id.
	Token(context.Context, *QueryGetTokenRequest) (*QueryGetTokenResponse, error)
	// Queries a list of Token items.
	TokenAll(context.Context, *QueryAllTokenRequest) (*QueryAllTokenResponse, error)
	// Queries a list of Token items for owner.
	TokenList(context.Context, *QueryTokenListRequest) (*QueryTokenListResponse, error)
}

QueryServer is the server API for Query service.

type QueryTokenListRequest

type QueryTokenListRequest struct {
	Owner string `protobuf:"bytes,1,opt,name=owner,proto3" json:"owner,omitempty"`
}

func (*QueryTokenListRequest) Descriptor

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

func (*QueryTokenListRequest) GetOwner

func (m *QueryTokenListRequest) GetOwner() string

func (*QueryTokenListRequest) Marshal

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

func (*QueryTokenListRequest) MarshalTo

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

func (*QueryTokenListRequest) MarshalToSizedBuffer

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

func (*QueryTokenListRequest) ProtoMessage

func (*QueryTokenListRequest) ProtoMessage()

func (*QueryTokenListRequest) Reset

func (m *QueryTokenListRequest) Reset()

func (*QueryTokenListRequest) Size

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

func (*QueryTokenListRequest) String

func (m *QueryTokenListRequest) String() string

func (*QueryTokenListRequest) Unmarshal

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

func (*QueryTokenListRequest) XXX_DiscardUnknown

func (m *QueryTokenListRequest) XXX_DiscardUnknown()

func (*QueryTokenListRequest) XXX_Marshal

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

func (*QueryTokenListRequest) XXX_Merge

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

func (*QueryTokenListRequest) XXX_Size

func (m *QueryTokenListRequest) XXX_Size() int

func (*QueryTokenListRequest) XXX_Unmarshal

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

type QueryTokenListResponse

type QueryTokenListResponse struct {
	Token []string `protobuf:"bytes,1,rep,name=Token,proto3" json:"Token,omitempty"`
}

func (*QueryTokenListResponse) Descriptor

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

func (*QueryTokenListResponse) GetToken

func (m *QueryTokenListResponse) GetToken() []string

func (*QueryTokenListResponse) Marshal

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

func (*QueryTokenListResponse) MarshalTo

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

func (*QueryTokenListResponse) MarshalToSizedBuffer

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

func (*QueryTokenListResponse) ProtoMessage

func (*QueryTokenListResponse) ProtoMessage()

func (*QueryTokenListResponse) Reset

func (m *QueryTokenListResponse) Reset()

func (*QueryTokenListResponse) Size

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

func (*QueryTokenListResponse) String

func (m *QueryTokenListResponse) String() string

func (*QueryTokenListResponse) Unmarshal

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

func (*QueryTokenListResponse) XXX_DiscardUnknown

func (m *QueryTokenListResponse) XXX_DiscardUnknown()

func (*QueryTokenListResponse) XXX_Marshal

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

func (*QueryTokenListResponse) XXX_Merge

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

func (*QueryTokenListResponse) XXX_Size

func (m *QueryTokenListResponse) XXX_Size() int

func (*QueryTokenListResponse) XXX_Unmarshal

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

type Token

type Token struct {
	Id           string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	Owner        string `protobuf:"bytes,2,opt,name=owner,proto3" json:"owner,omitempty"`
	Name         string `protobuf:"bytes,3,opt,name=name,proto3" json:"name,omitempty"`
	Symbol       string `protobuf:"bytes,4,opt,name=symbol,proto3" json:"symbol,omitempty"`
	Supply       uint64 `protobuf:"varint,5,opt,name=supply,proto3" json:"supply,omitempty"`
	Decimal      uint64 `protobuf:"varint,6,opt,name=decimal,proto3" json:"decimal,omitempty"`
	Mintable     bool   `protobuf:"varint,7,opt,name=mintable,proto3" json:"mintable,omitempty"`
	Burnable     bool   `protobuf:"varint,8,opt,name=burnable,proto3" json:"burnable,omitempty"`
	MintSequence uint64 `protobuf:"varint,9,opt,name=mintSequence,proto3" json:"mintSequence,omitempty"`
	BurnSequence uint64 `protobuf:"varint,10,opt,name=burnSequence,proto3" json:"burnSequence,omitempty"`
}

func (*Token) Descriptor

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

func (*Token) GetBurnSequence

func (m *Token) GetBurnSequence() uint64

func (*Token) GetBurnable

func (m *Token) GetBurnable() bool

func (*Token) GetDecimal

func (m *Token) GetDecimal() uint64

func (*Token) GetId

func (m *Token) GetId() string

func (*Token) GetMintSequence

func (m *Token) GetMintSequence() uint64

func (*Token) GetMintable

func (m *Token) GetMintable() bool

func (*Token) GetName

func (m *Token) GetName() string

func (*Token) GetOwner

func (m *Token) GetOwner() string

func (*Token) GetSupply

func (m *Token) GetSupply() uint64

func (*Token) GetSymbol

func (m *Token) GetSymbol() string

func (*Token) Marshal

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

func (*Token) MarshalTo

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

func (*Token) MarshalToSizedBuffer

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

func (*Token) ProtoMessage

func (*Token) ProtoMessage()

func (*Token) Reset

func (m *Token) Reset()

func (*Token) Size

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

func (*Token) String

func (m *Token) String() string

func (*Token) Unmarshal

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

func (*Token) XXX_DiscardUnknown

func (m *Token) XXX_DiscardUnknown()

func (*Token) XXX_Marshal

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

func (*Token) XXX_Merge

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

func (*Token) XXX_Size

func (m *Token) XXX_Size() int

func (*Token) XXX_Unmarshal

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

type UnimplementedMsgServer

type UnimplementedMsgServer struct {
}

UnimplementedMsgServer can be embedded to have forward compatible implementations.

func (*UnimplementedMsgServer) Burn

func (*UnimplementedMsgServer) CreateToken

func (*UnimplementedMsgServer) Mint

type UnimplementedQueryServer

type UnimplementedQueryServer struct {
}

UnimplementedQueryServer can be embedded to have forward compatible implementations.

func (*UnimplementedQueryServer) Token

func (*UnimplementedQueryServer) TokenAll

func (*UnimplementedQueryServer) TokenList

Jump to

Keyboard shortcuts

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