Documentation ¶
Index ¶
- Constants
- Variables
- func IsValidProposalType(ty string) bool
- func RegisterInterfaces(registry types.InterfaceRegistry)
- func RegisterMsgServer(s grpc1.Server, srv MsgServer)
- func RegisterProposalType(ty string)
- func RegisterQueryServer(s grpc1.Server, srv QueryServer)
- func ValidProposalStatus(status ProposalStatus) bool
- func ValidVoteOption(option VoteOption) bool
- type Client
- type Content
- type Deposit
- func (d Deposit) Convert() interface{}
- func (*Deposit) Descriptor() ([]byte, []int)
- func (m *Deposit) Marshal() (dAtA []byte, err error)
- func (m *Deposit) MarshalTo(dAtA []byte) (int, error)
- func (m *Deposit) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*Deposit) ProtoMessage()
- func (m *Deposit) Reset()
- func (m *Deposit) Size() (n int)
- func (d Deposit) String() string
- func (m *Deposit) Unmarshal(dAtA []byte) error
- func (m *Deposit) XXX_DiscardUnknown()
- func (m *Deposit) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Deposit) XXX_Merge(src proto.Message)
- func (m *Deposit) XXX_Size() int
- func (m *Deposit) XXX_Unmarshal(b []byte) error
- type DepositParams
- func (*DepositParams) Descriptor() ([]byte, []int)
- func (m *DepositParams) Marshal() (dAtA []byte, err error)
- func (m *DepositParams) MarshalTo(dAtA []byte) (int, error)
- func (m *DepositParams) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*DepositParams) ProtoMessage()
- func (m *DepositParams) Reset()
- func (m *DepositParams) Size() (n int)
- func (dp DepositParams) String() string
- func (m *DepositParams) Unmarshal(dAtA []byte) error
- func (m *DepositParams) XXX_DiscardUnknown()
- func (m *DepositParams) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *DepositParams) XXX_Merge(src proto.Message)
- func (m *DepositParams) XXX_Size() int
- func (m *DepositParams) XXX_Unmarshal(b []byte) error
- type DepositRequest
- type Deposits
- type MsgClient
- type MsgDeposit
- func (*MsgDeposit) Descriptor() ([]byte, []int)
- func (msg MsgDeposit) GetSignBytes() []byte
- func (msg MsgDeposit) GetSigners() []sdk.AccAddress
- func (m *MsgDeposit) Marshal() (dAtA []byte, err error)
- func (m *MsgDeposit) MarshalTo(dAtA []byte) (int, error)
- func (m *MsgDeposit) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*MsgDeposit) ProtoMessage()
- func (m *MsgDeposit) Reset()
- func (msg MsgDeposit) Route() string
- func (m *MsgDeposit) Size() (n int)
- func (msg MsgDeposit) String() string
- func (msg MsgDeposit) Type() string
- func (m *MsgDeposit) Unmarshal(dAtA []byte) error
- func (msg MsgDeposit) ValidateBasic() error
- func (m *MsgDeposit) XXX_DiscardUnknown()
- func (m *MsgDeposit) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *MsgDeposit) XXX_Merge(src proto.Message)
- func (m *MsgDeposit) XXX_Size() int
- func (m *MsgDeposit) XXX_Unmarshal(b []byte) error
- type MsgDepositResponse
- func (*MsgDepositResponse) Descriptor() ([]byte, []int)
- func (m *MsgDepositResponse) Marshal() (dAtA []byte, err error)
- func (m *MsgDepositResponse) MarshalTo(dAtA []byte) (int, error)
- func (m *MsgDepositResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*MsgDepositResponse) ProtoMessage()
- func (m *MsgDepositResponse) Reset()
- func (m *MsgDepositResponse) Size() (n int)
- func (m *MsgDepositResponse) String() string
- func (m *MsgDepositResponse) Unmarshal(dAtA []byte) error
- func (m *MsgDepositResponse) XXX_DiscardUnknown()
- func (m *MsgDepositResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *MsgDepositResponse) XXX_Merge(src proto.Message)
- func (m *MsgDepositResponse) XXX_Size() int
- func (m *MsgDepositResponse) XXX_Unmarshal(b []byte) error
- type MsgServer
- type MsgSubmitProposal
- func (*MsgSubmitProposal) Descriptor() ([]byte, []int)
- func (m *MsgSubmitProposal) GetContent() Content
- func (m *MsgSubmitProposal) GetInitialDeposit() sdk.Coins
- func (m *MsgSubmitProposal) GetProposer() sdk.AccAddress
- func (m MsgSubmitProposal) GetSignBytes() []byte
- func (m MsgSubmitProposal) GetSigners() []sdk.AccAddress
- func (m *MsgSubmitProposal) Marshal() (dAtA []byte, err error)
- func (m *MsgSubmitProposal) MarshalTo(dAtA []byte) (int, error)
- func (m *MsgSubmitProposal) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*MsgSubmitProposal) ProtoMessage()
- func (m *MsgSubmitProposal) Reset()
- func (m MsgSubmitProposal) Route() string
- func (m *MsgSubmitProposal) SetContent(content Content) error
- func (m *MsgSubmitProposal) Size() (n int)
- func (m MsgSubmitProposal) String() string
- func (m MsgSubmitProposal) Type() string
- func (m *MsgSubmitProposal) Unmarshal(dAtA []byte) error
- func (m MsgSubmitProposal) UnpackInterfaces(unpacker types.AnyUnpacker) error
- func (m MsgSubmitProposal) ValidateBasic() error
- func (m *MsgSubmitProposal) XXX_DiscardUnknown()
- func (m *MsgSubmitProposal) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *MsgSubmitProposal) XXX_Merge(src proto.Message)
- func (m *MsgSubmitProposal) XXX_Size() int
- func (m *MsgSubmitProposal) XXX_Unmarshal(b []byte) error
- type MsgSubmitProposalResponse
- func (*MsgSubmitProposalResponse) Descriptor() ([]byte, []int)
- func (m *MsgSubmitProposalResponse) GetProposalId() uint64
- func (m *MsgSubmitProposalResponse) Marshal() (dAtA []byte, err error)
- func (m *MsgSubmitProposalResponse) MarshalTo(dAtA []byte) (int, error)
- func (m *MsgSubmitProposalResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*MsgSubmitProposalResponse) ProtoMessage()
- func (m *MsgSubmitProposalResponse) Reset()
- func (m *MsgSubmitProposalResponse) Size() (n int)
- func (m *MsgSubmitProposalResponse) String() string
- func (m *MsgSubmitProposalResponse) Unmarshal(dAtA []byte) error
- func (m *MsgSubmitProposalResponse) XXX_DiscardUnknown()
- func (m *MsgSubmitProposalResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *MsgSubmitProposalResponse) XXX_Merge(src proto.Message)
- func (m *MsgSubmitProposalResponse) XXX_Size() int
- func (m *MsgSubmitProposalResponse) XXX_Unmarshal(b []byte) error
- type MsgVote
- func (*MsgVote) Descriptor() ([]byte, []int)
- func (msg MsgVote) GetSignBytes() []byte
- func (msg MsgVote) GetSigners() []sdk.AccAddress
- func (m *MsgVote) Marshal() (dAtA []byte, err error)
- func (m *MsgVote) MarshalTo(dAtA []byte) (int, error)
- func (m *MsgVote) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*MsgVote) ProtoMessage()
- func (m *MsgVote) Reset()
- func (msg MsgVote) Route() string
- func (m *MsgVote) Size() (n int)
- func (msg MsgVote) String() string
- func (msg MsgVote) Type() string
- func (m *MsgVote) Unmarshal(dAtA []byte) error
- func (msg MsgVote) ValidateBasic() error
- func (m *MsgVote) XXX_DiscardUnknown()
- func (m *MsgVote) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *MsgVote) XXX_Merge(src proto.Message)
- func (m *MsgVote) XXX_Size() int
- func (m *MsgVote) XXX_Unmarshal(b []byte) error
- type MsgVoteResponse
- func (*MsgVoteResponse) Descriptor() ([]byte, []int)
- func (m *MsgVoteResponse) Marshal() (dAtA []byte, err error)
- func (m *MsgVoteResponse) MarshalTo(dAtA []byte) (int, error)
- func (m *MsgVoteResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*MsgVoteResponse) ProtoMessage()
- func (m *MsgVoteResponse) Reset()
- func (m *MsgVoteResponse) Size() (n int)
- func (m *MsgVoteResponse) String() string
- func (m *MsgVoteResponse) Unmarshal(dAtA []byte) error
- func (m *MsgVoteResponse) XXX_DiscardUnknown()
- func (m *MsgVoteResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *MsgVoteResponse) XXX_Merge(src proto.Message)
- func (m *MsgVoteResponse) XXX_Size() int
- func (m *MsgVoteResponse) XXX_Unmarshal(b []byte) error
- type Proposal
- func (q Proposal) Convert() interface{}
- func (*Proposal) Descriptor() ([]byte, []int)
- func (this *Proposal) Equal(that interface{}) bool
- func (p Proposal) GetContent() Content
- func (p Proposal) GetTitle() string
- func (m *Proposal) Marshal() (dAtA []byte, err error)
- func (m *Proposal) MarshalTo(dAtA []byte) (int, error)
- func (m *Proposal) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (p Proposal) ProposalRoute() string
- func (p Proposal) ProposalType() string
- func (*Proposal) ProtoMessage()
- func (m *Proposal) Reset()
- func (m *Proposal) Size() (n int)
- func (p Proposal) String() string
- func (m *Proposal) Unmarshal(dAtA []byte) error
- func (p Proposal) UnpackInterfaces(unpacker types.AnyUnpacker) error
- func (m *Proposal) XXX_DiscardUnknown()
- func (m *Proposal) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Proposal) XXX_Merge(src proto.Message)
- func (m *Proposal) XXX_Size() int
- func (m *Proposal) XXX_Unmarshal(b []byte) error
- type ProposalQueue
- type ProposalStatus
- type Proposals
- type QueryClient
- type QueryDepositRequest
- func (*QueryDepositRequest) Descriptor() ([]byte, []int)
- func (m *QueryDepositRequest) Marshal() (dAtA []byte, err error)
- func (m *QueryDepositRequest) MarshalTo(dAtA []byte) (int, error)
- func (m *QueryDepositRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*QueryDepositRequest) ProtoMessage()
- func (m *QueryDepositRequest) Reset()
- func (m *QueryDepositRequest) Size() (n int)
- func (m *QueryDepositRequest) String() string
- func (m *QueryDepositRequest) Unmarshal(dAtA []byte) error
- func (m *QueryDepositRequest) XXX_DiscardUnknown()
- func (m *QueryDepositRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *QueryDepositRequest) XXX_Merge(src proto.Message)
- func (m *QueryDepositRequest) XXX_Size() int
- func (m *QueryDepositRequest) XXX_Unmarshal(b []byte) error
- type QueryDepositResp
- type QueryDepositResponse
- func (*QueryDepositResponse) Descriptor() ([]byte, []int)
- func (m *QueryDepositResponse) GetDeposit() Deposit
- func (m *QueryDepositResponse) Marshal() (dAtA []byte, err error)
- func (m *QueryDepositResponse) MarshalTo(dAtA []byte) (int, error)
- func (m *QueryDepositResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*QueryDepositResponse) ProtoMessage()
- func (m *QueryDepositResponse) Reset()
- func (m *QueryDepositResponse) Size() (n int)
- func (m *QueryDepositResponse) String() string
- func (m *QueryDepositResponse) Unmarshal(dAtA []byte) error
- func (m *QueryDepositResponse) XXX_DiscardUnknown()
- func (m *QueryDepositResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *QueryDepositResponse) XXX_Merge(src proto.Message)
- func (m *QueryDepositResponse) XXX_Size() int
- func (m *QueryDepositResponse) XXX_Unmarshal(b []byte) error
- type QueryDepositsRequest
- func (*QueryDepositsRequest) Descriptor() ([]byte, []int)
- func (m *QueryDepositsRequest) GetPagination() *query.PageRequest
- func (m *QueryDepositsRequest) GetProposalId() uint64
- func (m *QueryDepositsRequest) Marshal() (dAtA []byte, err error)
- func (m *QueryDepositsRequest) MarshalTo(dAtA []byte) (int, error)
- func (m *QueryDepositsRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*QueryDepositsRequest) ProtoMessage()
- func (m *QueryDepositsRequest) Reset()
- func (m *QueryDepositsRequest) Size() (n int)
- func (m *QueryDepositsRequest) String() string
- func (m *QueryDepositsRequest) Unmarshal(dAtA []byte) error
- func (m *QueryDepositsRequest) XXX_DiscardUnknown()
- func (m *QueryDepositsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *QueryDepositsRequest) XXX_Merge(src proto.Message)
- func (m *QueryDepositsRequest) XXX_Size() int
- func (m *QueryDepositsRequest) XXX_Unmarshal(b []byte) error
- type QueryDepositsResponse
- func (*QueryDepositsResponse) Descriptor() ([]byte, []int)
- func (m *QueryDepositsResponse) GetDeposits() []Deposit
- func (m *QueryDepositsResponse) GetPagination() *query.PageResponse
- func (m *QueryDepositsResponse) Marshal() (dAtA []byte, err error)
- func (m *QueryDepositsResponse) MarshalTo(dAtA []byte) (int, error)
- func (m *QueryDepositsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*QueryDepositsResponse) ProtoMessage()
- func (m *QueryDepositsResponse) Reset()
- func (m *QueryDepositsResponse) Size() (n int)
- func (m *QueryDepositsResponse) String() string
- func (m *QueryDepositsResponse) Unmarshal(dAtA []byte) error
- func (m *QueryDepositsResponse) XXX_DiscardUnknown()
- func (m *QueryDepositsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *QueryDepositsResponse) XXX_Merge(src proto.Message)
- func (m *QueryDepositsResponse) XXX_Size() int
- func (m *QueryDepositsResponse) XXX_Unmarshal(b []byte) error
- type QueryParamsRequest
- func (*QueryParamsRequest) Descriptor() ([]byte, []int)
- func (m *QueryParamsRequest) GetParamsType() string
- 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 QueryParamsResp
- type QueryParamsResponse
- func (q QueryParamsResponse) Convert() interface{}
- func (*QueryParamsResponse) Descriptor() ([]byte, []int)
- func (m *QueryParamsResponse) GetDepositParams() DepositParams
- func (m *QueryParamsResponse) GetTallyParams() TallyParams
- func (m *QueryParamsResponse) GetVotingParams() VotingParams
- 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 QueryProposalRequest
- func (*QueryProposalRequest) Descriptor() ([]byte, []int)
- func (m *QueryProposalRequest) GetProposalId() uint64
- func (m *QueryProposalRequest) Marshal() (dAtA []byte, err error)
- func (m *QueryProposalRequest) MarshalTo(dAtA []byte) (int, error)
- func (m *QueryProposalRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*QueryProposalRequest) ProtoMessage()
- func (m *QueryProposalRequest) Reset()
- func (m *QueryProposalRequest) Size() (n int)
- func (m *QueryProposalRequest) String() string
- func (m *QueryProposalRequest) Unmarshal(dAtA []byte) error
- func (m *QueryProposalRequest) XXX_DiscardUnknown()
- func (m *QueryProposalRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *QueryProposalRequest) XXX_Merge(src proto.Message)
- func (m *QueryProposalRequest) XXX_Size() int
- func (m *QueryProposalRequest) XXX_Unmarshal(b []byte) error
- type QueryProposalResp
- type QueryProposalResponse
- func (*QueryProposalResponse) Descriptor() ([]byte, []int)
- func (m *QueryProposalResponse) GetProposal() Proposal
- func (m *QueryProposalResponse) Marshal() (dAtA []byte, err error)
- func (m *QueryProposalResponse) MarshalTo(dAtA []byte) (int, error)
- func (m *QueryProposalResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*QueryProposalResponse) ProtoMessage()
- func (m *QueryProposalResponse) Reset()
- func (m *QueryProposalResponse) Size() (n int)
- func (m *QueryProposalResponse) String() string
- func (m *QueryProposalResponse) Unmarshal(dAtA []byte) error
- func (m *QueryProposalResponse) XXX_DiscardUnknown()
- func (m *QueryProposalResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *QueryProposalResponse) XXX_Merge(src proto.Message)
- func (m *QueryProposalResponse) XXX_Size() int
- func (m *QueryProposalResponse) XXX_Unmarshal(b []byte) error
- type QueryProposalsRequest
- func (*QueryProposalsRequest) Descriptor() ([]byte, []int)
- func (m *QueryProposalsRequest) Marshal() (dAtA []byte, err error)
- func (m *QueryProposalsRequest) MarshalTo(dAtA []byte) (int, error)
- func (m *QueryProposalsRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*QueryProposalsRequest) ProtoMessage()
- func (m *QueryProposalsRequest) Reset()
- func (m *QueryProposalsRequest) Size() (n int)
- func (m *QueryProposalsRequest) String() string
- func (m *QueryProposalsRequest) Unmarshal(dAtA []byte) error
- func (m *QueryProposalsRequest) XXX_DiscardUnknown()
- func (m *QueryProposalsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *QueryProposalsRequest) XXX_Merge(src proto.Message)
- func (m *QueryProposalsRequest) XXX_Size() int
- func (m *QueryProposalsRequest) XXX_Unmarshal(b []byte) error
- type QueryProposalsResponse
- func (*QueryProposalsResponse) Descriptor() ([]byte, []int)
- func (m *QueryProposalsResponse) GetPagination() *query.PageResponse
- func (m *QueryProposalsResponse) GetProposals() []Proposal
- func (m *QueryProposalsResponse) Marshal() (dAtA []byte, err error)
- func (m *QueryProposalsResponse) MarshalTo(dAtA []byte) (int, error)
- func (m *QueryProposalsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*QueryProposalsResponse) ProtoMessage()
- func (m *QueryProposalsResponse) Reset()
- func (m *QueryProposalsResponse) Size() (n int)
- func (m *QueryProposalsResponse) String() string
- func (m *QueryProposalsResponse) Unmarshal(dAtA []byte) error
- func (m *QueryProposalsResponse) XXX_DiscardUnknown()
- func (m *QueryProposalsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *QueryProposalsResponse) XXX_Merge(src proto.Message)
- func (m *QueryProposalsResponse) XXX_Size() int
- func (m *QueryProposalsResponse) XXX_Unmarshal(b []byte) error
- type QueryServer
- type QueryTallyResultRequest
- func (*QueryTallyResultRequest) Descriptor() ([]byte, []int)
- func (m *QueryTallyResultRequest) GetProposalId() uint64
- func (m *QueryTallyResultRequest) Marshal() (dAtA []byte, err error)
- func (m *QueryTallyResultRequest) MarshalTo(dAtA []byte) (int, error)
- func (m *QueryTallyResultRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*QueryTallyResultRequest) ProtoMessage()
- func (m *QueryTallyResultRequest) Reset()
- func (m *QueryTallyResultRequest) Size() (n int)
- func (m *QueryTallyResultRequest) String() string
- func (m *QueryTallyResultRequest) Unmarshal(dAtA []byte) error
- func (m *QueryTallyResultRequest) XXX_DiscardUnknown()
- func (m *QueryTallyResultRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *QueryTallyResultRequest) XXX_Merge(src proto.Message)
- func (m *QueryTallyResultRequest) XXX_Size() int
- func (m *QueryTallyResultRequest) XXX_Unmarshal(b []byte) error
- type QueryTallyResultResp
- type QueryTallyResultResponse
- func (*QueryTallyResultResponse) Descriptor() ([]byte, []int)
- func (m *QueryTallyResultResponse) GetTally() TallyResult
- func (m *QueryTallyResultResponse) Marshal() (dAtA []byte, err error)
- func (m *QueryTallyResultResponse) MarshalTo(dAtA []byte) (int, error)
- func (m *QueryTallyResultResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*QueryTallyResultResponse) ProtoMessage()
- func (m *QueryTallyResultResponse) Reset()
- func (m *QueryTallyResultResponse) Size() (n int)
- func (m *QueryTallyResultResponse) String() string
- func (m *QueryTallyResultResponse) Unmarshal(dAtA []byte) error
- func (m *QueryTallyResultResponse) XXX_DiscardUnknown()
- func (m *QueryTallyResultResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *QueryTallyResultResponse) XXX_Merge(src proto.Message)
- func (m *QueryTallyResultResponse) XXX_Size() int
- func (m *QueryTallyResultResponse) XXX_Unmarshal(b []byte) error
- type QueryVoteRequest
- func (*QueryVoteRequest) Descriptor() ([]byte, []int)
- func (m *QueryVoteRequest) Marshal() (dAtA []byte, err error)
- func (m *QueryVoteRequest) MarshalTo(dAtA []byte) (int, error)
- func (m *QueryVoteRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*QueryVoteRequest) ProtoMessage()
- func (m *QueryVoteRequest) Reset()
- func (m *QueryVoteRequest) Size() (n int)
- func (m *QueryVoteRequest) String() string
- func (m *QueryVoteRequest) Unmarshal(dAtA []byte) error
- func (m *QueryVoteRequest) XXX_DiscardUnknown()
- func (m *QueryVoteRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *QueryVoteRequest) XXX_Merge(src proto.Message)
- func (m *QueryVoteRequest) XXX_Size() int
- func (m *QueryVoteRequest) XXX_Unmarshal(b []byte) error
- type QueryVoteResp
- type QueryVoteResponse
- func (*QueryVoteResponse) Descriptor() ([]byte, []int)
- func (m *QueryVoteResponse) GetVote() Vote
- func (m *QueryVoteResponse) Marshal() (dAtA []byte, err error)
- func (m *QueryVoteResponse) MarshalTo(dAtA []byte) (int, error)
- func (m *QueryVoteResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*QueryVoteResponse) ProtoMessage()
- func (m *QueryVoteResponse) Reset()
- func (m *QueryVoteResponse) Size() (n int)
- func (m *QueryVoteResponse) String() string
- func (m *QueryVoteResponse) Unmarshal(dAtA []byte) error
- func (m *QueryVoteResponse) XXX_DiscardUnknown()
- func (m *QueryVoteResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *QueryVoteResponse) XXX_Merge(src proto.Message)
- func (m *QueryVoteResponse) XXX_Size() int
- func (m *QueryVoteResponse) XXX_Unmarshal(b []byte) error
- type QueryVotesRequest
- func (*QueryVotesRequest) Descriptor() ([]byte, []int)
- func (m *QueryVotesRequest) GetPagination() *query.PageRequest
- func (m *QueryVotesRequest) GetProposalId() uint64
- func (m *QueryVotesRequest) Marshal() (dAtA []byte, err error)
- func (m *QueryVotesRequest) MarshalTo(dAtA []byte) (int, error)
- func (m *QueryVotesRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*QueryVotesRequest) ProtoMessage()
- func (m *QueryVotesRequest) Reset()
- func (m *QueryVotesRequest) Size() (n int)
- func (m *QueryVotesRequest) String() string
- func (m *QueryVotesRequest) Unmarshal(dAtA []byte) error
- func (m *QueryVotesRequest) XXX_DiscardUnknown()
- func (m *QueryVotesRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *QueryVotesRequest) XXX_Merge(src proto.Message)
- func (m *QueryVotesRequest) XXX_Size() int
- func (m *QueryVotesRequest) XXX_Unmarshal(b []byte) error
- type QueryVotesResponse
- func (*QueryVotesResponse) Descriptor() ([]byte, []int)
- func (m *QueryVotesResponse) GetPagination() *query.PageResponse
- func (m *QueryVotesResponse) GetVotes() []Vote
- func (m *QueryVotesResponse) Marshal() (dAtA []byte, err error)
- func (m *QueryVotesResponse) MarshalTo(dAtA []byte) (int, error)
- func (m *QueryVotesResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*QueryVotesResponse) ProtoMessage()
- func (m *QueryVotesResponse) Reset()
- func (m *QueryVotesResponse) Size() (n int)
- func (m *QueryVotesResponse) String() string
- func (m *QueryVotesResponse) Unmarshal(dAtA []byte) error
- func (m *QueryVotesResponse) XXX_DiscardUnknown()
- func (m *QueryVotesResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *QueryVotesResponse) XXX_Merge(src proto.Message)
- func (m *QueryVotesResponse) XXX_Size() int
- func (m *QueryVotesResponse) XXX_Unmarshal(b []byte) error
- type SubmitProposalRequest
- type TallyParams
- func (*TallyParams) Descriptor() ([]byte, []int)
- func (m *TallyParams) Marshal() (dAtA []byte, err error)
- func (m *TallyParams) MarshalTo(dAtA []byte) (int, error)
- func (m *TallyParams) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*TallyParams) ProtoMessage()
- func (m *TallyParams) Reset()
- func (m *TallyParams) Size() (n int)
- func (tp TallyParams) String() string
- func (m *TallyParams) Unmarshal(dAtA []byte) error
- func (m *TallyParams) XXX_DiscardUnknown()
- func (m *TallyParams) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *TallyParams) XXX_Merge(src proto.Message)
- func (m *TallyParams) XXX_Size() int
- func (m *TallyParams) XXX_Unmarshal(b []byte) error
- type TallyResult
- func (t TallyResult) Convert() interface{}
- func (*TallyResult) Descriptor() ([]byte, []int)
- func (this *TallyResult) Equal(that interface{}) bool
- func (m *TallyResult) Marshal() (dAtA []byte, err error)
- func (m *TallyResult) MarshalTo(dAtA []byte) (int, error)
- func (m *TallyResult) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*TallyResult) ProtoMessage()
- func (m *TallyResult) Reset()
- func (m *TallyResult) Size() (n int)
- func (tr TallyResult) String() string
- func (m *TallyResult) Unmarshal(dAtA []byte) error
- func (m *TallyResult) XXX_DiscardUnknown()
- func (m *TallyResult) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *TallyResult) XXX_Merge(src proto.Message)
- func (m *TallyResult) XXX_Size() int
- func (m *TallyResult) XXX_Unmarshal(b []byte) error
- type TextProposal
- func (*TextProposal) Descriptor() ([]byte, []int)
- func (this *TextProposal) Equal(that interface{}) bool
- func (tp *TextProposal) GetDescription() string
- func (tp *TextProposal) GetTitle() string
- func (m *TextProposal) Marshal() (dAtA []byte, err error)
- func (m *TextProposal) MarshalTo(dAtA []byte) (int, error)
- func (m *TextProposal) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (tp *TextProposal) ProposalRoute() string
- func (tp *TextProposal) ProposalType() string
- func (*TextProposal) ProtoMessage()
- func (m *TextProposal) Reset()
- func (m *TextProposal) Size() (n int)
- func (tp TextProposal) String() string
- func (m *TextProposal) Unmarshal(dAtA []byte) error
- func (tp *TextProposal) ValidateBasic() error
- func (m *TextProposal) XXX_DiscardUnknown()
- func (m *TextProposal) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *TextProposal) XXX_Merge(src proto.Message)
- func (m *TextProposal) XXX_Size() int
- func (m *TextProposal) XXX_Unmarshal(b []byte) error
- type UnimplementedMsgServer
- func (*UnimplementedMsgServer) Deposit(ctx context.Context, req *MsgDeposit) (*MsgDepositResponse, error)
- func (*UnimplementedMsgServer) SubmitProposal(ctx context.Context, req *MsgSubmitProposal) (*MsgSubmitProposalResponse, error)
- func (*UnimplementedMsgServer) Vote(ctx context.Context, req *MsgVote) (*MsgVoteResponse, error)
- type UnimplementedQueryServer
- func (*UnimplementedQueryServer) Deposit(ctx context.Context, req *QueryDepositRequest) (*QueryDepositResponse, error)
- func (*UnimplementedQueryServer) Deposits(ctx context.Context, req *QueryDepositsRequest) (*QueryDepositsResponse, error)
- func (*UnimplementedQueryServer) Params(ctx context.Context, req *QueryParamsRequest) (*QueryParamsResponse, error)
- func (*UnimplementedQueryServer) Proposal(ctx context.Context, req *QueryProposalRequest) (*QueryProposalResponse, error)
- func (*UnimplementedQueryServer) Proposals(ctx context.Context, req *QueryProposalsRequest) (*QueryProposalsResponse, error)
- func (*UnimplementedQueryServer) TallyResult(ctx context.Context, req *QueryTallyResultRequest) (*QueryTallyResultResponse, error)
- func (*UnimplementedQueryServer) Vote(ctx context.Context, req *QueryVoteRequest) (*QueryVoteResponse, error)
- func (*UnimplementedQueryServer) Votes(ctx context.Context, req *QueryVotesRequest) (*QueryVotesResponse, error)
- type Vote
- func (v Vote) Convert() interface{}
- func (*Vote) Descriptor() ([]byte, []int)
- func (m *Vote) Marshal() (dAtA []byte, err error)
- func (m *Vote) MarshalTo(dAtA []byte) (int, error)
- func (m *Vote) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*Vote) ProtoMessage()
- func (m *Vote) Reset()
- func (m *Vote) Size() (n int)
- func (v Vote) String() string
- func (m *Vote) Unmarshal(dAtA []byte) error
- func (m *Vote) XXX_DiscardUnknown()
- func (m *Vote) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Vote) XXX_Merge(src proto.Message)
- func (m *Vote) XXX_Size() int
- func (m *Vote) XXX_Unmarshal(b []byte) error
- type VoteOption
- type VoteRequest
- type Votes
- type VotingParams
- func (*VotingParams) Descriptor() ([]byte, []int)
- func (m *VotingParams) Marshal() (dAtA []byte, err error)
- func (m *VotingParams) MarshalTo(dAtA []byte) (int, error)
- func (m *VotingParams) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*VotingParams) ProtoMessage()
- func (m *VotingParams) Reset()
- func (m *VotingParams) Size() (n int)
- func (vp VotingParams) String() string
- func (m *VotingParams) Unmarshal(dAtA []byte) error
- func (m *VotingParams) XXX_DiscardUnknown()
- func (m *VotingParams) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *VotingParams) XXX_Merge(src proto.Message)
- func (m *VotingParams) XXX_Size() int
- func (m *VotingParams) XXX_Unmarshal(b []byte) error
Constants ¶
const ( MaxDescriptionLength int = 5000 MaxTitleLength int = 140 )
Constants pertaining to a Content object
const ( ModuleName = "gov" AttributeKeyProposalId = "proposal_id" )
const DefaultStartingProposalID uint64 = 1
DefaultStartingProposalID is 1
const (
ProposalTypeText string = "Text"
)
Proposal types
Variables ¶
var ( ErrInvalidLengthGov = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowGov = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupGov = 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 ( ErrInvalidLengthTx = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowTx = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupTx = fmt.Errorf("proto: unexpected end of group") )
var (
ModuleCdc = codec.NewAminoCodec(amino)
)
var ProposalStatus_name = map[int32]string{
0: "PROPOSAL_STATUS_UNSPECIFIED",
1: "PROPOSAL_STATUS_DEPOSIT_PERIOD",
2: "PROPOSAL_STATUS_VOTING_PERIOD",
3: "PROPOSAL_STATUS_PASSED",
4: "PROPOSAL_STATUS_REJECTED",
5: "PROPOSAL_STATUS_FAILED",
}
var ProposalStatus_value = map[string]int32{
"PROPOSAL_STATUS_UNSPECIFIED": 0,
"PROPOSAL_STATUS_DEPOSIT_PERIOD": 1,
"PROPOSAL_STATUS_VOTING_PERIOD": 2,
"PROPOSAL_STATUS_PASSED": 3,
"PROPOSAL_STATUS_REJECTED": 4,
"PROPOSAL_STATUS_FAILED": 5,
}
var VoteOption_name = map[int32]string{
0: "VOTE_OPTION_UNSPECIFIED",
1: "VOTE_OPTION_YES",
2: "VOTE_OPTION_ABSTAIN",
3: "VOTE_OPTION_NO",
4: "VOTE_OPTION_NO_WITH_VETO",
}
var VoteOption_value = map[string]int32{
"VOTE_OPTION_UNSPECIFIED": 0,
"VOTE_OPTION_YES": 1,
"VOTE_OPTION_ABSTAIN": 2,
"VOTE_OPTION_NO": 3,
"VOTE_OPTION_NO_WITH_VETO": 4,
}
Functions ¶
func IsValidProposalType ¶
IsValidProposalType returns a boolean determining if the proposal type is valid.
NOTE: Modules with their own proposal types must register them.
func RegisterInterfaces ¶
func RegisterInterfaces(registry types.InterfaceRegistry)
func RegisterMsgServer ¶
func RegisterProposalType ¶
func RegisterProposalType(ty string)
RegisterProposalType registers a proposal type. It will panic if the type is already registered.
func RegisterQueryServer ¶
func RegisterQueryServer(s grpc1.Server, srv QueryServer)
func ValidProposalStatus ¶
func ValidProposalStatus(status ProposalStatus) bool
ValidProposalStatus returns true if the proposal status is valid and false otherwise.
func ValidVoteOption ¶
func ValidVoteOption(option VoteOption) bool
Types ¶
type Client ¶
type Client interface { sdk.Module SubmitProposal(request SubmitProposalRequest, baseTx sdk.BaseTx) (uint64, sdk.ResultTx, sdk.Error) Deposit(request DepositRequest, baseTx sdk.BaseTx) (sdk.ResultTx, sdk.Error) Vote(request VoteRequest, baseTx sdk.BaseTx) (sdk.ResultTx, sdk.Error) QueryProposal(proposalId uint64) (QueryProposalResp, sdk.Error) QueryProposals(proposalStatus string) ([]QueryProposalResp, sdk.Error) QueryVote(proposalId uint64, voter string) (QueryVoteResp, sdk.Error) QueryVotes(proposalId uint64) ([]QueryVoteResp, sdk.Error) QueryParams(paramsType string) (QueryParamsResp, sdk.Error) QueryDeposit(proposalId uint64, depositor string) (QueryDepositResp, sdk.Error) QueryDeposits(proposalId uint64) ([]QueryDepositResp, sdk.Error) QueryTallyResult(proposalId uint64) (QueryTallyResultResp, sdk.Error) }
expose Gov module api for user
type Content ¶
type Content interface { GetTitle() string GetDescription() string ProposalRoute() string ProposalType() string ValidateBasic() error String() string }
Content defines an interface that a proposal must implement. It contains information such as the title and description along with the type and routing information for the appropriate handler to process the proposal. Content can have additional fields, which will handled by a proposal's Handler. TODO Try to unify this interface with types/module/simulation https://github.com/cosmos/cosmos-sdk/issues/5853
func ContentFromProposalType ¶
ContentFromProposalType returns a Content object based on the proposal type.
func NewTextProposal ¶
NewTextProposal creates a text proposal Content
type Deposit ¶
type Deposit struct { ProposalId uint64 `protobuf:"varint,1,opt,name=proposal_id,json=proposalId,proto3" json:"proposal_id,omitempty" yaml:"proposal_id"` Depositor string `protobuf:"bytes,2,opt,name=depositor,proto3" json:"depositor,omitempty"` Amount plugchain_sdk_types.Coins `protobuf:"bytes,3,rep,name=amount,proto3,castrepeated=gitee.com/qizikd/plugchain-sdk-go/types.Coins" json:"amount"` }
Deposit defines an amount deposited by an account address to an active proposal.
func (*Deposit) Descriptor ¶
func (*Deposit) MarshalToSizedBuffer ¶
func (*Deposit) ProtoMessage ¶
func (*Deposit) ProtoMessage()
func (*Deposit) XXX_DiscardUnknown ¶
func (m *Deposit) XXX_DiscardUnknown()
func (*Deposit) XXX_Marshal ¶
func (*Deposit) XXX_Unmarshal ¶
type DepositParams ¶
type DepositParams struct { // Minimum deposit for a proposal to enter voting period. MinDeposit plugchain_sdk_types.Coins `` /* 169-byte string literal not displayed */ // Maximum period for Atom holders to deposit on a proposal. Initial value: 2 // months. MaxDepositPeriod time.Duration `` /* 149-byte string literal not displayed */ }
DepositParams defines the params for deposits on governance proposals.
func (*DepositParams) Descriptor ¶
func (*DepositParams) Descriptor() ([]byte, []int)
func (*DepositParams) Marshal ¶
func (m *DepositParams) Marshal() (dAtA []byte, err error)
func (*DepositParams) MarshalToSizedBuffer ¶
func (m *DepositParams) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*DepositParams) ProtoMessage ¶
func (*DepositParams) ProtoMessage()
func (*DepositParams) Reset ¶
func (m *DepositParams) Reset()
func (*DepositParams) Size ¶
func (m *DepositParams) Size() (n int)
func (DepositParams) String ¶
func (dp DepositParams) String() string
func (*DepositParams) Unmarshal ¶
func (m *DepositParams) Unmarshal(dAtA []byte) error
func (*DepositParams) XXX_DiscardUnknown ¶
func (m *DepositParams) XXX_DiscardUnknown()
func (*DepositParams) XXX_Marshal ¶
func (m *DepositParams) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*DepositParams) XXX_Merge ¶
func (m *DepositParams) XXX_Merge(src proto.Message)
func (*DepositParams) XXX_Size ¶
func (m *DepositParams) XXX_Size() int
func (*DepositParams) XXX_Unmarshal ¶
func (m *DepositParams) XXX_Unmarshal(b []byte) error
type DepositRequest ¶
type MsgClient ¶
type MsgClient interface { // SubmitProposal defines a method to create new proposal given a content. SubmitProposal(ctx context.Context, in *MsgSubmitProposal, opts ...grpc.CallOption) (*MsgSubmitProposalResponse, error) // Vote defines a method to add a vote on a specific proposal. Vote(ctx context.Context, in *MsgVote, opts ...grpc.CallOption) (*MsgVoteResponse, error) // Deposit defines a method to add deposit on a specific proposal. Deposit(ctx context.Context, in *MsgDeposit, opts ...grpc.CallOption) (*MsgDepositResponse, 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 MsgDeposit ¶
type MsgDeposit struct { ProposalId uint64 `protobuf:"varint,1,opt,name=proposal_id,json=proposalId,proto3" json:"proposal_id" yaml:"proposal_id"` Depositor string `protobuf:"bytes,2,opt,name=depositor,proto3" json:"depositor,omitempty"` Amount plugchain_sdk_types.Coins `protobuf:"bytes,3,rep,name=amount,proto3,castrepeated=gitee.com/qizikd/plugchain-sdk-go/types.Coins" json:"amount"` }
MsgDeposit defines a message to submit a deposit to an existing proposal.
func (*MsgDeposit) Descriptor ¶
func (*MsgDeposit) Descriptor() ([]byte, []int)
func (MsgDeposit) GetSignBytes ¶
func (msg MsgDeposit) GetSignBytes() []byte
GetSignBytes implements Msg
func (MsgDeposit) GetSigners ¶
func (msg MsgDeposit) GetSigners() []sdk.AccAddress
GetSigners implements Msg
func (*MsgDeposit) Marshal ¶
func (m *MsgDeposit) Marshal() (dAtA []byte, err error)
func (*MsgDeposit) MarshalToSizedBuffer ¶
func (m *MsgDeposit) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*MsgDeposit) ProtoMessage ¶
func (*MsgDeposit) ProtoMessage()
func (*MsgDeposit) Reset ¶
func (m *MsgDeposit) Reset()
func (MsgDeposit) Route ¶
func (msg MsgDeposit) Route() string
func (*MsgDeposit) Size ¶
func (m *MsgDeposit) Size() (n int)
func (MsgDeposit) String ¶
func (msg MsgDeposit) String() string
String implements the Stringer interface
func (*MsgDeposit) Unmarshal ¶
func (m *MsgDeposit) Unmarshal(dAtA []byte) error
func (MsgDeposit) ValidateBasic ¶
func (msg MsgDeposit) ValidateBasic() error
ValidateBasic implements Msg
func (*MsgDeposit) XXX_DiscardUnknown ¶
func (m *MsgDeposit) XXX_DiscardUnknown()
func (*MsgDeposit) XXX_Marshal ¶
func (m *MsgDeposit) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*MsgDeposit) XXX_Merge ¶
func (m *MsgDeposit) XXX_Merge(src proto.Message)
func (*MsgDeposit) XXX_Size ¶
func (m *MsgDeposit) XXX_Size() int
func (*MsgDeposit) XXX_Unmarshal ¶
func (m *MsgDeposit) XXX_Unmarshal(b []byte) error
type MsgDepositResponse ¶
type MsgDepositResponse struct { }
MsgDepositResponse defines the Msg/Deposit response type.
func (*MsgDepositResponse) Descriptor ¶
func (*MsgDepositResponse) Descriptor() ([]byte, []int)
func (*MsgDepositResponse) Marshal ¶
func (m *MsgDepositResponse) Marshal() (dAtA []byte, err error)
func (*MsgDepositResponse) MarshalTo ¶
func (m *MsgDepositResponse) MarshalTo(dAtA []byte) (int, error)
func (*MsgDepositResponse) MarshalToSizedBuffer ¶
func (m *MsgDepositResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*MsgDepositResponse) ProtoMessage ¶
func (*MsgDepositResponse) ProtoMessage()
func (*MsgDepositResponse) Reset ¶
func (m *MsgDepositResponse) Reset()
func (*MsgDepositResponse) Size ¶
func (m *MsgDepositResponse) Size() (n int)
func (*MsgDepositResponse) String ¶
func (m *MsgDepositResponse) String() string
func (*MsgDepositResponse) Unmarshal ¶
func (m *MsgDepositResponse) Unmarshal(dAtA []byte) error
func (*MsgDepositResponse) XXX_DiscardUnknown ¶
func (m *MsgDepositResponse) XXX_DiscardUnknown()
func (*MsgDepositResponse) XXX_Marshal ¶
func (m *MsgDepositResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*MsgDepositResponse) XXX_Merge ¶
func (m *MsgDepositResponse) XXX_Merge(src proto.Message)
func (*MsgDepositResponse) XXX_Size ¶
func (m *MsgDepositResponse) XXX_Size() int
func (*MsgDepositResponse) XXX_Unmarshal ¶
func (m *MsgDepositResponse) XXX_Unmarshal(b []byte) error
type MsgServer ¶
type MsgServer interface { // SubmitProposal defines a method to create new proposal given a content. SubmitProposal(context.Context, *MsgSubmitProposal) (*MsgSubmitProposalResponse, error) // Vote defines a method to add a vote on a specific proposal. Vote(context.Context, *MsgVote) (*MsgVoteResponse, error) // Deposit defines a method to add deposit on a specific proposal. Deposit(context.Context, *MsgDeposit) (*MsgDepositResponse, error) }
MsgServer is the server API for Msg service.
type MsgSubmitProposal ¶
type MsgSubmitProposal struct { Content *types.Any `protobuf:"bytes,1,opt,name=content,proto3" json:"content,omitempty"` InitialDeposit plugchain_sdk_types.Coins `` /* 175-byte string literal not displayed */ Proposer string `protobuf:"bytes,3,opt,name=proposer,proto3" json:"proposer,omitempty"` }
MsgSubmitProposal defines an sdk.Msg type that supports submitting arbitrary proposal Content.
func NewMsgSubmitProposal ¶
func NewMsgSubmitProposal(content Content, initialDeposit sdk.Coins, proposer sdk.AccAddress) (*MsgSubmitProposal, error)
NewMsgSubmitProposal creates a new MsgSubmitProposal.
func (*MsgSubmitProposal) Descriptor ¶
func (*MsgSubmitProposal) Descriptor() ([]byte, []int)
func (*MsgSubmitProposal) GetContent ¶
func (m *MsgSubmitProposal) GetContent() Content
func (*MsgSubmitProposal) GetInitialDeposit ¶
func (m *MsgSubmitProposal) GetInitialDeposit() sdk.Coins
func (*MsgSubmitProposal) GetProposer ¶
func (m *MsgSubmitProposal) GetProposer() sdk.AccAddress
func (MsgSubmitProposal) GetSignBytes ¶
func (m MsgSubmitProposal) GetSignBytes() []byte
GetSignBytes implements Msg
func (MsgSubmitProposal) GetSigners ¶
func (m MsgSubmitProposal) GetSigners() []sdk.AccAddress
GetSigners implements Msg
func (*MsgSubmitProposal) Marshal ¶
func (m *MsgSubmitProposal) Marshal() (dAtA []byte, err error)
func (*MsgSubmitProposal) MarshalTo ¶
func (m *MsgSubmitProposal) MarshalTo(dAtA []byte) (int, error)
func (*MsgSubmitProposal) MarshalToSizedBuffer ¶
func (m *MsgSubmitProposal) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*MsgSubmitProposal) ProtoMessage ¶
func (*MsgSubmitProposal) ProtoMessage()
func (*MsgSubmitProposal) Reset ¶
func (m *MsgSubmitProposal) Reset()
func (MsgSubmitProposal) Route ¶
func (m MsgSubmitProposal) Route() string
func (*MsgSubmitProposal) SetContent ¶
func (m *MsgSubmitProposal) SetContent(content Content) error
func (*MsgSubmitProposal) Size ¶
func (m *MsgSubmitProposal) Size() (n int)
func (MsgSubmitProposal) String ¶
func (m MsgSubmitProposal) String() string
String implements the Stringer interface
func (*MsgSubmitProposal) Unmarshal ¶
func (m *MsgSubmitProposal) Unmarshal(dAtA []byte) error
func (MsgSubmitProposal) UnpackInterfaces ¶
func (m MsgSubmitProposal) UnpackInterfaces(unpacker types.AnyUnpacker) error
UnpackInterfaces implements UnpackInterfacesMessage.UnpackInterfaces
func (MsgSubmitProposal) ValidateBasic ¶
func (m MsgSubmitProposal) ValidateBasic() error
ValidateBasic implements Msg
func (*MsgSubmitProposal) XXX_DiscardUnknown ¶
func (m *MsgSubmitProposal) XXX_DiscardUnknown()
func (*MsgSubmitProposal) XXX_Marshal ¶
func (m *MsgSubmitProposal) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*MsgSubmitProposal) XXX_Merge ¶
func (m *MsgSubmitProposal) XXX_Merge(src proto.Message)
func (*MsgSubmitProposal) XXX_Size ¶
func (m *MsgSubmitProposal) XXX_Size() int
func (*MsgSubmitProposal) XXX_Unmarshal ¶
func (m *MsgSubmitProposal) XXX_Unmarshal(b []byte) error
type MsgSubmitProposalResponse ¶
type MsgSubmitProposalResponse struct {
ProposalId uint64 `protobuf:"varint,1,opt,name=proposal_id,json=proposalId,proto3" json:"proposal_id" yaml:"proposal_id"`
}
MsgSubmitProposalResponse defines the Msg/SubmitProposal response type.
func (*MsgSubmitProposalResponse) Descriptor ¶
func (*MsgSubmitProposalResponse) Descriptor() ([]byte, []int)
func (*MsgSubmitProposalResponse) GetProposalId ¶
func (m *MsgSubmitProposalResponse) GetProposalId() uint64
func (*MsgSubmitProposalResponse) Marshal ¶
func (m *MsgSubmitProposalResponse) Marshal() (dAtA []byte, err error)
func (*MsgSubmitProposalResponse) MarshalTo ¶
func (m *MsgSubmitProposalResponse) MarshalTo(dAtA []byte) (int, error)
func (*MsgSubmitProposalResponse) MarshalToSizedBuffer ¶
func (m *MsgSubmitProposalResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*MsgSubmitProposalResponse) ProtoMessage ¶
func (*MsgSubmitProposalResponse) ProtoMessage()
func (*MsgSubmitProposalResponse) Reset ¶
func (m *MsgSubmitProposalResponse) Reset()
func (*MsgSubmitProposalResponse) Size ¶
func (m *MsgSubmitProposalResponse) Size() (n int)
func (*MsgSubmitProposalResponse) String ¶
func (m *MsgSubmitProposalResponse) String() string
func (*MsgSubmitProposalResponse) Unmarshal ¶
func (m *MsgSubmitProposalResponse) Unmarshal(dAtA []byte) error
func (*MsgSubmitProposalResponse) XXX_DiscardUnknown ¶
func (m *MsgSubmitProposalResponse) XXX_DiscardUnknown()
func (*MsgSubmitProposalResponse) XXX_Marshal ¶
func (m *MsgSubmitProposalResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*MsgSubmitProposalResponse) XXX_Merge ¶
func (m *MsgSubmitProposalResponse) XXX_Merge(src proto.Message)
func (*MsgSubmitProposalResponse) XXX_Size ¶
func (m *MsgSubmitProposalResponse) XXX_Size() int
func (*MsgSubmitProposalResponse) XXX_Unmarshal ¶
func (m *MsgSubmitProposalResponse) XXX_Unmarshal(b []byte) error
type MsgVote ¶
type MsgVote struct { ProposalId uint64 `protobuf:"varint,1,opt,name=proposal_id,json=proposalId,proto3" json:"proposal_id" yaml:"proposal_id"` Voter string `protobuf:"bytes,2,opt,name=voter,proto3" json:"voter,omitempty"` Option VoteOption `protobuf:"varint,3,opt,name=option,proto3,enum=cosmos.gov.v1beta1.VoteOption" json:"option,omitempty"` }
MsgVote defines a message to cast a vote.
func (*MsgVote) Descriptor ¶
func (MsgVote) GetSigners ¶
func (msg MsgVote) GetSigners() []sdk.AccAddress
GetSigners implements Msg
func (*MsgVote) MarshalToSizedBuffer ¶
func (*MsgVote) ProtoMessage ¶
func (*MsgVote) ProtoMessage()
func (MsgVote) ValidateBasic ¶
ValidateBasic implements Msg
func (*MsgVote) XXX_DiscardUnknown ¶
func (m *MsgVote) XXX_DiscardUnknown()
func (*MsgVote) XXX_Marshal ¶
func (*MsgVote) XXX_Unmarshal ¶
type MsgVoteResponse ¶
type MsgVoteResponse struct { }
MsgVoteResponse defines the Msg/Vote response type.
func (*MsgVoteResponse) Descriptor ¶
func (*MsgVoteResponse) Descriptor() ([]byte, []int)
func (*MsgVoteResponse) Marshal ¶
func (m *MsgVoteResponse) Marshal() (dAtA []byte, err error)
func (*MsgVoteResponse) MarshalToSizedBuffer ¶
func (m *MsgVoteResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*MsgVoteResponse) ProtoMessage ¶
func (*MsgVoteResponse) ProtoMessage()
func (*MsgVoteResponse) Reset ¶
func (m *MsgVoteResponse) Reset()
func (*MsgVoteResponse) Size ¶
func (m *MsgVoteResponse) Size() (n int)
func (*MsgVoteResponse) String ¶
func (m *MsgVoteResponse) String() string
func (*MsgVoteResponse) Unmarshal ¶
func (m *MsgVoteResponse) Unmarshal(dAtA []byte) error
func (*MsgVoteResponse) XXX_DiscardUnknown ¶
func (m *MsgVoteResponse) XXX_DiscardUnknown()
func (*MsgVoteResponse) XXX_Marshal ¶
func (m *MsgVoteResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*MsgVoteResponse) XXX_Merge ¶
func (m *MsgVoteResponse) XXX_Merge(src proto.Message)
func (*MsgVoteResponse) XXX_Size ¶
func (m *MsgVoteResponse) XXX_Size() int
func (*MsgVoteResponse) XXX_Unmarshal ¶
func (m *MsgVoteResponse) XXX_Unmarshal(b []byte) error
type Proposal ¶
type Proposal struct { ProposalId uint64 `protobuf:"varint,1,opt,name=proposal_id,json=proposalId,proto3" json:"id" yaml:"id"` Content *types1.Any `protobuf:"bytes,2,opt,name=content,proto3" json:"content,omitempty"` Status ProposalStatus `` /* 128-byte string literal not displayed */ FinalTallyResult TallyResult `` /* 127-byte string literal not displayed */ SubmitTime time.Time `protobuf:"bytes,5,opt,name=submit_time,json=submitTime,proto3,stdtime" json:"submit_time" yaml:"submit_time"` DepositEndTime time.Time `` /* 127-byte string literal not displayed */ TotalDeposit plugchain_sdk_types.Coins `` /* 167-byte string literal not displayed */ VotingStartTime time.Time `` /* 131-byte string literal not displayed */ VotingEndTime time.Time `protobuf:"bytes,9,opt,name=voting_end_time,json=votingEndTime,proto3,stdtime" json:"voting_end_time" yaml:"voting_end_time"` }
Proposal defines the core field members of a governance proposal.
func NewProposal ¶
func NewProposal(content Content, id uint64, submitTime, depositEndTime time.Time) (Proposal, error)
NewProposal creates a new Proposal instance
func (*Proposal) Descriptor ¶
func (Proposal) GetContent ¶
GetContent returns the proposal Content
func (*Proposal) MarshalToSizedBuffer ¶
func (Proposal) ProposalRoute ¶
func (Proposal) ProposalType ¶
func (*Proposal) ProtoMessage ¶
func (*Proposal) ProtoMessage()
func (Proposal) UnpackInterfaces ¶
func (p Proposal) UnpackInterfaces(unpacker types.AnyUnpacker) error
UnpackInterfaces implements UnpackInterfacesMessage.UnpackInterfaces
func (*Proposal) XXX_DiscardUnknown ¶
func (m *Proposal) XXX_DiscardUnknown()
func (*Proposal) XXX_Marshal ¶
func (*Proposal) XXX_Unmarshal ¶
type ProposalStatus ¶
type ProposalStatus int32
ProposalStatus enumerates the valid statuses of a proposal.
const ( // PROPOSAL_STATUS_UNSPECIFIED defines the default propopsal status. StatusNil ProposalStatus = 0 // PROPOSAL_STATUS_DEPOSIT_PERIOD defines a proposal status during the deposit // period. StatusDepositPeriod ProposalStatus = 1 // PROPOSAL_STATUS_VOTING_PERIOD defines a proposal status during the voting // period. StatusVotingPeriod ProposalStatus = 2 // PROPOSAL_STATUS_PASSED defines a proposal status of a proposal that has // passed. StatusPassed ProposalStatus = 3 // PROPOSAL_STATUS_REJECTED defines a proposal status of a proposal that has // been rejected. StatusRejected ProposalStatus = 4 // PROPOSAL_STATUS_FAILED defines a proposal status of a proposal that has // failed. StatusFailed ProposalStatus = 5 )
func ProposalStatusFromString ¶
func ProposalStatusFromString(str string) (ProposalStatus, error)
ProposalStatusFromString turns a string into a ProposalStatus
func (ProposalStatus) EnumDescriptor ¶
func (ProposalStatus) EnumDescriptor() ([]byte, []int)
func (ProposalStatus) Format ¶
func (status ProposalStatus) Format(s fmt.State, verb rune)
Format implements the fmt.Formatter interface. nolint: errcheck
func (ProposalStatus) Marshal ¶
func (status ProposalStatus) Marshal() ([]byte, error)
Marshal needed for protobuf compatibility
func (ProposalStatus) String ¶
func (x ProposalStatus) String() string
func (*ProposalStatus) Unmarshal ¶
func (status *ProposalStatus) Unmarshal(data []byte) error
Unmarshal needed for protobuf compatibility
type Proposals ¶
type Proposals []Proposal
func (Proposals) UnpackInterfaces ¶
func (p Proposals) UnpackInterfaces(unpacker types.AnyUnpacker) error
UnpackInterfaces implements UnpackInterfacesMessage.UnpackInterfaces
type QueryClient ¶
type QueryClient interface { // Proposal queries proposal details based on ProposalID. Proposal(ctx context.Context, in *QueryProposalRequest, opts ...grpc.CallOption) (*QueryProposalResponse, error) // Proposals queries all proposals based on given status. Proposals(ctx context.Context, in *QueryProposalsRequest, opts ...grpc.CallOption) (*QueryProposalsResponse, error) // Vote queries voted information based on proposalID, voterAddr. Vote(ctx context.Context, in *QueryVoteRequest, opts ...grpc.CallOption) (*QueryVoteResponse, error) // Votes queries votes of a given proposal. Votes(ctx context.Context, in *QueryVotesRequest, opts ...grpc.CallOption) (*QueryVotesResponse, error) // Params queries all parameters of the gov module. Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) // Deposit queries single deposit information based proposalID, depositAddr. Deposit(ctx context.Context, in *QueryDepositRequest, opts ...grpc.CallOption) (*QueryDepositResponse, error) // Deposits queries all deposits of a single proposal. Deposits(ctx context.Context, in *QueryDepositsRequest, opts ...grpc.CallOption) (*QueryDepositsResponse, error) // TallyResult queries the tally of a proposal vote. TallyResult(ctx context.Context, in *QueryTallyResultRequest, opts ...grpc.CallOption) (*QueryTallyResultResponse, 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 QueryDepositRequest ¶
type QueryDepositRequest struct { // proposal_id defines the unique id of the proposal. ProposalId uint64 `protobuf:"varint,1,opt,name=proposal_id,json=proposalId,proto3" json:"proposal_id,omitempty"` // depositor defines the deposit addresses from the proposals. Depositor string `protobuf:"bytes,2,opt,name=depositor,proto3" json:"depositor,omitempty"` }
QueryDepositRequest is the request type for the Query/Deposit RPC method.
func (*QueryDepositRequest) Descriptor ¶
func (*QueryDepositRequest) Descriptor() ([]byte, []int)
func (*QueryDepositRequest) Marshal ¶
func (m *QueryDepositRequest) Marshal() (dAtA []byte, err error)
func (*QueryDepositRequest) MarshalTo ¶
func (m *QueryDepositRequest) MarshalTo(dAtA []byte) (int, error)
func (*QueryDepositRequest) MarshalToSizedBuffer ¶
func (m *QueryDepositRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*QueryDepositRequest) ProtoMessage ¶
func (*QueryDepositRequest) ProtoMessage()
func (*QueryDepositRequest) Reset ¶
func (m *QueryDepositRequest) Reset()
func (*QueryDepositRequest) Size ¶
func (m *QueryDepositRequest) Size() (n int)
func (*QueryDepositRequest) String ¶
func (m *QueryDepositRequest) String() string
func (*QueryDepositRequest) Unmarshal ¶
func (m *QueryDepositRequest) Unmarshal(dAtA []byte) error
func (*QueryDepositRequest) XXX_DiscardUnknown ¶
func (m *QueryDepositRequest) XXX_DiscardUnknown()
func (*QueryDepositRequest) XXX_Marshal ¶
func (m *QueryDepositRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*QueryDepositRequest) XXX_Merge ¶
func (m *QueryDepositRequest) XXX_Merge(src proto.Message)
func (*QueryDepositRequest) XXX_Size ¶
func (m *QueryDepositRequest) XXX_Size() int
func (*QueryDepositRequest) XXX_Unmarshal ¶
func (m *QueryDepositRequest) XXX_Unmarshal(b []byte) error
type QueryDepositResp ¶
type QueryDepositResponse ¶
type QueryDepositResponse struct { // deposit defines the requested deposit. Deposit Deposit `protobuf:"bytes,1,opt,name=deposit,proto3" json:"deposit"` }
QueryDepositResponse is the response type for the Query/Deposit RPC method.
func (*QueryDepositResponse) Descriptor ¶
func (*QueryDepositResponse) Descriptor() ([]byte, []int)
func (*QueryDepositResponse) GetDeposit ¶
func (m *QueryDepositResponse) GetDeposit() Deposit
func (*QueryDepositResponse) Marshal ¶
func (m *QueryDepositResponse) Marshal() (dAtA []byte, err error)
func (*QueryDepositResponse) MarshalTo ¶
func (m *QueryDepositResponse) MarshalTo(dAtA []byte) (int, error)
func (*QueryDepositResponse) MarshalToSizedBuffer ¶
func (m *QueryDepositResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*QueryDepositResponse) ProtoMessage ¶
func (*QueryDepositResponse) ProtoMessage()
func (*QueryDepositResponse) Reset ¶
func (m *QueryDepositResponse) Reset()
func (*QueryDepositResponse) Size ¶
func (m *QueryDepositResponse) Size() (n int)
func (*QueryDepositResponse) String ¶
func (m *QueryDepositResponse) String() string
func (*QueryDepositResponse) Unmarshal ¶
func (m *QueryDepositResponse) Unmarshal(dAtA []byte) error
func (*QueryDepositResponse) XXX_DiscardUnknown ¶
func (m *QueryDepositResponse) XXX_DiscardUnknown()
func (*QueryDepositResponse) XXX_Marshal ¶
func (m *QueryDepositResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*QueryDepositResponse) XXX_Merge ¶
func (m *QueryDepositResponse) XXX_Merge(src proto.Message)
func (*QueryDepositResponse) XXX_Size ¶
func (m *QueryDepositResponse) XXX_Size() int
func (*QueryDepositResponse) XXX_Unmarshal ¶
func (m *QueryDepositResponse) XXX_Unmarshal(b []byte) error
type QueryDepositsRequest ¶
type QueryDepositsRequest struct { // proposal_id defines the unique id of the proposal. ProposalId uint64 `protobuf:"varint,1,opt,name=proposal_id,json=proposalId,proto3" json:"proposal_id,omitempty"` // pagination defines an optional pagination for the request. Pagination *query.PageRequest `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` }
QueryDepositsRequest is the request type for the Query/Deposits RPC method.
func (*QueryDepositsRequest) Descriptor ¶
func (*QueryDepositsRequest) Descriptor() ([]byte, []int)
func (*QueryDepositsRequest) GetPagination ¶
func (m *QueryDepositsRequest) GetPagination() *query.PageRequest
func (*QueryDepositsRequest) GetProposalId ¶
func (m *QueryDepositsRequest) GetProposalId() uint64
func (*QueryDepositsRequest) Marshal ¶
func (m *QueryDepositsRequest) Marshal() (dAtA []byte, err error)
func (*QueryDepositsRequest) MarshalTo ¶
func (m *QueryDepositsRequest) MarshalTo(dAtA []byte) (int, error)
func (*QueryDepositsRequest) MarshalToSizedBuffer ¶
func (m *QueryDepositsRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*QueryDepositsRequest) ProtoMessage ¶
func (*QueryDepositsRequest) ProtoMessage()
func (*QueryDepositsRequest) Reset ¶
func (m *QueryDepositsRequest) Reset()
func (*QueryDepositsRequest) Size ¶
func (m *QueryDepositsRequest) Size() (n int)
func (*QueryDepositsRequest) String ¶
func (m *QueryDepositsRequest) String() string
func (*QueryDepositsRequest) Unmarshal ¶
func (m *QueryDepositsRequest) Unmarshal(dAtA []byte) error
func (*QueryDepositsRequest) XXX_DiscardUnknown ¶
func (m *QueryDepositsRequest) XXX_DiscardUnknown()
func (*QueryDepositsRequest) XXX_Marshal ¶
func (m *QueryDepositsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*QueryDepositsRequest) XXX_Merge ¶
func (m *QueryDepositsRequest) XXX_Merge(src proto.Message)
func (*QueryDepositsRequest) XXX_Size ¶
func (m *QueryDepositsRequest) XXX_Size() int
func (*QueryDepositsRequest) XXX_Unmarshal ¶
func (m *QueryDepositsRequest) XXX_Unmarshal(b []byte) error
type QueryDepositsResponse ¶
type QueryDepositsResponse struct { Deposits []Deposit `protobuf:"bytes,1,rep,name=deposits,proto3" json:"deposits"` // pagination defines the pagination in the response. Pagination *query.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` }
QueryDepositsResponse is the response type for the Query/Deposits RPC method.
func (*QueryDepositsResponse) Descriptor ¶
func (*QueryDepositsResponse) Descriptor() ([]byte, []int)
func (*QueryDepositsResponse) GetDeposits ¶
func (m *QueryDepositsResponse) GetDeposits() []Deposit
func (*QueryDepositsResponse) GetPagination ¶
func (m *QueryDepositsResponse) GetPagination() *query.PageResponse
func (*QueryDepositsResponse) Marshal ¶
func (m *QueryDepositsResponse) Marshal() (dAtA []byte, err error)
func (*QueryDepositsResponse) MarshalTo ¶
func (m *QueryDepositsResponse) MarshalTo(dAtA []byte) (int, error)
func (*QueryDepositsResponse) MarshalToSizedBuffer ¶
func (m *QueryDepositsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*QueryDepositsResponse) ProtoMessage ¶
func (*QueryDepositsResponse) ProtoMessage()
func (*QueryDepositsResponse) Reset ¶
func (m *QueryDepositsResponse) Reset()
func (*QueryDepositsResponse) Size ¶
func (m *QueryDepositsResponse) Size() (n int)
func (*QueryDepositsResponse) String ¶
func (m *QueryDepositsResponse) String() string
func (*QueryDepositsResponse) Unmarshal ¶
func (m *QueryDepositsResponse) Unmarshal(dAtA []byte) error
func (*QueryDepositsResponse) XXX_DiscardUnknown ¶
func (m *QueryDepositsResponse) XXX_DiscardUnknown()
func (*QueryDepositsResponse) XXX_Marshal ¶
func (m *QueryDepositsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*QueryDepositsResponse) XXX_Merge ¶
func (m *QueryDepositsResponse) XXX_Merge(src proto.Message)
func (*QueryDepositsResponse) XXX_Size ¶
func (m *QueryDepositsResponse) XXX_Size() int
func (*QueryDepositsResponse) XXX_Unmarshal ¶
func (m *QueryDepositsResponse) XXX_Unmarshal(b []byte) error
type QueryParamsRequest ¶
type QueryParamsRequest struct { // params_type defines which parameters to query for, can be one of "voting", // "tallying" or "deposit". ParamsType string `protobuf:"bytes,1,opt,name=params_type,json=paramsType,proto3" json:"params_type,omitempty"` }
QueryParamsRequest is the request type for the Query/Params RPC method.
func (*QueryParamsRequest) Descriptor ¶
func (*QueryParamsRequest) Descriptor() ([]byte, []int)
func (*QueryParamsRequest) GetParamsType ¶
func (m *QueryParamsRequest) GetParamsType() string
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 QueryParamsResp ¶
type QueryParamsResp struct { VotingParams votingParams `json:"voting_params"` DepositParams depositParams `json:"deposit_params"` TallyParams tallyParams `json:"tally_params"` }
type QueryParamsResponse ¶
type QueryParamsResponse struct { // voting_params defines the parameters related to voting. VotingParams VotingParams `protobuf:"bytes,1,opt,name=voting_params,json=votingParams,proto3" json:"voting_params"` // deposit_params defines the parameters related to deposit. DepositParams DepositParams `protobuf:"bytes,2,opt,name=deposit_params,json=depositParams,proto3" json:"deposit_params"` // tally_params defines the parameters related to tally. TallyParams TallyParams `protobuf:"bytes,3,opt,name=tally_params,json=tallyParams,proto3" json:"tally_params"` }
QueryParamsResponse is the response type for the Query/Params RPC method.
func (QueryParamsResponse) Convert ¶
func (q QueryParamsResponse) Convert() interface{}
func (*QueryParamsResponse) Descriptor ¶
func (*QueryParamsResponse) Descriptor() ([]byte, []int)
func (*QueryParamsResponse) GetDepositParams ¶
func (m *QueryParamsResponse) GetDepositParams() DepositParams
func (*QueryParamsResponse) GetTallyParams ¶
func (m *QueryParamsResponse) GetTallyParams() TallyParams
func (*QueryParamsResponse) GetVotingParams ¶
func (m *QueryParamsResponse) GetVotingParams() VotingParams
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 QueryProposalRequest ¶
type QueryProposalRequest struct { // proposal_id defines the unique id of the proposal. ProposalId uint64 `protobuf:"varint,1,opt,name=proposal_id,json=proposalId,proto3" json:"proposal_id,omitempty"` }
QueryProposalRequest is the request type for the Query/Proposal RPC method.
func (*QueryProposalRequest) Descriptor ¶
func (*QueryProposalRequest) Descriptor() ([]byte, []int)
func (*QueryProposalRequest) GetProposalId ¶
func (m *QueryProposalRequest) GetProposalId() uint64
func (*QueryProposalRequest) Marshal ¶
func (m *QueryProposalRequest) Marshal() (dAtA []byte, err error)
func (*QueryProposalRequest) MarshalTo ¶
func (m *QueryProposalRequest) MarshalTo(dAtA []byte) (int, error)
func (*QueryProposalRequest) MarshalToSizedBuffer ¶
func (m *QueryProposalRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*QueryProposalRequest) ProtoMessage ¶
func (*QueryProposalRequest) ProtoMessage()
func (*QueryProposalRequest) Reset ¶
func (m *QueryProposalRequest) Reset()
func (*QueryProposalRequest) Size ¶
func (m *QueryProposalRequest) Size() (n int)
func (*QueryProposalRequest) String ¶
func (m *QueryProposalRequest) String() string
func (*QueryProposalRequest) Unmarshal ¶
func (m *QueryProposalRequest) Unmarshal(dAtA []byte) error
func (*QueryProposalRequest) XXX_DiscardUnknown ¶
func (m *QueryProposalRequest) XXX_DiscardUnknown()
func (*QueryProposalRequest) XXX_Marshal ¶
func (m *QueryProposalRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*QueryProposalRequest) XXX_Merge ¶
func (m *QueryProposalRequest) XXX_Merge(src proto.Message)
func (*QueryProposalRequest) XXX_Size ¶
func (m *QueryProposalRequest) XXX_Size() int
func (*QueryProposalRequest) XXX_Unmarshal ¶
func (m *QueryProposalRequest) XXX_Unmarshal(b []byte) error
type QueryProposalResp ¶
type QueryProposalResp struct { ProposalId uint64 `json:"proposal_id"` Content Content `json:"content"` Status string `json:"status"` FinalTallyResult QueryTallyResultResp `json:"final_tally_result"` SubmitTime time.Time `json:"submit_time"` DepositEndTime time.Time `json:"deposit_end_time"` TotalDeposit sdk.Coins `json:"total_deposit"` VotingStartTime time.Time `json:"voting_start_time"` VotingEndTime time.Time `json:"voting_end_time"` }
type QueryProposalResponse ¶
type QueryProposalResponse struct {
Proposal Proposal `protobuf:"bytes,1,opt,name=proposal,proto3" json:"proposal"`
}
QueryProposalResponse is the response type for the Query/Proposal RPC method.
func (*QueryProposalResponse) Descriptor ¶
func (*QueryProposalResponse) Descriptor() ([]byte, []int)
func (*QueryProposalResponse) GetProposal ¶
func (m *QueryProposalResponse) GetProposal() Proposal
func (*QueryProposalResponse) Marshal ¶
func (m *QueryProposalResponse) Marshal() (dAtA []byte, err error)
func (*QueryProposalResponse) MarshalTo ¶
func (m *QueryProposalResponse) MarshalTo(dAtA []byte) (int, error)
func (*QueryProposalResponse) MarshalToSizedBuffer ¶
func (m *QueryProposalResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*QueryProposalResponse) ProtoMessage ¶
func (*QueryProposalResponse) ProtoMessage()
func (*QueryProposalResponse) Reset ¶
func (m *QueryProposalResponse) Reset()
func (*QueryProposalResponse) Size ¶
func (m *QueryProposalResponse) Size() (n int)
func (*QueryProposalResponse) String ¶
func (m *QueryProposalResponse) String() string
func (*QueryProposalResponse) Unmarshal ¶
func (m *QueryProposalResponse) Unmarshal(dAtA []byte) error
func (*QueryProposalResponse) XXX_DiscardUnknown ¶
func (m *QueryProposalResponse) XXX_DiscardUnknown()
func (*QueryProposalResponse) XXX_Marshal ¶
func (m *QueryProposalResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*QueryProposalResponse) XXX_Merge ¶
func (m *QueryProposalResponse) XXX_Merge(src proto.Message)
func (*QueryProposalResponse) XXX_Size ¶
func (m *QueryProposalResponse) XXX_Size() int
func (*QueryProposalResponse) XXX_Unmarshal ¶
func (m *QueryProposalResponse) XXX_Unmarshal(b []byte) error
type QueryProposalsRequest ¶
type QueryProposalsRequest struct { // proposal_status defines the status of the proposals. ProposalStatus ProposalStatus `` /* 143-byte string literal not displayed */ // voter defines the voter address for the proposals. Voter string `protobuf:"bytes,2,opt,name=voter,proto3" json:"voter,omitempty"` // depositor defines the deposit addresses from the proposals. Depositor string `protobuf:"bytes,3,opt,name=depositor,proto3" json:"depositor,omitempty"` // pagination defines an optional pagination for the request. Pagination *query.PageRequest `protobuf:"bytes,4,opt,name=pagination,proto3" json:"pagination,omitempty"` }
QueryProposalsRequest is the request type for the Query/Proposals RPC method.
func (*QueryProposalsRequest) Descriptor ¶
func (*QueryProposalsRequest) Descriptor() ([]byte, []int)
func (*QueryProposalsRequest) Marshal ¶
func (m *QueryProposalsRequest) Marshal() (dAtA []byte, err error)
func (*QueryProposalsRequest) MarshalTo ¶
func (m *QueryProposalsRequest) MarshalTo(dAtA []byte) (int, error)
func (*QueryProposalsRequest) MarshalToSizedBuffer ¶
func (m *QueryProposalsRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*QueryProposalsRequest) ProtoMessage ¶
func (*QueryProposalsRequest) ProtoMessage()
func (*QueryProposalsRequest) Reset ¶
func (m *QueryProposalsRequest) Reset()
func (*QueryProposalsRequest) Size ¶
func (m *QueryProposalsRequest) Size() (n int)
func (*QueryProposalsRequest) String ¶
func (m *QueryProposalsRequest) String() string
func (*QueryProposalsRequest) Unmarshal ¶
func (m *QueryProposalsRequest) Unmarshal(dAtA []byte) error
func (*QueryProposalsRequest) XXX_DiscardUnknown ¶
func (m *QueryProposalsRequest) XXX_DiscardUnknown()
func (*QueryProposalsRequest) XXX_Marshal ¶
func (m *QueryProposalsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*QueryProposalsRequest) XXX_Merge ¶
func (m *QueryProposalsRequest) XXX_Merge(src proto.Message)
func (*QueryProposalsRequest) XXX_Size ¶
func (m *QueryProposalsRequest) XXX_Size() int
func (*QueryProposalsRequest) XXX_Unmarshal ¶
func (m *QueryProposalsRequest) XXX_Unmarshal(b []byte) error
type QueryProposalsResponse ¶
type QueryProposalsResponse struct { Proposals []Proposal `protobuf:"bytes,1,rep,name=proposals,proto3" json:"proposals"` // pagination defines the pagination in the response. Pagination *query.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` }
QueryProposalsResponse is the response type for the Query/Proposals RPC method.
func (*QueryProposalsResponse) Descriptor ¶
func (*QueryProposalsResponse) Descriptor() ([]byte, []int)
func (*QueryProposalsResponse) GetPagination ¶
func (m *QueryProposalsResponse) GetPagination() *query.PageResponse
func (*QueryProposalsResponse) GetProposals ¶
func (m *QueryProposalsResponse) GetProposals() []Proposal
func (*QueryProposalsResponse) Marshal ¶
func (m *QueryProposalsResponse) Marshal() (dAtA []byte, err error)
func (*QueryProposalsResponse) MarshalTo ¶
func (m *QueryProposalsResponse) MarshalTo(dAtA []byte) (int, error)
func (*QueryProposalsResponse) MarshalToSizedBuffer ¶
func (m *QueryProposalsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*QueryProposalsResponse) ProtoMessage ¶
func (*QueryProposalsResponse) ProtoMessage()
func (*QueryProposalsResponse) Reset ¶
func (m *QueryProposalsResponse) Reset()
func (*QueryProposalsResponse) Size ¶
func (m *QueryProposalsResponse) Size() (n int)
func (*QueryProposalsResponse) String ¶
func (m *QueryProposalsResponse) String() string
func (*QueryProposalsResponse) Unmarshal ¶
func (m *QueryProposalsResponse) Unmarshal(dAtA []byte) error
func (*QueryProposalsResponse) XXX_DiscardUnknown ¶
func (m *QueryProposalsResponse) XXX_DiscardUnknown()
func (*QueryProposalsResponse) XXX_Marshal ¶
func (m *QueryProposalsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*QueryProposalsResponse) XXX_Merge ¶
func (m *QueryProposalsResponse) XXX_Merge(src proto.Message)
func (*QueryProposalsResponse) XXX_Size ¶
func (m *QueryProposalsResponse) XXX_Size() int
func (*QueryProposalsResponse) XXX_Unmarshal ¶
func (m *QueryProposalsResponse) XXX_Unmarshal(b []byte) error
type QueryServer ¶
type QueryServer interface { // Proposal queries proposal details based on ProposalID. Proposal(context.Context, *QueryProposalRequest) (*QueryProposalResponse, error) // Proposals queries all proposals based on given status. Proposals(context.Context, *QueryProposalsRequest) (*QueryProposalsResponse, error) // Vote queries voted information based on proposalID, voterAddr. Vote(context.Context, *QueryVoteRequest) (*QueryVoteResponse, error) // Votes queries votes of a given proposal. Votes(context.Context, *QueryVotesRequest) (*QueryVotesResponse, error) // Params queries all parameters of the gov module. Params(context.Context, *QueryParamsRequest) (*QueryParamsResponse, error) // Deposit queries single deposit information based proposalID, depositAddr. Deposit(context.Context, *QueryDepositRequest) (*QueryDepositResponse, error) // Deposits queries all deposits of a single proposal. Deposits(context.Context, *QueryDepositsRequest) (*QueryDepositsResponse, error) // TallyResult queries the tally of a proposal vote. TallyResult(context.Context, *QueryTallyResultRequest) (*QueryTallyResultResponse, error) }
QueryServer is the server API for Query service.
type QueryTallyResultRequest ¶
type QueryTallyResultRequest struct { // proposal_id defines the unique id of the proposal. ProposalId uint64 `protobuf:"varint,1,opt,name=proposal_id,json=proposalId,proto3" json:"proposal_id,omitempty"` }
QueryTallyResultRequest is the request type for the Query/Tally RPC method.
func (*QueryTallyResultRequest) Descriptor ¶
func (*QueryTallyResultRequest) Descriptor() ([]byte, []int)
func (*QueryTallyResultRequest) GetProposalId ¶
func (m *QueryTallyResultRequest) GetProposalId() uint64
func (*QueryTallyResultRequest) Marshal ¶
func (m *QueryTallyResultRequest) Marshal() (dAtA []byte, err error)
func (*QueryTallyResultRequest) MarshalTo ¶
func (m *QueryTallyResultRequest) MarshalTo(dAtA []byte) (int, error)
func (*QueryTallyResultRequest) MarshalToSizedBuffer ¶
func (m *QueryTallyResultRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*QueryTallyResultRequest) ProtoMessage ¶
func (*QueryTallyResultRequest) ProtoMessage()
func (*QueryTallyResultRequest) Reset ¶
func (m *QueryTallyResultRequest) Reset()
func (*QueryTallyResultRequest) Size ¶
func (m *QueryTallyResultRequest) Size() (n int)
func (*QueryTallyResultRequest) String ¶
func (m *QueryTallyResultRequest) String() string
func (*QueryTallyResultRequest) Unmarshal ¶
func (m *QueryTallyResultRequest) Unmarshal(dAtA []byte) error
func (*QueryTallyResultRequest) XXX_DiscardUnknown ¶
func (m *QueryTallyResultRequest) XXX_DiscardUnknown()
func (*QueryTallyResultRequest) XXX_Marshal ¶
func (m *QueryTallyResultRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*QueryTallyResultRequest) XXX_Merge ¶
func (m *QueryTallyResultRequest) XXX_Merge(src proto.Message)
func (*QueryTallyResultRequest) XXX_Size ¶
func (m *QueryTallyResultRequest) XXX_Size() int
func (*QueryTallyResultRequest) XXX_Unmarshal ¶
func (m *QueryTallyResultRequest) XXX_Unmarshal(b []byte) error
type QueryTallyResultResp ¶
type QueryTallyResultResponse ¶
type QueryTallyResultResponse struct { // tally defines the requested tally. Tally TallyResult `protobuf:"bytes,1,opt,name=tally,proto3" json:"tally"` }
QueryTallyResultResponse is the response type for the Query/Tally RPC method.
func (*QueryTallyResultResponse) Descriptor ¶
func (*QueryTallyResultResponse) Descriptor() ([]byte, []int)
func (*QueryTallyResultResponse) GetTally ¶
func (m *QueryTallyResultResponse) GetTally() TallyResult
func (*QueryTallyResultResponse) Marshal ¶
func (m *QueryTallyResultResponse) Marshal() (dAtA []byte, err error)
func (*QueryTallyResultResponse) MarshalTo ¶
func (m *QueryTallyResultResponse) MarshalTo(dAtA []byte) (int, error)
func (*QueryTallyResultResponse) MarshalToSizedBuffer ¶
func (m *QueryTallyResultResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*QueryTallyResultResponse) ProtoMessage ¶
func (*QueryTallyResultResponse) ProtoMessage()
func (*QueryTallyResultResponse) Reset ¶
func (m *QueryTallyResultResponse) Reset()
func (*QueryTallyResultResponse) Size ¶
func (m *QueryTallyResultResponse) Size() (n int)
func (*QueryTallyResultResponse) String ¶
func (m *QueryTallyResultResponse) String() string
func (*QueryTallyResultResponse) Unmarshal ¶
func (m *QueryTallyResultResponse) Unmarshal(dAtA []byte) error
func (*QueryTallyResultResponse) XXX_DiscardUnknown ¶
func (m *QueryTallyResultResponse) XXX_DiscardUnknown()
func (*QueryTallyResultResponse) XXX_Marshal ¶
func (m *QueryTallyResultResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*QueryTallyResultResponse) XXX_Merge ¶
func (m *QueryTallyResultResponse) XXX_Merge(src proto.Message)
func (*QueryTallyResultResponse) XXX_Size ¶
func (m *QueryTallyResultResponse) XXX_Size() int
func (*QueryTallyResultResponse) XXX_Unmarshal ¶
func (m *QueryTallyResultResponse) XXX_Unmarshal(b []byte) error
type QueryVoteRequest ¶
type QueryVoteRequest struct { // proposal_id defines the unique id of the proposal. ProposalId uint64 `protobuf:"varint,1,opt,name=proposal_id,json=proposalId,proto3" json:"proposal_id,omitempty"` // voter defines the oter address for the proposals. Voter string `protobuf:"bytes,2,opt,name=voter,proto3" json:"voter,omitempty"` }
QueryVoteRequest is the request type for the Query/Vote RPC method.
func (*QueryVoteRequest) Descriptor ¶
func (*QueryVoteRequest) Descriptor() ([]byte, []int)
func (*QueryVoteRequest) Marshal ¶
func (m *QueryVoteRequest) Marshal() (dAtA []byte, err error)
func (*QueryVoteRequest) MarshalToSizedBuffer ¶
func (m *QueryVoteRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*QueryVoteRequest) ProtoMessage ¶
func (*QueryVoteRequest) ProtoMessage()
func (*QueryVoteRequest) Reset ¶
func (m *QueryVoteRequest) Reset()
func (*QueryVoteRequest) Size ¶
func (m *QueryVoteRequest) Size() (n int)
func (*QueryVoteRequest) String ¶
func (m *QueryVoteRequest) String() string
func (*QueryVoteRequest) Unmarshal ¶
func (m *QueryVoteRequest) Unmarshal(dAtA []byte) error
func (*QueryVoteRequest) XXX_DiscardUnknown ¶
func (m *QueryVoteRequest) XXX_DiscardUnknown()
func (*QueryVoteRequest) XXX_Marshal ¶
func (m *QueryVoteRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*QueryVoteRequest) XXX_Merge ¶
func (m *QueryVoteRequest) XXX_Merge(src proto.Message)
func (*QueryVoteRequest) XXX_Size ¶
func (m *QueryVoteRequest) XXX_Size() int
func (*QueryVoteRequest) XXX_Unmarshal ¶
func (m *QueryVoteRequest) XXX_Unmarshal(b []byte) error
type QueryVoteResp ¶
type QueryVoteResponse ¶
type QueryVoteResponse struct { // vote defined the queried vote. Vote Vote `protobuf:"bytes,1,opt,name=vote,proto3" json:"vote"` }
QueryVoteResponse is the response type for the Query/Vote RPC method.
func (*QueryVoteResponse) Descriptor ¶
func (*QueryVoteResponse) Descriptor() ([]byte, []int)
func (*QueryVoteResponse) GetVote ¶
func (m *QueryVoteResponse) GetVote() Vote
func (*QueryVoteResponse) Marshal ¶
func (m *QueryVoteResponse) Marshal() (dAtA []byte, err error)
func (*QueryVoteResponse) MarshalTo ¶
func (m *QueryVoteResponse) MarshalTo(dAtA []byte) (int, error)
func (*QueryVoteResponse) MarshalToSizedBuffer ¶
func (m *QueryVoteResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*QueryVoteResponse) ProtoMessage ¶
func (*QueryVoteResponse) ProtoMessage()
func (*QueryVoteResponse) Reset ¶
func (m *QueryVoteResponse) Reset()
func (*QueryVoteResponse) Size ¶
func (m *QueryVoteResponse) Size() (n int)
func (*QueryVoteResponse) String ¶
func (m *QueryVoteResponse) String() string
func (*QueryVoteResponse) Unmarshal ¶
func (m *QueryVoteResponse) Unmarshal(dAtA []byte) error
func (*QueryVoteResponse) XXX_DiscardUnknown ¶
func (m *QueryVoteResponse) XXX_DiscardUnknown()
func (*QueryVoteResponse) XXX_Marshal ¶
func (m *QueryVoteResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*QueryVoteResponse) XXX_Merge ¶
func (m *QueryVoteResponse) XXX_Merge(src proto.Message)
func (*QueryVoteResponse) XXX_Size ¶
func (m *QueryVoteResponse) XXX_Size() int
func (*QueryVoteResponse) XXX_Unmarshal ¶
func (m *QueryVoteResponse) XXX_Unmarshal(b []byte) error
type QueryVotesRequest ¶
type QueryVotesRequest struct { // proposal_id defines the unique id of the proposal. ProposalId uint64 `protobuf:"varint,1,opt,name=proposal_id,json=proposalId,proto3" json:"proposal_id,omitempty"` // pagination defines an optional pagination for the request. Pagination *query.PageRequest `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` }
QueryVotesRequest is the request type for the Query/Votes RPC method.
func (*QueryVotesRequest) Descriptor ¶
func (*QueryVotesRequest) Descriptor() ([]byte, []int)
func (*QueryVotesRequest) GetPagination ¶
func (m *QueryVotesRequest) GetPagination() *query.PageRequest
func (*QueryVotesRequest) GetProposalId ¶
func (m *QueryVotesRequest) GetProposalId() uint64
func (*QueryVotesRequest) Marshal ¶
func (m *QueryVotesRequest) Marshal() (dAtA []byte, err error)
func (*QueryVotesRequest) MarshalTo ¶
func (m *QueryVotesRequest) MarshalTo(dAtA []byte) (int, error)
func (*QueryVotesRequest) MarshalToSizedBuffer ¶
func (m *QueryVotesRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*QueryVotesRequest) ProtoMessage ¶
func (*QueryVotesRequest) ProtoMessage()
func (*QueryVotesRequest) Reset ¶
func (m *QueryVotesRequest) Reset()
func (*QueryVotesRequest) Size ¶
func (m *QueryVotesRequest) Size() (n int)
func (*QueryVotesRequest) String ¶
func (m *QueryVotesRequest) String() string
func (*QueryVotesRequest) Unmarshal ¶
func (m *QueryVotesRequest) Unmarshal(dAtA []byte) error
func (*QueryVotesRequest) XXX_DiscardUnknown ¶
func (m *QueryVotesRequest) XXX_DiscardUnknown()
func (*QueryVotesRequest) XXX_Marshal ¶
func (m *QueryVotesRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*QueryVotesRequest) XXX_Merge ¶
func (m *QueryVotesRequest) XXX_Merge(src proto.Message)
func (*QueryVotesRequest) XXX_Size ¶
func (m *QueryVotesRequest) XXX_Size() int
func (*QueryVotesRequest) XXX_Unmarshal ¶
func (m *QueryVotesRequest) XXX_Unmarshal(b []byte) error
type QueryVotesResponse ¶
type QueryVotesResponse struct { // votes defined the queried votes. Votes []Vote `protobuf:"bytes,1,rep,name=votes,proto3" json:"votes"` // pagination defines the pagination in the response. Pagination *query.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` }
QueryVotesResponse is the response type for the Query/Votes RPC method.
func (*QueryVotesResponse) Descriptor ¶
func (*QueryVotesResponse) Descriptor() ([]byte, []int)
func (*QueryVotesResponse) GetPagination ¶
func (m *QueryVotesResponse) GetPagination() *query.PageResponse
func (*QueryVotesResponse) GetVotes ¶
func (m *QueryVotesResponse) GetVotes() []Vote
func (*QueryVotesResponse) Marshal ¶
func (m *QueryVotesResponse) Marshal() (dAtA []byte, err error)
func (*QueryVotesResponse) MarshalTo ¶
func (m *QueryVotesResponse) MarshalTo(dAtA []byte) (int, error)
func (*QueryVotesResponse) MarshalToSizedBuffer ¶
func (m *QueryVotesResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*QueryVotesResponse) ProtoMessage ¶
func (*QueryVotesResponse) ProtoMessage()
func (*QueryVotesResponse) Reset ¶
func (m *QueryVotesResponse) Reset()
func (*QueryVotesResponse) Size ¶
func (m *QueryVotesResponse) Size() (n int)
func (*QueryVotesResponse) String ¶
func (m *QueryVotesResponse) String() string
func (*QueryVotesResponse) Unmarshal ¶
func (m *QueryVotesResponse) Unmarshal(dAtA []byte) error
func (*QueryVotesResponse) XXX_DiscardUnknown ¶
func (m *QueryVotesResponse) XXX_DiscardUnknown()
func (*QueryVotesResponse) XXX_Marshal ¶
func (m *QueryVotesResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*QueryVotesResponse) XXX_Merge ¶
func (m *QueryVotesResponse) XXX_Merge(src proto.Message)
func (*QueryVotesResponse) XXX_Size ¶
func (m *QueryVotesResponse) XXX_Size() int
func (*QueryVotesResponse) XXX_Unmarshal ¶
func (m *QueryVotesResponse) XXX_Unmarshal(b []byte) error
type SubmitProposalRequest ¶
type TallyParams ¶
type TallyParams struct { // Minimum percentage of total stake needed to vote for a result to be // considered valid. Quorum plugchain_sdk_types.Dec `protobuf:"bytes,1,opt,name=quorum,proto3,customtype=github.com/xiaka53/plugchain-sdk-go/types.Dec" json:"quorum,omitempty"` // Minimum proportion of Yes votes for proposal to pass. Default value: 0.5. Threshold plugchain_sdk_types.Dec `` /* 128-byte string literal not displayed */ // Minimum value of Veto votes to Total votes ratio for proposal to be // vetoed. Default value: 1/3. VetoThreshold plugchain_sdk_types.Dec `` /* 179-byte string literal not displayed */ }
TallyParams defines the params for tallying votes on governance proposals.
func (*TallyParams) Descriptor ¶
func (*TallyParams) Descriptor() ([]byte, []int)
func (*TallyParams) Marshal ¶
func (m *TallyParams) Marshal() (dAtA []byte, err error)
func (*TallyParams) MarshalToSizedBuffer ¶
func (m *TallyParams) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*TallyParams) ProtoMessage ¶
func (*TallyParams) ProtoMessage()
func (*TallyParams) Reset ¶
func (m *TallyParams) Reset()
func (*TallyParams) Size ¶
func (m *TallyParams) Size() (n int)
func (TallyParams) String ¶
func (tp TallyParams) String() string
func (*TallyParams) Unmarshal ¶
func (m *TallyParams) Unmarshal(dAtA []byte) error
func (*TallyParams) XXX_DiscardUnknown ¶
func (m *TallyParams) XXX_DiscardUnknown()
func (*TallyParams) XXX_Marshal ¶
func (m *TallyParams) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*TallyParams) XXX_Merge ¶
func (m *TallyParams) XXX_Merge(src proto.Message)
func (*TallyParams) XXX_Size ¶
func (m *TallyParams) XXX_Size() int
func (*TallyParams) XXX_Unmarshal ¶
func (m *TallyParams) XXX_Unmarshal(b []byte) error
type TallyResult ¶
type TallyResult struct { Yes plugchain_sdk_types.Int `protobuf:"bytes,1,opt,name=yes,proto3,customtype=gitee.com/qizikd/plugchain-sdk-go/types.Int" json:"yes"` Abstain plugchain_sdk_types.Int `protobuf:"bytes,2,opt,name=abstain,proto3,customtype=gitee.com/qizikd/plugchain-sdk-go/types.Int" json:"abstain"` No plugchain_sdk_types.Int `protobuf:"bytes,3,opt,name=no,proto3,customtype=gitee.com/qizikd/plugchain-sdk-go/types.Int" json:"no"` NoWithVeto plugchain_sdk_types.Int `` /* 158-byte string literal not displayed */ }
TallyResult defines a standard tally for a governance proposal.
func (TallyResult) Convert ¶
func (t TallyResult) Convert() interface{}
func (*TallyResult) Descriptor ¶
func (*TallyResult) Descriptor() ([]byte, []int)
func (*TallyResult) Equal ¶
func (this *TallyResult) Equal(that interface{}) bool
func (*TallyResult) Marshal ¶
func (m *TallyResult) Marshal() (dAtA []byte, err error)
func (*TallyResult) MarshalToSizedBuffer ¶
func (m *TallyResult) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*TallyResult) ProtoMessage ¶
func (*TallyResult) ProtoMessage()
func (*TallyResult) Reset ¶
func (m *TallyResult) Reset()
func (*TallyResult) Size ¶
func (m *TallyResult) Size() (n int)
func (TallyResult) String ¶
func (tr TallyResult) String() string
func (*TallyResult) Unmarshal ¶
func (m *TallyResult) Unmarshal(dAtA []byte) error
func (*TallyResult) XXX_DiscardUnknown ¶
func (m *TallyResult) XXX_DiscardUnknown()
func (*TallyResult) XXX_Marshal ¶
func (m *TallyResult) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*TallyResult) XXX_Merge ¶
func (m *TallyResult) XXX_Merge(src proto.Message)
func (*TallyResult) XXX_Size ¶
func (m *TallyResult) XXX_Size() int
func (*TallyResult) XXX_Unmarshal ¶
func (m *TallyResult) XXX_Unmarshal(b []byte) error
type TextProposal ¶
type TextProposal struct { Title string `protobuf:"bytes,1,opt,name=title,proto3" json:"title,omitempty"` Description string `protobuf:"bytes,2,opt,name=description,proto3" json:"description,omitempty"` }
TextProposal defines a standard text proposal whose changes need to be manually updated in case of approval.
func (*TextProposal) Descriptor ¶
func (*TextProposal) Descriptor() ([]byte, []int)
func (*TextProposal) Equal ¶
func (this *TextProposal) Equal(that interface{}) bool
func (*TextProposal) GetDescription ¶
func (tp *TextProposal) GetDescription() string
GetDescription returns the proposal description
func (*TextProposal) GetTitle ¶
func (tp *TextProposal) GetTitle() string
GetTitle returns the proposal title
func (*TextProposal) Marshal ¶
func (m *TextProposal) Marshal() (dAtA []byte, err error)
func (*TextProposal) MarshalToSizedBuffer ¶
func (m *TextProposal) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*TextProposal) ProposalRoute ¶
func (tp *TextProposal) ProposalRoute() string
ProposalRoute returns the proposal router key
func (*TextProposal) ProposalType ¶
func (tp *TextProposal) ProposalType() string
ProposalType is "Text"
func (*TextProposal) ProtoMessage ¶
func (*TextProposal) ProtoMessage()
func (*TextProposal) Reset ¶
func (m *TextProposal) Reset()
func (*TextProposal) Size ¶
func (m *TextProposal) Size() (n int)
func (TextProposal) String ¶
func (tp TextProposal) String() string
String implements Stringer interface
func (*TextProposal) Unmarshal ¶
func (m *TextProposal) Unmarshal(dAtA []byte) error
func (*TextProposal) ValidateBasic ¶
func (tp *TextProposal) ValidateBasic() error
ValidateBasic validates the content's title and description of the proposal
func (*TextProposal) XXX_DiscardUnknown ¶
func (m *TextProposal) XXX_DiscardUnknown()
func (*TextProposal) XXX_Marshal ¶
func (m *TextProposal) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*TextProposal) XXX_Merge ¶
func (m *TextProposal) XXX_Merge(src proto.Message)
func (*TextProposal) XXX_Size ¶
func (m *TextProposal) XXX_Size() int
func (*TextProposal) XXX_Unmarshal ¶
func (m *TextProposal) XXX_Unmarshal(b []byte) error
type UnimplementedMsgServer ¶
type UnimplementedMsgServer struct { }
UnimplementedMsgServer can be embedded to have forward compatible implementations.
func (*UnimplementedMsgServer) Deposit ¶
func (*UnimplementedMsgServer) Deposit(ctx context.Context, req *MsgDeposit) (*MsgDepositResponse, error)
func (*UnimplementedMsgServer) SubmitProposal ¶
func (*UnimplementedMsgServer) SubmitProposal(ctx context.Context, req *MsgSubmitProposal) (*MsgSubmitProposalResponse, error)
func (*UnimplementedMsgServer) Vote ¶
func (*UnimplementedMsgServer) Vote(ctx context.Context, req *MsgVote) (*MsgVoteResponse, error)
type UnimplementedQueryServer ¶
type UnimplementedQueryServer struct { }
UnimplementedQueryServer can be embedded to have forward compatible implementations.
func (*UnimplementedQueryServer) Deposit ¶
func (*UnimplementedQueryServer) Deposit(ctx context.Context, req *QueryDepositRequest) (*QueryDepositResponse, error)
func (*UnimplementedQueryServer) Deposits ¶
func (*UnimplementedQueryServer) Deposits(ctx context.Context, req *QueryDepositsRequest) (*QueryDepositsResponse, error)
func (*UnimplementedQueryServer) Params ¶
func (*UnimplementedQueryServer) Params(ctx context.Context, req *QueryParamsRequest) (*QueryParamsResponse, error)
func (*UnimplementedQueryServer) Proposal ¶
func (*UnimplementedQueryServer) Proposal(ctx context.Context, req *QueryProposalRequest) (*QueryProposalResponse, error)
func (*UnimplementedQueryServer) Proposals ¶
func (*UnimplementedQueryServer) Proposals(ctx context.Context, req *QueryProposalsRequest) (*QueryProposalsResponse, error)
func (*UnimplementedQueryServer) TallyResult ¶
func (*UnimplementedQueryServer) TallyResult(ctx context.Context, req *QueryTallyResultRequest) (*QueryTallyResultResponse, error)
func (*UnimplementedQueryServer) Vote ¶
func (*UnimplementedQueryServer) Vote(ctx context.Context, req *QueryVoteRequest) (*QueryVoteResponse, error)
func (*UnimplementedQueryServer) Votes ¶
func (*UnimplementedQueryServer) Votes(ctx context.Context, req *QueryVotesRequest) (*QueryVotesResponse, error)
type Vote ¶
type Vote struct { ProposalId uint64 `protobuf:"varint,1,opt,name=proposal_id,json=proposalId,proto3" json:"proposal_id,omitempty" yaml:"proposal_id"` Voter string `protobuf:"bytes,2,opt,name=voter,proto3" json:"voter,omitempty"` Option VoteOption `protobuf:"varint,3,opt,name=option,proto3,enum=cosmos.gov.v1beta1.VoteOption" json:"option,omitempty"` }
Vote defines a vote on a governance proposal. A Vote consists of a proposal ID, the voter, and the vote option.
func (*Vote) Descriptor ¶
func (*Vote) ProtoMessage ¶
func (*Vote) ProtoMessage()
func (*Vote) XXX_DiscardUnknown ¶
func (m *Vote) XXX_DiscardUnknown()
func (*Vote) XXX_Unmarshal ¶
type VoteOption ¶
type VoteOption int32
VoteOption enumerates the valid vote options for a given governance proposal.
const ( // VOTE_OPTION_UNSPECIFIED defines a no-op vote option. OptionEmpty VoteOption = 0 // VOTE_OPTION_YES defines a yes vote option. OptionYes VoteOption = 1 // VOTE_OPTION_ABSTAIN defines an abstain vote option. OptionAbstain VoteOption = 2 // VOTE_OPTION_NO defines a no vote option. OptionNo VoteOption = 3 // VOTE_OPTION_NO_WITH_VETO defines a no with veto vote option. OptionNoWithVeto VoteOption = 4 )
func (VoteOption) EnumDescriptor ¶
func (VoteOption) EnumDescriptor() ([]byte, []int)
func (VoteOption) String ¶
func (x VoteOption) String() string
type VoteRequest ¶
type VotingParams ¶
type VotingParams struct { // Length of the voting period. VotingPeriod time.Duration `` /* 130-byte string literal not displayed */ }
VotingParams defines the params for voting on governance proposals.
func (*VotingParams) Descriptor ¶
func (*VotingParams) Descriptor() ([]byte, []int)
func (*VotingParams) Marshal ¶
func (m *VotingParams) Marshal() (dAtA []byte, err error)
func (*VotingParams) MarshalToSizedBuffer ¶
func (m *VotingParams) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*VotingParams) ProtoMessage ¶
func (*VotingParams) ProtoMessage()
func (*VotingParams) Reset ¶
func (m *VotingParams) Reset()
func (*VotingParams) Size ¶
func (m *VotingParams) Size() (n int)
func (VotingParams) String ¶
func (vp VotingParams) String() string
func (*VotingParams) Unmarshal ¶
func (m *VotingParams) Unmarshal(dAtA []byte) error
func (*VotingParams) XXX_DiscardUnknown ¶
func (m *VotingParams) XXX_DiscardUnknown()
func (*VotingParams) XXX_Marshal ¶
func (m *VotingParams) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*VotingParams) XXX_Merge ¶
func (m *VotingParams) XXX_Merge(src proto.Message)
func (*VotingParams) XXX_Size ¶
func (m *VotingParams) XXX_Size() int
func (*VotingParams) XXX_Unmarshal ¶
func (m *VotingParams) XXX_Unmarshal(b []byte) error