Documentation
¶
Overview ¶
Package types is a reverse proxy.
It translates gRPC into RESTful JSON APIs.
Index ¶
- Constants
- Variables
- func HistoricalDataStoreKey(timestamp time.Time) []byte
- func IsTicketIDDuplicated(id string, slice []Ticket) bool
- func MarshalHistoricalDraw(cdc codec.BinaryMarshaler, draw HistoricalDrawData) ([]byte, error)
- func MarshalTicket(cdc codec.BinaryMarshaler, ticket Ticket) ([]byte, error)
- func MustMarshalDrawEndTime(endTime time.Time) []byte
- func MustMarshalHistoricalDraw(cdc codec.BinaryMarshaler, draw HistoricalDrawData) []byte
- func MustMarshalTicket(cdc codec.BinaryMarshaler, ticket Ticket) []byte
- func MustUnmarshalDrawEndTime(bz []byte) time.Time
- func NewRandFromCtx(ctx sdk.Context) *rand.Rand
- func NewRandFromCtxAndIndex(ctx sdk.Context, i int) *rand.Rand
- func NewRandFromSeed(seed []byte) *rand.Rand
- func ParamKeyTable() paramstypes.KeyTable
- func RegisterInterfaces(registry types.InterfaceRegistry)
- func RegisterLegacyAminoCodec(cdc *codec.LegacyAmino)
- func RegisterMsgServer(s grpc1.Server, srv MsgServer)
- func RegisterQueryHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error
- func RegisterQueryHandlerClient(ctx context.Context, mux *runtime.ServeMux, client QueryClient) error
- func RegisterQueryHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, ...) (err error)
- func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, server QueryServer) error
- func RegisterQueryServer(s grpc1.Server, srv QueryServer)
- func TicketsStoreKey(id string) []byte
- func ValidateDistributionParams(i interface{}) error
- func ValidateDrawParams(i interface{}) error
- func ValidateGenesis(state *GenesisState) error
- func ValidateTicketParams(i interface{}) error
- type DistributionParams
- func (*DistributionParams) Descriptor() ([]byte, []int)
- func (m *DistributionParams) Marshal() (dAtA []byte, err error)
- func (m *DistributionParams) MarshalTo(dAtA []byte) (int, error)
- func (m *DistributionParams) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*DistributionParams) ProtoMessage()
- func (m *DistributionParams) Reset()
- func (m *DistributionParams) Size() (n int)
- func (m *DistributionParams) String() string
- func (m *DistributionParams) Unmarshal(dAtA []byte) error
- func (m *DistributionParams) XXX_DiscardUnknown()
- func (m *DistributionParams) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *DistributionParams) XXX_Merge(src proto.Message)
- func (m *DistributionParams) XXX_Size() int
- func (m *DistributionParams) XXX_Unmarshal(b []byte) error
- type Draw
- func (*Draw) Descriptor() ([]byte, []int)
- func (d Draw) Equal(e Draw) bool
- func (m *Draw) GetEndTime() time.Time
- func (m *Draw) GetParticipants() uint32
- func (m *Draw) GetPrize() github_com_cosmos_cosmos_sdk_types.Coins
- func (m *Draw) GetTicketsSold() uint32
- func (m *Draw) Marshal() (dAtA []byte, err error)
- func (m *Draw) MarshalTo(dAtA []byte) (int, error)
- func (m *Draw) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*Draw) ProtoMessage()
- func (m *Draw) Reset()
- func (m *Draw) Size() (n int)
- func (m *Draw) String() string
- func (m *Draw) Unmarshal(dAtA []byte) error
- func (d Draw) Validate() error
- func (m *Draw) XXX_DiscardUnknown()
- func (m *Draw) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Draw) XXX_Merge(src proto.Message)
- func (m *Draw) XXX_Size() int
- func (m *Draw) XXX_Unmarshal(b []byte) error
- type DrawParams
- func (*DrawParams) Descriptor() ([]byte, []int)
- func (m *DrawParams) GetDuration() time.Duration
- func (m *DrawParams) Marshal() (dAtA []byte, err error)
- func (m *DrawParams) MarshalTo(dAtA []byte) (int, error)
- func (m *DrawParams) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*DrawParams) ProtoMessage()
- func (m *DrawParams) Reset()
- func (m *DrawParams) Size() (n int)
- func (m *DrawParams) String() string
- func (m *DrawParams) Unmarshal(dAtA []byte) error
- func (m *DrawParams) XXX_DiscardUnknown()
- func (m *DrawParams) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *DrawParams) XXX_Merge(src proto.Message)
- func (m *DrawParams) XXX_Size() int
- func (m *DrawParams) XXX_Unmarshal(b []byte) error
- type GenesisState
- func (*GenesisState) Descriptor() ([]byte, []int)
- func (m *GenesisState) GetDistributionParams() DistributionParams
- func (m *GenesisState) GetDrawEndTime() time.Time
- func (m *GenesisState) GetDrawParams() DrawParams
- func (m *GenesisState) GetPastDraws() []HistoricalDrawData
- func (m *GenesisState) GetTicketParams() TicketParams
- func (m *GenesisState) GetTickets() []Ticket
- func (m *GenesisState) Marshal() (dAtA []byte, err error)
- func (m *GenesisState) MarshalTo(dAtA []byte) (int, error)
- func (m *GenesisState) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*GenesisState) ProtoMessage()
- func (m *GenesisState) Reset()
- func (m *GenesisState) Size() (n int)
- func (m *GenesisState) String() string
- func (m *GenesisState) Unmarshal(dAtA []byte) error
- func (m *GenesisState) XXX_DiscardUnknown()
- func (m *GenesisState) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *GenesisState) XXX_Merge(src proto.Message)
- func (m *GenesisState) XXX_Size() int
- func (m *GenesisState) XXX_Unmarshal(b []byte) error
- type HistoricalDrawData
- func (*HistoricalDrawData) Descriptor() ([]byte, []int)
- func (m *HistoricalDrawData) GetDraw() Draw
- func (m *HistoricalDrawData) GetWinningTicket() Ticket
- func (m *HistoricalDrawData) Marshal() (dAtA []byte, err error)
- func (m *HistoricalDrawData) MarshalTo(dAtA []byte) (int, error)
- func (m *HistoricalDrawData) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*HistoricalDrawData) ProtoMessage()
- func (m *HistoricalDrawData) Reset()
- func (m *HistoricalDrawData) Size() (n int)
- func (m *HistoricalDrawData) String() string
- func (m *HistoricalDrawData) Unmarshal(dAtA []byte) error
- func (h *HistoricalDrawData) Validate() error
- func (m *HistoricalDrawData) XXX_DiscardUnknown()
- func (m *HistoricalDrawData) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *HistoricalDrawData) XXX_Merge(src proto.Message)
- func (m *HistoricalDrawData) XXX_Size() int
- func (m *HistoricalDrawData) XXX_Unmarshal(b []byte) error
- type MsgBuyTickets
- func (*MsgBuyTickets) Descriptor() ([]byte, []int)
- func (m *MsgBuyTickets) GetSignBytes() []byte
- func (m *MsgBuyTickets) GetSigners() []sdk.AccAddress
- func (m *MsgBuyTickets) Marshal() (dAtA []byte, err error)
- func (m *MsgBuyTickets) MarshalTo(dAtA []byte) (int, error)
- func (m *MsgBuyTickets) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*MsgBuyTickets) ProtoMessage()
- func (m *MsgBuyTickets) Reset()
- func (m *MsgBuyTickets) Route() string
- func (m *MsgBuyTickets) Size() (n int)
- func (m *MsgBuyTickets) String() string
- func (m *MsgBuyTickets) Type() string
- func (m *MsgBuyTickets) Unmarshal(dAtA []byte) error
- func (m *MsgBuyTickets) ValidateBasic() error
- func (m *MsgBuyTickets) XXX_DiscardUnknown()
- func (m *MsgBuyTickets) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *MsgBuyTickets) XXX_Merge(src proto.Message)
- func (m *MsgBuyTickets) XXX_Size() int
- func (m *MsgBuyTickets) XXX_Unmarshal(b []byte) error
- type MsgBuyTicketsResponse
- func (*MsgBuyTicketsResponse) Descriptor() ([]byte, []int)
- func (m *MsgBuyTicketsResponse) Marshal() (dAtA []byte, err error)
- func (m *MsgBuyTicketsResponse) MarshalTo(dAtA []byte) (int, error)
- func (m *MsgBuyTicketsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*MsgBuyTicketsResponse) ProtoMessage()
- func (m *MsgBuyTicketsResponse) Reset()
- func (m *MsgBuyTicketsResponse) Size() (n int)
- func (m *MsgBuyTicketsResponse) String() string
- func (m *MsgBuyTicketsResponse) Unmarshal(dAtA []byte) error
- func (m *MsgBuyTicketsResponse) XXX_DiscardUnknown()
- func (m *MsgBuyTicketsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *MsgBuyTicketsResponse) XXX_Merge(src proto.Message)
- func (m *MsgBuyTicketsResponse) XXX_Size() int
- func (m *MsgBuyTicketsResponse) XXX_Unmarshal(b []byte) error
- type MsgClient
- type MsgServer
- type QueryClient
- type QueryNextDrawRequest
- func (*QueryNextDrawRequest) Descriptor() ([]byte, []int)
- func (m *QueryNextDrawRequest) Marshal() (dAtA []byte, err error)
- func (m *QueryNextDrawRequest) MarshalTo(dAtA []byte) (int, error)
- func (m *QueryNextDrawRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*QueryNextDrawRequest) ProtoMessage()
- func (m *QueryNextDrawRequest) Reset()
- func (m *QueryNextDrawRequest) Size() (n int)
- func (m *QueryNextDrawRequest) String() string
- func (m *QueryNextDrawRequest) Unmarshal(dAtA []byte) error
- func (m *QueryNextDrawRequest) XXX_DiscardUnknown()
- func (m *QueryNextDrawRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *QueryNextDrawRequest) XXX_Merge(src proto.Message)
- func (m *QueryNextDrawRequest) XXX_Size() int
- func (m *QueryNextDrawRequest) XXX_Unmarshal(b []byte) error
- type QueryNextDrawResponse
- func (*QueryNextDrawResponse) Descriptor() ([]byte, []int)
- func (m *QueryNextDrawResponse) GetDraw() Draw
- func (m *QueryNextDrawResponse) Marshal() (dAtA []byte, err error)
- func (m *QueryNextDrawResponse) MarshalTo(dAtA []byte) (int, error)
- func (m *QueryNextDrawResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*QueryNextDrawResponse) ProtoMessage()
- func (m *QueryNextDrawResponse) Reset()
- func (m *QueryNextDrawResponse) Size() (n int)
- func (m *QueryNextDrawResponse) String() string
- func (m *QueryNextDrawResponse) Unmarshal(dAtA []byte) error
- func (m *QueryNextDrawResponse) XXX_DiscardUnknown()
- func (m *QueryNextDrawResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *QueryNextDrawResponse) XXX_Merge(src proto.Message)
- func (m *QueryNextDrawResponse) XXX_Size() int
- func (m *QueryNextDrawResponse) XXX_Unmarshal(b []byte) error
- type QueryParamsRequest
- func (*QueryParamsRequest) Descriptor() ([]byte, []int)
- func (m *QueryParamsRequest) Marshal() (dAtA []byte, err error)
- func (m *QueryParamsRequest) MarshalTo(dAtA []byte) (int, error)
- func (m *QueryParamsRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*QueryParamsRequest) ProtoMessage()
- func (m *QueryParamsRequest) Reset()
- func (m *QueryParamsRequest) Size() (n int)
- func (m *QueryParamsRequest) String() string
- func (m *QueryParamsRequest) Unmarshal(dAtA []byte) error
- func (m *QueryParamsRequest) XXX_DiscardUnknown()
- func (m *QueryParamsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *QueryParamsRequest) XXX_Merge(src proto.Message)
- func (m *QueryParamsRequest) XXX_Size() int
- func (m *QueryParamsRequest) XXX_Unmarshal(b []byte) error
- type QueryParamsResponse
- func (*QueryParamsResponse) Descriptor() ([]byte, []int)
- func (m *QueryParamsResponse) GetDistributionParams() DistributionParams
- func (m *QueryParamsResponse) GetDrawParams() DrawParams
- func (m *QueryParamsResponse) GetTicketParams() TicketParams
- func (m *QueryParamsResponse) Marshal() (dAtA []byte, err error)
- func (m *QueryParamsResponse) MarshalTo(dAtA []byte) (int, error)
- func (m *QueryParamsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*QueryParamsResponse) ProtoMessage()
- func (m *QueryParamsResponse) Reset()
- func (m *QueryParamsResponse) Size() (n int)
- func (m *QueryParamsResponse) String() string
- func (m *QueryParamsResponse) Unmarshal(dAtA []byte) error
- func (m *QueryParamsResponse) XXX_DiscardUnknown()
- func (m *QueryParamsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *QueryParamsResponse) XXX_Merge(src proto.Message)
- func (m *QueryParamsResponse) XXX_Size() int
- func (m *QueryParamsResponse) XXX_Unmarshal(b []byte) error
- type QueryPastDrawsRequest
- func (*QueryPastDrawsRequest) Descriptor() ([]byte, []int)
- func (m *QueryPastDrawsRequest) GetPagination() *query.PageRequest
- func (m *QueryPastDrawsRequest) Marshal() (dAtA []byte, err error)
- func (m *QueryPastDrawsRequest) MarshalTo(dAtA []byte) (int, error)
- func (m *QueryPastDrawsRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*QueryPastDrawsRequest) ProtoMessage()
- func (m *QueryPastDrawsRequest) Reset()
- func (m *QueryPastDrawsRequest) Size() (n int)
- func (m *QueryPastDrawsRequest) String() string
- func (m *QueryPastDrawsRequest) Unmarshal(dAtA []byte) error
- func (m *QueryPastDrawsRequest) XXX_DiscardUnknown()
- func (m *QueryPastDrawsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *QueryPastDrawsRequest) XXX_Merge(src proto.Message)
- func (m *QueryPastDrawsRequest) XXX_Size() int
- func (m *QueryPastDrawsRequest) XXX_Unmarshal(b []byte) error
- type QueryPastDrawsResponse
- func (*QueryPastDrawsResponse) Descriptor() ([]byte, []int)
- func (m *QueryPastDrawsResponse) GetDraws() []HistoricalDrawData
- func (m *QueryPastDrawsResponse) GetPagination() *query.PageResponse
- func (m *QueryPastDrawsResponse) Marshal() (dAtA []byte, err error)
- func (m *QueryPastDrawsResponse) MarshalTo(dAtA []byte) (int, error)
- func (m *QueryPastDrawsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*QueryPastDrawsResponse) ProtoMessage()
- func (m *QueryPastDrawsResponse) Reset()
- func (m *QueryPastDrawsResponse) Size() (n int)
- func (m *QueryPastDrawsResponse) String() string
- func (m *QueryPastDrawsResponse) Unmarshal(dAtA []byte) error
- func (m *QueryPastDrawsResponse) XXX_DiscardUnknown()
- func (m *QueryPastDrawsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *QueryPastDrawsResponse) XXX_Merge(src proto.Message)
- func (m *QueryPastDrawsResponse) XXX_Size() int
- func (m *QueryPastDrawsResponse) XXX_Unmarshal(b []byte) error
- type QueryServer
- type QueryTicketsRequest
- func (*QueryTicketsRequest) Descriptor() ([]byte, []int)
- func (m *QueryTicketsRequest) GetPagination() *query.PageRequest
- func (m *QueryTicketsRequest) Marshal() (dAtA []byte, err error)
- func (m *QueryTicketsRequest) MarshalTo(dAtA []byte) (int, error)
- func (m *QueryTicketsRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*QueryTicketsRequest) ProtoMessage()
- func (m *QueryTicketsRequest) Reset()
- func (m *QueryTicketsRequest) Size() (n int)
- func (m *QueryTicketsRequest) String() string
- func (m *QueryTicketsRequest) Unmarshal(dAtA []byte) error
- func (m *QueryTicketsRequest) XXX_DiscardUnknown()
- func (m *QueryTicketsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *QueryTicketsRequest) XXX_Merge(src proto.Message)
- func (m *QueryTicketsRequest) XXX_Size() int
- func (m *QueryTicketsRequest) XXX_Unmarshal(b []byte) error
- type QueryTicketsResponse
- func (*QueryTicketsResponse) Descriptor() ([]byte, []int)
- func (m *QueryTicketsResponse) GetPagination() *query.PageResponse
- func (m *QueryTicketsResponse) GetTickets() []Ticket
- func (m *QueryTicketsResponse) Marshal() (dAtA []byte, err error)
- func (m *QueryTicketsResponse) MarshalTo(dAtA []byte) (int, error)
- func (m *QueryTicketsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*QueryTicketsResponse) ProtoMessage()
- func (m *QueryTicketsResponse) Reset()
- func (m *QueryTicketsResponse) Size() (n int)
- func (m *QueryTicketsResponse) String() string
- func (m *QueryTicketsResponse) Unmarshal(dAtA []byte) error
- func (m *QueryTicketsResponse) XXX_DiscardUnknown()
- func (m *QueryTicketsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *QueryTicketsResponse) XXX_Merge(src proto.Message)
- func (m *QueryTicketsResponse) XXX_Size() int
- func (m *QueryTicketsResponse) XXX_Unmarshal(b []byte) error
- type Ticket
- func (*Ticket) Descriptor() ([]byte, []int)
- func (this *Ticket) Equal(that interface{}) bool
- func (m *Ticket) GetId() string
- func (m *Ticket) GetOwner() string
- func (m *Ticket) GetTimestamp() time.Time
- func (m *Ticket) Marshal() (dAtA []byte, err error)
- func (m *Ticket) MarshalTo(dAtA []byte) (int, error)
- func (m *Ticket) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*Ticket) ProtoMessage()
- func (m *Ticket) Reset()
- func (m *Ticket) Size() (n int)
- func (m *Ticket) String() string
- func (m *Ticket) Unmarshal(dAtA []byte) error
- func (t *Ticket) Validate() error
- func (m *Ticket) XXX_DiscardUnknown()
- func (m *Ticket) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Ticket) XXX_Merge(src proto.Message)
- func (m *Ticket) XXX_Size() int
- func (m *Ticket) XXX_Unmarshal(b []byte) error
- type TicketParams
- func (*TicketParams) Descriptor() ([]byte, []int)
- func (m *TicketParams) GetPrice() types.Coin
- func (m *TicketParams) Marshal() (dAtA []byte, err error)
- func (m *TicketParams) MarshalTo(dAtA []byte) (int, error)
- func (m *TicketParams) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*TicketParams) ProtoMessage()
- func (m *TicketParams) Reset()
- func (m *TicketParams) Size() (n int)
- func (m *TicketParams) String() string
- func (m *TicketParams) Unmarshal(dAtA []byte) error
- func (m *TicketParams) XXX_DiscardUnknown()
- func (m *TicketParams) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *TicketParams) XXX_Merge(src proto.Message)
- func (m *TicketParams) XXX_Size() int
- func (m *TicketParams) XXX_Unmarshal(b []byte) error
- type UnimplementedMsgServer
- type UnimplementedQueryServer
- func (*UnimplementedQueryServer) NextDraw(ctx context.Context, req *QueryNextDrawRequest) (*QueryNextDrawResponse, error)
- func (*UnimplementedQueryServer) Params(ctx context.Context, req *QueryParamsRequest) (*QueryParamsResponse, error)
- func (*UnimplementedQueryServer) PastDraws(ctx context.Context, req *QueryPastDrawsRequest) (*QueryPastDrawsResponse, error)
- func (*UnimplementedQueryServer) Tickets(ctx context.Context, req *QueryTicketsRequest) (*QueryTicketsResponse, error)
Constants ¶
const ( EventTypeBuyTicket = "buy_ticket" EventTypePrizeIncrease = "prize_increase" EventTypeWinnerDrawn = "winner_drawn" EventTypeNewDraw = "new_draw" AttributeKeyTicketID = "ticket_id" AttributeKeyTicketBuyer = "ticket_buyer" AttributeKeyTicketTimestamp = "ticket_timestamp" AttributeKeyPrizeAmount = "prize_amount" AttributeKeyWinnerAddress = "winner_address" AttributeKeyWonAmount = "won_amount" AttributeKeyDrawClosing = "draw_closing" )
const ( // ModuleName is the name of the wta module ModuleName = "wta" // StoreKey is the string store representation StoreKey = ModuleName // QuerierRoute is the querier route for the wta module QuerierRoute = ModuleName // RouterKey is the msg router key for the wta module RouterKey = ModuleName PrizeCollectorName = "wta_prize_collector" PrizeBurnerName = "wta_prize_burner" )
const ( // Default draw duration DefaultDrawDuration = time.Hour // Min draw duration MinDrawDuration = time.Minute )
const (
TypeMsgBuyTickets = "buy_tickets"
)
Variables ¶
var ( ErrInvalidLengthGenesis = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowGenesis = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupGenesis = fmt.Errorf("proto: unexpected end of group") )
var ( CurrentDrawEndTimeStoreKey = []byte{0x1} HistoricalDrawStorePrefix = []byte("historical_draw") TicketsStorePrefix = []byte("ticket") )
var ( ErrInvalidLengthModels = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowModels = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupModels = fmt.Errorf("proto: unexpected end of group") )
var ( ErrInvalidLengthMsgs = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowMsgs = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupMsgs = fmt.Errorf("proto: unexpected end of group") )
var ( DefaultPrizePercentage = sdk.NewDecWithPrec(98, 2) // 98% DefaultBurnPercentage = sdk.NewDecWithPrec(1, 2) // 1% DefaultFeePercentage = sdk.NewDecWithPrec(1, 2) // 1% DefaultTicketPrice = sdk.NewCoin(sdk.DefaultBondDenom, sdk.TokensFromConsensusPower(10)) // 10 Tokens )
Default wta params
var ( ParamStoreDistributionParamsKey = []byte("DistributionParams") ParamStoreDrawParamsKey = []byte("DrawParams") ParamStoreTicketParamsKey = []byte("TicketParams") )
Parameters store keys
var ( ErrInvalidLengthParams = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowParams = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupParams = fmt.Errorf("proto: unexpected end of group") )
var ( ErrInvalidLengthQuery = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowQuery = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupQuery = fmt.Errorf("proto: unexpected end of group") )
var ( // ModuleCdc references the global x/wda 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/wda and // defined at the application level. ModuleCdc = codec.NewAminoCodec(amino) )
Functions ¶
func HistoricalDataStoreKey ¶
HistoricalDataStoreKey returns the store key used to save a historical data entry with the given timestamp
func IsTicketIDDuplicated ¶
IsTicketIDDuplicated tells whether or not the given id is duplicated inside the provided slice
func MarshalHistoricalDraw ¶
func MarshalHistoricalDraw(cdc codec.BinaryMarshaler, draw HistoricalDrawData) ([]byte, error)
MarshalHistoricalDraw marshals the given historical draw as a byte array
func MarshalTicket ¶
func MarshalTicket(cdc codec.BinaryMarshaler, ticket Ticket) ([]byte, error)
MarshalTicket marshals the given ticket to a slice of bytes
func MustMarshalDrawEndTime ¶ added in v0.1.1
MustMarshalDraw marshals the given time.Time as a byte array and panics on error
func MustMarshalHistoricalDraw ¶
func MustMarshalHistoricalDraw(cdc codec.BinaryMarshaler, draw HistoricalDrawData) []byte
MustMarshalHistoricalDraw marshals the given draws as a byte array
func MustMarshalTicket ¶
func MustMarshalTicket(cdc codec.BinaryMarshaler, ticket Ticket) []byte
MustMarshalTicket marshals the given ticket into a slice of bytes, and panics on error
func MustUnmarshalDrawEndTime ¶ added in v0.1.1
MustUnmarshalDraw unmarshals the given byte slice into a time.Time object
func NewRandFromCtx ¶
NewRandFromCtx returns a new rand.Rand based on the given context
func NewRandFromCtxAndIndex ¶
NewRandFromCtxAndIndex returns a new rand.Rand based on the given context and index
func NewRandFromSeed ¶
NewRandFromSeed returns a new deterministic rand.Rand using the given byte slice as seed
func ParamKeyTable ¶
func ParamKeyTable() paramstypes.KeyTable
ParamKeyTable Key declaration for parameters
func RegisterInterfaces ¶
func RegisterInterfaces(registry types.InterfaceRegistry)
func RegisterLegacyAminoCodec ¶
func RegisterLegacyAminoCodec(cdc *codec.LegacyAmino)
func RegisterMsgServer ¶
func RegisterQueryHandler ¶
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 (such as grpc.SendHeader, etc) to stop working. Consider using RegisterQueryHandlerFromEndpoint instead.
func RegisterQueryServer ¶
func RegisterQueryServer(s grpc1.Server, srv QueryServer)
func TicketsStoreKey ¶
TicketsStoreKey returns the store key used to save the ticket with the given id
func ValidateDistributionParams ¶ added in v0.1.1
func ValidateDistributionParams(i interface{}) error
func ValidateDrawParams ¶ added in v0.1.1
func ValidateDrawParams(i interface{}) error
func ValidateGenesis ¶
func ValidateGenesis(state *GenesisState) error
ValidateGenesis validates the given genesis state and returns an error if something is invalid
func ValidateTicketParams ¶ added in v0.1.1
func ValidateTicketParams(i interface{}) error
Types ¶
type DistributionParams ¶ added in v0.1.1
type DistributionParams struct { // Percentage of the ticket cost that should be sent to the prize pool, // represented as a value between 0.00 and 1.00. PrizePercentage github_com_cosmos_cosmos_sdk_types.Dec `` /* 146-byte string literal not displayed */ // Percentage of the ticket cost that should be burnt, // represented as a value between 0.00 and 1.00. BurnPercentage github_com_cosmos_cosmos_sdk_types.Dec `` /* 143-byte string literal not displayed */ // Percentage of the ticket cost that should be considered as a fee, // represented as a value between 0.00 and 1.00. FeePercentage github_com_cosmos_cosmos_sdk_types.Dec `` /* 140-byte string literal not displayed */ }
DistributionParams contains the parameters of the distribution of the prize
func DefaultDistributionParams ¶ added in v0.1.1
func DefaultDistributionParams() DistributionParams
func NewDistributionParams ¶ added in v0.1.1
func NewDistributionParams(prizePercentage, feePercentage, burnPercentage sdk.Dec) DistributionParams
func (*DistributionParams) Descriptor ¶ added in v0.1.1
func (*DistributionParams) Descriptor() ([]byte, []int)
func (*DistributionParams) Marshal ¶ added in v0.1.1
func (m *DistributionParams) Marshal() (dAtA []byte, err error)
func (*DistributionParams) MarshalTo ¶ added in v0.1.1
func (m *DistributionParams) MarshalTo(dAtA []byte) (int, error)
func (*DistributionParams) MarshalToSizedBuffer ¶ added in v0.1.1
func (m *DistributionParams) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*DistributionParams) ProtoMessage ¶ added in v0.1.1
func (*DistributionParams) ProtoMessage()
func (*DistributionParams) Reset ¶ added in v0.1.1
func (m *DistributionParams) Reset()
func (*DistributionParams) Size ¶ added in v0.1.1
func (m *DistributionParams) Size() (n int)
func (*DistributionParams) String ¶ added in v0.1.1
func (m *DistributionParams) String() string
func (*DistributionParams) Unmarshal ¶ added in v0.1.1
func (m *DistributionParams) Unmarshal(dAtA []byte) error
func (*DistributionParams) XXX_DiscardUnknown ¶ added in v0.1.1
func (m *DistributionParams) XXX_DiscardUnknown()
func (*DistributionParams) XXX_Marshal ¶ added in v0.1.1
func (m *DistributionParams) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*DistributionParams) XXX_Merge ¶ added in v0.1.1
func (m *DistributionParams) XXX_Merge(src proto.Message)
func (*DistributionParams) XXX_Size ¶ added in v0.1.1
func (m *DistributionParams) XXX_Size() int
func (*DistributionParams) XXX_Unmarshal ¶ added in v0.1.1
func (m *DistributionParams) XXX_Unmarshal(b []byte) error
type Draw ¶
type Draw struct { Participants uint32 `protobuf:"varint,1,opt,name=participants,proto3" json:"participants,omitempty"` TicketsSold uint32 `protobuf:"varint,2,opt,name=tickets_sold,json=ticketsSold,proto3" json:"tickets_sold,omitempty"` Prize github_com_cosmos_cosmos_sdk_types.Coins `protobuf:"bytes,3,rep,name=prize,proto3,castrepeated=github.com/cosmos/cosmos-sdk/types.Coins" json:"prize"` EndTime time.Time `protobuf:"bytes,4,opt,name=end_time,json=endTime,proto3,stdtime" json:"end_time"` }
Draw contains the data of the next planned draw
func (*Draw) Descriptor ¶
func (*Draw) GetEndTime ¶
func (*Draw) GetParticipants ¶
func (*Draw) GetPrize ¶
func (m *Draw) GetPrize() github_com_cosmos_cosmos_sdk_types.Coins
func (*Draw) GetTicketsSold ¶
func (*Draw) ProtoMessage ¶
func (*Draw) ProtoMessage()
func (*Draw) XXX_DiscardUnknown ¶
func (m *Draw) XXX_DiscardUnknown()
func (*Draw) XXX_Unmarshal ¶
type DrawParams ¶ added in v0.1.1
type DrawParams struct { // Duration of each draw, after which the winner is picked and a new draw is // created Duration time.Duration `protobuf:"bytes,4,opt,name=duration,proto3,stdduration" json:"duration"` }
DrawParams contain the parameters for each draw
func DefaultDrawParams ¶ added in v0.1.1
func DefaultDrawParams() DrawParams
func NewDrawParams ¶ added in v0.1.1
func NewDrawParams(duration time.Duration) DrawParams
func (*DrawParams) Descriptor ¶ added in v0.1.1
func (*DrawParams) Descriptor() ([]byte, []int)
func (*DrawParams) GetDuration ¶ added in v0.1.1
func (m *DrawParams) GetDuration() time.Duration
func (*DrawParams) Marshal ¶ added in v0.1.1
func (m *DrawParams) Marshal() (dAtA []byte, err error)
func (*DrawParams) MarshalTo ¶ added in v0.1.1
func (m *DrawParams) MarshalTo(dAtA []byte) (int, error)
func (*DrawParams) MarshalToSizedBuffer ¶ added in v0.1.1
func (m *DrawParams) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*DrawParams) ProtoMessage ¶ added in v0.1.1
func (*DrawParams) ProtoMessage()
func (*DrawParams) Reset ¶ added in v0.1.1
func (m *DrawParams) Reset()
func (*DrawParams) Size ¶ added in v0.1.1
func (m *DrawParams) Size() (n int)
func (*DrawParams) String ¶ added in v0.1.1
func (m *DrawParams) String() string
func (*DrawParams) Unmarshal ¶ added in v0.1.1
func (m *DrawParams) Unmarshal(dAtA []byte) error
func (*DrawParams) XXX_DiscardUnknown ¶ added in v0.1.1
func (m *DrawParams) XXX_DiscardUnknown()
func (*DrawParams) XXX_Marshal ¶ added in v0.1.1
func (m *DrawParams) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*DrawParams) XXX_Merge ¶ added in v0.1.1
func (m *DrawParams) XXX_Merge(src proto.Message)
func (*DrawParams) XXX_Size ¶ added in v0.1.1
func (m *DrawParams) XXX_Size() int
func (*DrawParams) XXX_Unmarshal ¶ added in v0.1.1
func (m *DrawParams) XXX_Unmarshal(b []byte) error
type GenesisState ¶
type GenesisState struct { // Defines the end time of the next draw DrawEndTime time.Time `protobuf:"bytes,1,opt,name=draw_end_time,json=drawEndTime,proto3,stdtime" json:"draw_end_time"` // Defines all the tickets present at genesis time Tickets []Ticket `protobuf:"bytes,2,rep,name=tickets,proto3" json:"tickets"` // Defines the past draws present at genesis time PastDraws []HistoricalDrawData `protobuf:"bytes,3,rep,name=past_draws,json=pastDraws,proto3" json:"past_draws"` // Represents the parameters related to the prize distribution DistributionParams DistributionParams `protobuf:"bytes,4,opt,name=distribution_params,json=distributionParams,proto3" json:"distribution_params"` // Represents the parameters related to each draw DrawParams DrawParams `protobuf:"bytes,5,opt,name=draw_params,json=drawParams,proto3" json:"draw_params"` // Represents the parameters related to each ticket TicketParams TicketParams `protobuf:"bytes,6,opt,name=ticket_params,json=ticketParams,proto3" json:"ticket_params"` }
GenesisState contains the data of the genesis state for the wda module
func DefaultGenesisState ¶
func DefaultGenesisState() *GenesisState
DefaultGenesisState returns a default GenesisState
func NewGenesisState ¶
func NewGenesisState( drawEndTime time.Time, tickets []Ticket, pastDraws []HistoricalDrawData, distributionParams DistributionParams, drawParams DrawParams, ticketParams TicketParams, ) *GenesisState
NewGenesisState returns a new GenesisState containing the provided data
func (*GenesisState) Descriptor ¶
func (*GenesisState) Descriptor() ([]byte, []int)
func (*GenesisState) GetDistributionParams ¶ added in v0.1.1
func (m *GenesisState) GetDistributionParams() DistributionParams
func (*GenesisState) GetDrawEndTime ¶ added in v0.1.1
func (m *GenesisState) GetDrawEndTime() time.Time
func (*GenesisState) GetDrawParams ¶ added in v0.1.1
func (m *GenesisState) GetDrawParams() DrawParams
func (*GenesisState) GetPastDraws ¶
func (m *GenesisState) GetPastDraws() []HistoricalDrawData
func (*GenesisState) GetTicketParams ¶ added in v0.1.1
func (m *GenesisState) GetTicketParams() TicketParams
func (*GenesisState) GetTickets ¶
func (m *GenesisState) GetTickets() []Ticket
func (*GenesisState) Marshal ¶
func (m *GenesisState) Marshal() (dAtA []byte, err 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 HistoricalDrawData ¶
type HistoricalDrawData struct { Draw Draw `protobuf:"bytes,1,opt,name=draw,proto3" json:"draw"` WinningTicket Ticket `protobuf:"bytes,2,opt,name=winning_ticket,json=winningTicket,proto3" json:"winning_ticket"` }
HistoricalDrawData contains the data of a past draw and its winner
func MustUnmarshalHistoricalDrawData ¶
func MustUnmarshalHistoricalDrawData(cdc codec.BinaryMarshaler, bz []byte) HistoricalDrawData
MustUnmarshalHistoricalDrawData unmarshals the given byte array as a HistoricalDrawData object and panics on errors
func NewHistoricalDrawData ¶
func NewHistoricalDrawData(draw Draw, winningTicket Ticket) HistoricalDrawData
NewHistoricalDrawData creates a new HistoricalDrawData
func UnmarshalHistoricalDraw ¶
func UnmarshalHistoricalDraw(cdc codec.BinaryMarshaler, bz []byte) (HistoricalDrawData, error)
UnmarshalHistoricalDraw unmarshals the given byte array as a HistoricalDrawData object
func (*HistoricalDrawData) Descriptor ¶
func (*HistoricalDrawData) Descriptor() ([]byte, []int)
func (*HistoricalDrawData) GetDraw ¶
func (m *HistoricalDrawData) GetDraw() Draw
func (*HistoricalDrawData) GetWinningTicket ¶
func (m *HistoricalDrawData) GetWinningTicket() Ticket
func (*HistoricalDrawData) Marshal ¶
func (m *HistoricalDrawData) Marshal() (dAtA []byte, err error)
func (*HistoricalDrawData) MarshalTo ¶
func (m *HistoricalDrawData) MarshalTo(dAtA []byte) (int, error)
func (*HistoricalDrawData) MarshalToSizedBuffer ¶
func (m *HistoricalDrawData) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*HistoricalDrawData) ProtoMessage ¶
func (*HistoricalDrawData) ProtoMessage()
func (*HistoricalDrawData) Reset ¶
func (m *HistoricalDrawData) Reset()
func (*HistoricalDrawData) Size ¶
func (m *HistoricalDrawData) Size() (n int)
func (*HistoricalDrawData) String ¶
func (m *HistoricalDrawData) String() string
func (*HistoricalDrawData) Unmarshal ¶
func (m *HistoricalDrawData) Unmarshal(dAtA []byte) error
func (*HistoricalDrawData) Validate ¶
func (h *HistoricalDrawData) Validate() error
func (*HistoricalDrawData) XXX_DiscardUnknown ¶
func (m *HistoricalDrawData) XXX_DiscardUnknown()
func (*HistoricalDrawData) XXX_Marshal ¶
func (m *HistoricalDrawData) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*HistoricalDrawData) XXX_Merge ¶
func (m *HistoricalDrawData) XXX_Merge(src proto.Message)
func (*HistoricalDrawData) XXX_Size ¶
func (m *HistoricalDrawData) XXX_Size() int
func (*HistoricalDrawData) XXX_Unmarshal ¶
func (m *HistoricalDrawData) XXX_Unmarshal(b []byte) error
type MsgBuyTickets ¶
type MsgBuyTickets struct { Quantity uint32 `protobuf:"varint,1,opt,name=quantity,proto3" json:"quantity,omitempty" yaml:"quantity"` Buyer string `protobuf:"bytes,2,opt,name=buyer,proto3" json:"buyer,omitempty" yaml:"buyer"` }
MsgBuyTickets represents the message to use to buy one or more lottery tickets.
func NewMsgBuyTickets ¶
func NewMsgBuyTickets(quantity uint32, user string) *MsgBuyTickets
NewMsgBuyTickets allows to build a new MsgBuyTickets instance
func (*MsgBuyTickets) Descriptor ¶
func (*MsgBuyTickets) Descriptor() ([]byte, []int)
func (*MsgBuyTickets) GetSignBytes ¶
func (m *MsgBuyTickets) GetSignBytes() []byte
GetSignBytes implements sdk.Msg
func (*MsgBuyTickets) GetSigners ¶
func (m *MsgBuyTickets) GetSigners() []sdk.AccAddress
GetSigners implements sdk.Msg
func (*MsgBuyTickets) Marshal ¶
func (m *MsgBuyTickets) Marshal() (dAtA []byte, err error)
func (*MsgBuyTickets) MarshalToSizedBuffer ¶
func (m *MsgBuyTickets) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*MsgBuyTickets) ProtoMessage ¶
func (*MsgBuyTickets) ProtoMessage()
func (*MsgBuyTickets) Reset ¶
func (m *MsgBuyTickets) Reset()
func (*MsgBuyTickets) Size ¶
func (m *MsgBuyTickets) Size() (n int)
func (*MsgBuyTickets) String ¶
func (m *MsgBuyTickets) String() string
func (*MsgBuyTickets) Unmarshal ¶
func (m *MsgBuyTickets) Unmarshal(dAtA []byte) error
func (*MsgBuyTickets) ValidateBasic ¶
func (m *MsgBuyTickets) ValidateBasic() error
ValidateBasic implements sdk.Msg
func (*MsgBuyTickets) XXX_DiscardUnknown ¶
func (m *MsgBuyTickets) XXX_DiscardUnknown()
func (*MsgBuyTickets) XXX_Marshal ¶
func (m *MsgBuyTickets) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*MsgBuyTickets) XXX_Merge ¶
func (m *MsgBuyTickets) XXX_Merge(src proto.Message)
func (*MsgBuyTickets) XXX_Size ¶
func (m *MsgBuyTickets) XXX_Size() int
func (*MsgBuyTickets) XXX_Unmarshal ¶
func (m *MsgBuyTickets) XXX_Unmarshal(b []byte) error
type MsgBuyTicketsResponse ¶
type MsgBuyTicketsResponse struct { }
MsgBuyTicketsResponse defines the Msg/BuyTickets response type.
func (*MsgBuyTicketsResponse) Descriptor ¶
func (*MsgBuyTicketsResponse) Descriptor() ([]byte, []int)
func (*MsgBuyTicketsResponse) Marshal ¶
func (m *MsgBuyTicketsResponse) Marshal() (dAtA []byte, err error)
func (*MsgBuyTicketsResponse) MarshalTo ¶
func (m *MsgBuyTicketsResponse) MarshalTo(dAtA []byte) (int, error)
func (*MsgBuyTicketsResponse) MarshalToSizedBuffer ¶
func (m *MsgBuyTicketsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*MsgBuyTicketsResponse) ProtoMessage ¶
func (*MsgBuyTicketsResponse) ProtoMessage()
func (*MsgBuyTicketsResponse) Reset ¶
func (m *MsgBuyTicketsResponse) Reset()
func (*MsgBuyTicketsResponse) Size ¶
func (m *MsgBuyTicketsResponse) Size() (n int)
func (*MsgBuyTicketsResponse) String ¶
func (m *MsgBuyTicketsResponse) String() string
func (*MsgBuyTicketsResponse) Unmarshal ¶
func (m *MsgBuyTicketsResponse) Unmarshal(dAtA []byte) error
func (*MsgBuyTicketsResponse) XXX_DiscardUnknown ¶
func (m *MsgBuyTicketsResponse) XXX_DiscardUnknown()
func (*MsgBuyTicketsResponse) XXX_Marshal ¶
func (m *MsgBuyTicketsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*MsgBuyTicketsResponse) XXX_Merge ¶
func (m *MsgBuyTicketsResponse) XXX_Merge(src proto.Message)
func (*MsgBuyTicketsResponse) XXX_Size ¶
func (m *MsgBuyTicketsResponse) XXX_Size() int
func (*MsgBuyTicketsResponse) XXX_Unmarshal ¶
func (m *MsgBuyTicketsResponse) XXX_Unmarshal(b []byte) error
type MsgClient ¶
type MsgClient interface { // BuyTickets defines the method to buy one or more lottery tickets BuyTickets(ctx context.Context, in *MsgBuyTickets, opts ...grpc.CallOption) (*MsgBuyTicketsResponse, 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 MsgServer ¶
type MsgServer interface { // BuyTickets defines the method to buy one or more lottery tickets BuyTickets(context.Context, *MsgBuyTickets) (*MsgBuyTicketsResponse, error) }
MsgServer is the server API for Msg service.
type QueryClient ¶
type QueryClient interface { // Tickets queries all the stored tickets for the next draw Tickets(ctx context.Context, in *QueryTicketsRequest, opts ...grpc.CallOption) (*QueryTicketsResponse, error) // NextDraw queries the next planned drawn NextDraw(ctx context.Context, in *QueryNextDrawRequest, opts ...grpc.CallOption) (*QueryNextDrawResponse, error) // PastDraws queries the past draws that have already been drawn PastDraws(ctx context.Context, in *QueryPastDrawsRequest, opts ...grpc.CallOption) (*QueryPastDrawsResponse, error) // Params queries the wta parameters Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, 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 QueryNextDrawRequest ¶
type QueryNextDrawRequest struct { }
QueryDrawRequest is the request type for the Query/Draw RPC method.
func (*QueryNextDrawRequest) Descriptor ¶
func (*QueryNextDrawRequest) Descriptor() ([]byte, []int)
func (*QueryNextDrawRequest) Marshal ¶
func (m *QueryNextDrawRequest) Marshal() (dAtA []byte, err error)
func (*QueryNextDrawRequest) MarshalTo ¶
func (m *QueryNextDrawRequest) MarshalTo(dAtA []byte) (int, error)
func (*QueryNextDrawRequest) MarshalToSizedBuffer ¶
func (m *QueryNextDrawRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*QueryNextDrawRequest) ProtoMessage ¶
func (*QueryNextDrawRequest) ProtoMessage()
func (*QueryNextDrawRequest) Reset ¶
func (m *QueryNextDrawRequest) Reset()
func (*QueryNextDrawRequest) Size ¶
func (m *QueryNextDrawRequest) Size() (n int)
func (*QueryNextDrawRequest) String ¶
func (m *QueryNextDrawRequest) String() string
func (*QueryNextDrawRequest) Unmarshal ¶
func (m *QueryNextDrawRequest) Unmarshal(dAtA []byte) error
func (*QueryNextDrawRequest) XXX_DiscardUnknown ¶
func (m *QueryNextDrawRequest) XXX_DiscardUnknown()
func (*QueryNextDrawRequest) XXX_Marshal ¶
func (m *QueryNextDrawRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*QueryNextDrawRequest) XXX_Merge ¶
func (m *QueryNextDrawRequest) XXX_Merge(src proto.Message)
func (*QueryNextDrawRequest) XXX_Size ¶
func (m *QueryNextDrawRequest) XXX_Size() int
func (*QueryNextDrawRequest) XXX_Unmarshal ¶
func (m *QueryNextDrawRequest) XXX_Unmarshal(b []byte) error
type QueryNextDrawResponse ¶
type QueryNextDrawResponse struct {
Draw Draw `protobuf:"bytes,1,opt,name=draw,proto3" json:"draw"`
}
QueryDrawResponse is the response type for the Query/Draw RPC method
func (*QueryNextDrawResponse) Descriptor ¶
func (*QueryNextDrawResponse) Descriptor() ([]byte, []int)
func (*QueryNextDrawResponse) GetDraw ¶
func (m *QueryNextDrawResponse) GetDraw() Draw
func (*QueryNextDrawResponse) Marshal ¶
func (m *QueryNextDrawResponse) Marshal() (dAtA []byte, err error)
func (*QueryNextDrawResponse) MarshalTo ¶
func (m *QueryNextDrawResponse) MarshalTo(dAtA []byte) (int, error)
func (*QueryNextDrawResponse) MarshalToSizedBuffer ¶
func (m *QueryNextDrawResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*QueryNextDrawResponse) ProtoMessage ¶
func (*QueryNextDrawResponse) ProtoMessage()
func (*QueryNextDrawResponse) Reset ¶
func (m *QueryNextDrawResponse) Reset()
func (*QueryNextDrawResponse) Size ¶
func (m *QueryNextDrawResponse) Size() (n int)
func (*QueryNextDrawResponse) String ¶
func (m *QueryNextDrawResponse) String() string
func (*QueryNextDrawResponse) Unmarshal ¶
func (m *QueryNextDrawResponse) Unmarshal(dAtA []byte) error
func (*QueryNextDrawResponse) XXX_DiscardUnknown ¶
func (m *QueryNextDrawResponse) XXX_DiscardUnknown()
func (*QueryNextDrawResponse) XXX_Marshal ¶
func (m *QueryNextDrawResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*QueryNextDrawResponse) XXX_Merge ¶
func (m *QueryNextDrawResponse) XXX_Merge(src proto.Message)
func (*QueryNextDrawResponse) XXX_Size ¶
func (m *QueryNextDrawResponse) XXX_Size() int
func (*QueryNextDrawResponse) XXX_Unmarshal ¶
func (m *QueryNextDrawResponse) XXX_Unmarshal(b []byte) error
type QueryParamsRequest ¶
type QueryParamsRequest struct { }
QueryParamsRequest is the request type for the Query/Params RPC method.
func (*QueryParamsRequest) Descriptor ¶
func (*QueryParamsRequest) Descriptor() ([]byte, []int)
func (*QueryParamsRequest) Marshal ¶
func (m *QueryParamsRequest) Marshal() (dAtA []byte, err error)
func (*QueryParamsRequest) MarshalTo ¶
func (m *QueryParamsRequest) MarshalTo(dAtA []byte) (int, error)
func (*QueryParamsRequest) MarshalToSizedBuffer ¶
func (m *QueryParamsRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*QueryParamsRequest) ProtoMessage ¶
func (*QueryParamsRequest) ProtoMessage()
func (*QueryParamsRequest) Reset ¶
func (m *QueryParamsRequest) Reset()
func (*QueryParamsRequest) Size ¶
func (m *QueryParamsRequest) Size() (n int)
func (*QueryParamsRequest) String ¶
func (m *QueryParamsRequest) String() string
func (*QueryParamsRequest) Unmarshal ¶
func (m *QueryParamsRequest) Unmarshal(dAtA []byte) error
func (*QueryParamsRequest) XXX_DiscardUnknown ¶
func (m *QueryParamsRequest) XXX_DiscardUnknown()
func (*QueryParamsRequest) XXX_Marshal ¶
func (m *QueryParamsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*QueryParamsRequest) XXX_Merge ¶
func (m *QueryParamsRequest) XXX_Merge(src proto.Message)
func (*QueryParamsRequest) XXX_Size ¶
func (m *QueryParamsRequest) XXX_Size() int
func (*QueryParamsRequest) XXX_Unmarshal ¶
func (m *QueryParamsRequest) XXX_Unmarshal(b []byte) error
type QueryParamsResponse ¶
type QueryParamsResponse struct { // Represents the parameters related to the prize distribution DistributionParams DistributionParams `protobuf:"bytes,1,opt,name=distribution_params,json=distributionParams,proto3" json:"distribution_params"` // Represents the parameters related to each draw DrawParams DrawParams `protobuf:"bytes,2,opt,name=draw_params,json=drawParams,proto3" json:"draw_params"` // Represents the parameters related to each ticket TicketParams TicketParams `protobuf:"bytes,3,opt,name=ticket_params,json=ticketParams,proto3" json:"ticket_params"` }
QueryParamsResponse is the response type for the Query/Params RPC method
func (*QueryParamsResponse) Descriptor ¶
func (*QueryParamsResponse) Descriptor() ([]byte, []int)
func (*QueryParamsResponse) GetDistributionParams ¶ added in v0.1.1
func (m *QueryParamsResponse) GetDistributionParams() DistributionParams
func (*QueryParamsResponse) GetDrawParams ¶ added in v0.1.1
func (m *QueryParamsResponse) GetDrawParams() DrawParams
func (*QueryParamsResponse) GetTicketParams ¶ added in v0.1.1
func (m *QueryParamsResponse) GetTicketParams() TicketParams
func (*QueryParamsResponse) Marshal ¶
func (m *QueryParamsResponse) Marshal() (dAtA []byte, err error)
func (*QueryParamsResponse) MarshalTo ¶
func (m *QueryParamsResponse) MarshalTo(dAtA []byte) (int, error)
func (*QueryParamsResponse) MarshalToSizedBuffer ¶
func (m *QueryParamsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*QueryParamsResponse) ProtoMessage ¶
func (*QueryParamsResponse) ProtoMessage()
func (*QueryParamsResponse) Reset ¶
func (m *QueryParamsResponse) Reset()
func (*QueryParamsResponse) Size ¶
func (m *QueryParamsResponse) Size() (n int)
func (*QueryParamsResponse) String ¶
func (m *QueryParamsResponse) String() string
func (*QueryParamsResponse) Unmarshal ¶
func (m *QueryParamsResponse) Unmarshal(dAtA []byte) error
func (*QueryParamsResponse) XXX_DiscardUnknown ¶
func (m *QueryParamsResponse) XXX_DiscardUnknown()
func (*QueryParamsResponse) XXX_Marshal ¶
func (m *QueryParamsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*QueryParamsResponse) XXX_Merge ¶
func (m *QueryParamsResponse) XXX_Merge(src proto.Message)
func (*QueryParamsResponse) XXX_Size ¶
func (m *QueryParamsResponse) XXX_Size() int
func (*QueryParamsResponse) XXX_Unmarshal ¶
func (m *QueryParamsResponse) XXX_Unmarshal(b []byte) error
type QueryPastDrawsRequest ¶
type QueryPastDrawsRequest struct { // pagination defines an optional pagination for the request. Pagination *query.PageRequest `protobuf:"bytes,1,opt,name=pagination,proto3" json:"pagination,omitempty"` }
QueryPastDrawsRequest is the request type for the Query/PastDraws RPC method.
func NewPastDrawsRequest ¶
func NewPastDrawsRequest(pagination *query.PageRequest) *QueryPastDrawsRequest
NewPastDrawsRequest returns a new QueryPastDrawsRequest with the provided pagination data
func (*QueryPastDrawsRequest) Descriptor ¶
func (*QueryPastDrawsRequest) Descriptor() ([]byte, []int)
func (*QueryPastDrawsRequest) GetPagination ¶
func (m *QueryPastDrawsRequest) GetPagination() *query.PageRequest
func (*QueryPastDrawsRequest) Marshal ¶
func (m *QueryPastDrawsRequest) Marshal() (dAtA []byte, err error)
func (*QueryPastDrawsRequest) MarshalTo ¶
func (m *QueryPastDrawsRequest) MarshalTo(dAtA []byte) (int, error)
func (*QueryPastDrawsRequest) MarshalToSizedBuffer ¶
func (m *QueryPastDrawsRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*QueryPastDrawsRequest) ProtoMessage ¶
func (*QueryPastDrawsRequest) ProtoMessage()
func (*QueryPastDrawsRequest) Reset ¶
func (m *QueryPastDrawsRequest) Reset()
func (*QueryPastDrawsRequest) Size ¶
func (m *QueryPastDrawsRequest) Size() (n int)
func (*QueryPastDrawsRequest) String ¶
func (m *QueryPastDrawsRequest) String() string
func (*QueryPastDrawsRequest) Unmarshal ¶
func (m *QueryPastDrawsRequest) Unmarshal(dAtA []byte) error
func (*QueryPastDrawsRequest) XXX_DiscardUnknown ¶
func (m *QueryPastDrawsRequest) XXX_DiscardUnknown()
func (*QueryPastDrawsRequest) XXX_Marshal ¶
func (m *QueryPastDrawsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*QueryPastDrawsRequest) XXX_Merge ¶
func (m *QueryPastDrawsRequest) XXX_Merge(src proto.Message)
func (*QueryPastDrawsRequest) XXX_Size ¶
func (m *QueryPastDrawsRequest) XXX_Size() int
func (*QueryPastDrawsRequest) XXX_Unmarshal ¶
func (m *QueryPastDrawsRequest) XXX_Unmarshal(b []byte) error
type QueryPastDrawsResponse ¶
type QueryPastDrawsResponse struct { Draws []HistoricalDrawData `protobuf:"bytes,1,rep,name=draws,proto3" json:"draws"` Pagination *query.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` }
QueryPastDrawsResponse is the response type for the Query/PastDraws RPC method
func (*QueryPastDrawsResponse) Descriptor ¶
func (*QueryPastDrawsResponse) Descriptor() ([]byte, []int)
func (*QueryPastDrawsResponse) GetDraws ¶
func (m *QueryPastDrawsResponse) GetDraws() []HistoricalDrawData
func (*QueryPastDrawsResponse) GetPagination ¶
func (m *QueryPastDrawsResponse) GetPagination() *query.PageResponse
func (*QueryPastDrawsResponse) Marshal ¶
func (m *QueryPastDrawsResponse) Marshal() (dAtA []byte, err error)
func (*QueryPastDrawsResponse) MarshalTo ¶
func (m *QueryPastDrawsResponse) MarshalTo(dAtA []byte) (int, error)
func (*QueryPastDrawsResponse) MarshalToSizedBuffer ¶
func (m *QueryPastDrawsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*QueryPastDrawsResponse) ProtoMessage ¶
func (*QueryPastDrawsResponse) ProtoMessage()
func (*QueryPastDrawsResponse) Reset ¶
func (m *QueryPastDrawsResponse) Reset()
func (*QueryPastDrawsResponse) Size ¶
func (m *QueryPastDrawsResponse) Size() (n int)
func (*QueryPastDrawsResponse) String ¶
func (m *QueryPastDrawsResponse) String() string
func (*QueryPastDrawsResponse) Unmarshal ¶
func (m *QueryPastDrawsResponse) Unmarshal(dAtA []byte) error
func (*QueryPastDrawsResponse) XXX_DiscardUnknown ¶
func (m *QueryPastDrawsResponse) XXX_DiscardUnknown()
func (*QueryPastDrawsResponse) XXX_Marshal ¶
func (m *QueryPastDrawsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*QueryPastDrawsResponse) XXX_Merge ¶
func (m *QueryPastDrawsResponse) XXX_Merge(src proto.Message)
func (*QueryPastDrawsResponse) XXX_Size ¶
func (m *QueryPastDrawsResponse) XXX_Size() int
func (*QueryPastDrawsResponse) XXX_Unmarshal ¶
func (m *QueryPastDrawsResponse) XXX_Unmarshal(b []byte) error
type QueryServer ¶
type QueryServer interface { // Tickets queries all the stored tickets for the next draw Tickets(context.Context, *QueryTicketsRequest) (*QueryTicketsResponse, error) // NextDraw queries the next planned drawn NextDraw(context.Context, *QueryNextDrawRequest) (*QueryNextDrawResponse, error) // PastDraws queries the past draws that have already been drawn PastDraws(context.Context, *QueryPastDrawsRequest) (*QueryPastDrawsResponse, error) // Params queries the wta parameters Params(context.Context, *QueryParamsRequest) (*QueryParamsResponse, error) }
QueryServer is the server API for Query service.
type QueryTicketsRequest ¶
type QueryTicketsRequest struct { // pagination defines an optional pagination for the request. Pagination *query.PageRequest `protobuf:"bytes,1,opt,name=pagination,proto3" json:"pagination,omitempty"` }
QueryTicketsRequest is the request type for the Query/Tickets RPC method.
func NewTicketsRequest ¶
func NewTicketsRequest(pagination *query.PageRequest) *QueryTicketsRequest
NewTicketsRequest returns a new QueryTicketsRequest with the provided pagination data
func (*QueryTicketsRequest) Descriptor ¶
func (*QueryTicketsRequest) Descriptor() ([]byte, []int)
func (*QueryTicketsRequest) GetPagination ¶
func (m *QueryTicketsRequest) GetPagination() *query.PageRequest
func (*QueryTicketsRequest) Marshal ¶
func (m *QueryTicketsRequest) Marshal() (dAtA []byte, err error)
func (*QueryTicketsRequest) MarshalTo ¶
func (m *QueryTicketsRequest) MarshalTo(dAtA []byte) (int, error)
func (*QueryTicketsRequest) MarshalToSizedBuffer ¶
func (m *QueryTicketsRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*QueryTicketsRequest) ProtoMessage ¶
func (*QueryTicketsRequest) ProtoMessage()
func (*QueryTicketsRequest) Reset ¶
func (m *QueryTicketsRequest) Reset()
func (*QueryTicketsRequest) Size ¶
func (m *QueryTicketsRequest) Size() (n int)
func (*QueryTicketsRequest) String ¶
func (m *QueryTicketsRequest) String() string
func (*QueryTicketsRequest) Unmarshal ¶
func (m *QueryTicketsRequest) Unmarshal(dAtA []byte) error
func (*QueryTicketsRequest) XXX_DiscardUnknown ¶
func (m *QueryTicketsRequest) XXX_DiscardUnknown()
func (*QueryTicketsRequest) XXX_Marshal ¶
func (m *QueryTicketsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*QueryTicketsRequest) XXX_Merge ¶
func (m *QueryTicketsRequest) XXX_Merge(src proto.Message)
func (*QueryTicketsRequest) XXX_Size ¶
func (m *QueryTicketsRequest) XXX_Size() int
func (*QueryTicketsRequest) XXX_Unmarshal ¶
func (m *QueryTicketsRequest) XXX_Unmarshal(b []byte) error
type QueryTicketsResponse ¶
type QueryTicketsResponse struct { Tickets []Ticket `protobuf:"bytes,1,rep,name=tickets,proto3" json:"tickets"` Pagination *query.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` }
QueryTicketsResponse is the response type for the Query/Tickets RPC method
func (*QueryTicketsResponse) Descriptor ¶
func (*QueryTicketsResponse) Descriptor() ([]byte, []int)
func (*QueryTicketsResponse) GetPagination ¶
func (m *QueryTicketsResponse) GetPagination() *query.PageResponse
func (*QueryTicketsResponse) GetTickets ¶
func (m *QueryTicketsResponse) GetTickets() []Ticket
func (*QueryTicketsResponse) Marshal ¶
func (m *QueryTicketsResponse) Marshal() (dAtA []byte, err error)
func (*QueryTicketsResponse) MarshalTo ¶
func (m *QueryTicketsResponse) MarshalTo(dAtA []byte) (int, error)
func (*QueryTicketsResponse) MarshalToSizedBuffer ¶
func (m *QueryTicketsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*QueryTicketsResponse) ProtoMessage ¶
func (*QueryTicketsResponse) ProtoMessage()
func (*QueryTicketsResponse) Reset ¶
func (m *QueryTicketsResponse) Reset()
func (*QueryTicketsResponse) Size ¶
func (m *QueryTicketsResponse) Size() (n int)
func (*QueryTicketsResponse) String ¶
func (m *QueryTicketsResponse) String() string
func (*QueryTicketsResponse) Unmarshal ¶
func (m *QueryTicketsResponse) Unmarshal(dAtA []byte) error
func (*QueryTicketsResponse) XXX_DiscardUnknown ¶
func (m *QueryTicketsResponse) XXX_DiscardUnknown()
func (*QueryTicketsResponse) XXX_Marshal ¶
func (m *QueryTicketsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*QueryTicketsResponse) XXX_Merge ¶
func (m *QueryTicketsResponse) XXX_Merge(src proto.Message)
func (*QueryTicketsResponse) XXX_Size ¶
func (m *QueryTicketsResponse) XXX_Size() int
func (*QueryTicketsResponse) XXX_Unmarshal ¶
func (m *QueryTicketsResponse) XXX_Unmarshal(b []byte) error
type Ticket ¶
type Ticket 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"` Timestamp time.Time `protobuf:"bytes,3,opt,name=timestamp,proto3,stdtime" json:"timestamp"` }
Ticket represents a single entry for the next drawn
func MustUnmarshalTicket ¶
func MustUnmarshalTicket(cdc codec.BinaryMarshaler, bz []byte) Ticket
MustUnmarshalTicket unmarshals the given byte slice into a Ticket object, and panics on error
func UnmarshalTicket ¶
func UnmarshalTicket(cdc codec.BinaryMarshaler, bz []byte) (Ticket, error)
UnmarshalTicket reads the provided byte array as a Ticket object
func (*Ticket) Descriptor ¶
func (*Ticket) GetTimestamp ¶
func (*Ticket) MarshalToSizedBuffer ¶
func (*Ticket) ProtoMessage ¶
func (*Ticket) ProtoMessage()
func (*Ticket) XXX_DiscardUnknown ¶
func (m *Ticket) XXX_DiscardUnknown()
func (*Ticket) XXX_Marshal ¶
func (*Ticket) XXX_Unmarshal ¶
type TicketParams ¶ added in v0.1.1
type TicketParams struct { // Cost of an individual ticket Price types.Coin `protobuf:"bytes,5,opt,name=price,proto3" json:"price"` }
TicketParams contain the parameters for each ticket
func DefaultTicketParams ¶ added in v0.1.1
func DefaultTicketParams() TicketParams
func NewTicketParams ¶ added in v0.1.1
func NewTicketParams(price sdk.Coin) TicketParams
func (*TicketParams) Descriptor ¶ added in v0.1.1
func (*TicketParams) Descriptor() ([]byte, []int)
func (*TicketParams) GetPrice ¶ added in v0.1.1
func (m *TicketParams) GetPrice() types.Coin
func (*TicketParams) Marshal ¶ added in v0.1.1
func (m *TicketParams) Marshal() (dAtA []byte, err error)
func (*TicketParams) MarshalTo ¶ added in v0.1.1
func (m *TicketParams) MarshalTo(dAtA []byte) (int, error)
func (*TicketParams) MarshalToSizedBuffer ¶ added in v0.1.1
func (m *TicketParams) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*TicketParams) ProtoMessage ¶ added in v0.1.1
func (*TicketParams) ProtoMessage()
func (*TicketParams) Reset ¶ added in v0.1.1
func (m *TicketParams) Reset()
func (*TicketParams) Size ¶ added in v0.1.1
func (m *TicketParams) Size() (n int)
func (*TicketParams) String ¶ added in v0.1.1
func (m *TicketParams) String() string
func (*TicketParams) Unmarshal ¶ added in v0.1.1
func (m *TicketParams) Unmarshal(dAtA []byte) error
func (*TicketParams) XXX_DiscardUnknown ¶ added in v0.1.1
func (m *TicketParams) XXX_DiscardUnknown()
func (*TicketParams) XXX_Marshal ¶ added in v0.1.1
func (m *TicketParams) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*TicketParams) XXX_Merge ¶ added in v0.1.1
func (m *TicketParams) XXX_Merge(src proto.Message)
func (*TicketParams) XXX_Size ¶ added in v0.1.1
func (m *TicketParams) XXX_Size() int
func (*TicketParams) XXX_Unmarshal ¶ added in v0.1.1
func (m *TicketParams) XXX_Unmarshal(b []byte) error
type UnimplementedMsgServer ¶
type UnimplementedMsgServer struct { }
UnimplementedMsgServer can be embedded to have forward compatible implementations.
func (*UnimplementedMsgServer) BuyTickets ¶
func (*UnimplementedMsgServer) BuyTickets(ctx context.Context, req *MsgBuyTickets) (*MsgBuyTicketsResponse, error)
type UnimplementedQueryServer ¶
type UnimplementedQueryServer struct { }
UnimplementedQueryServer can be embedded to have forward compatible implementations.
func (*UnimplementedQueryServer) NextDraw ¶
func (*UnimplementedQueryServer) NextDraw(ctx context.Context, req *QueryNextDrawRequest) (*QueryNextDrawResponse, error)
func (*UnimplementedQueryServer) Params ¶
func (*UnimplementedQueryServer) Params(ctx context.Context, req *QueryParamsRequest) (*QueryParamsResponse, error)
func (*UnimplementedQueryServer) PastDraws ¶
func (*UnimplementedQueryServer) PastDraws(ctx context.Context, req *QueryPastDrawsRequest) (*QueryPastDrawsResponse, error)
func (*UnimplementedQueryServer) Tickets ¶
func (*UnimplementedQueryServer) Tickets(ctx context.Context, req *QueryTicketsRequest) (*QueryTicketsResponse, error)