types

package
v1.7.0-rc2 Latest Latest
Warning

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

Go to latest
Published: Nov 7, 2024 License: Apache-2.0 Imports: 36 Imported by: 1

Documentation

Overview

Package types is a reverse proxy.

It translates gRPC into RESTful JSON APIs.

Index

Constants

View Source
const (
	// ModuleName is the module name constant used in many places
	ModuleName = "volunteer"

	// StoreKey is the store key string for volunteer
	StoreKey = ModuleName

	// RouterKey is the message route for volunteer
	RouterKey = ModuleName
)
View Source
const (
	TypeMsgRegisterVolunteerValidator   = "register_volunteer_validator"
	TypeMsgUnregisterVolunteerValidator = "unregister_volunteer_validator"
)
View Source
const (
	QueryVolunteerValidators = "volunteer_validators"
)

Variables

View Source
var (
	ErrInvalidLengthGenesis        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowGenesis          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupGenesis = fmt.Errorf("proto: unexpected end of group")
)
View Source
var (
	ErrInvalidLengthProposal        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowProposal          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupProposal = fmt.Errorf("proto: unexpected end of group")
)
View Source
var (
	ErrInvalidLengthQuery        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowQuery          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupQuery = fmt.Errorf("proto: unexpected end of group")
)
View Source
var (
	ErrInvalidLengthTx        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowTx          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupTx = fmt.Errorf("proto: unexpected end of group")
)
View Source
var (
	ErrInvalidLengthVolunteervalidator        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowVolunteervalidator          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupVolunteervalidator = fmt.Errorf("proto: unexpected end of group")
)
View Source
var (
	// Keys for store prefixes
	VolunteerValidatorKey = []byte{0x11}
)

Functions

func GetVolunteerValidatorKey

func GetVolunteerValidatorKey(operatorAddr sdk.ValAddress) []byte

func RegisterInterfaces

func RegisterInterfaces(registry types.InterfaceRegistry)

func RegisterLegacyAminoCodec

func RegisterLegacyAminoCodec(cdc *codec.LegacyAmino)

func RegisterMsgServer

func RegisterMsgServer(s grpc1.Server, srv MsgServer)

func RegisterQueryHandler

func RegisterQueryHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error

RegisterQueryHandler registers the http handlers for service Query to "mux". The handlers forward requests to the grpc endpoint over "conn".

func RegisterQueryHandlerClient

func RegisterQueryHandlerClient(ctx context.Context, mux *runtime.ServeMux, client QueryClient) error

RegisterQueryHandlerClient registers the http handlers for service Query to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "QueryClient". Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "QueryClient" doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in "QueryClient" to call the correct interceptors.

func RegisterQueryHandlerFromEndpoint

func RegisterQueryHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error)

RegisterQueryHandlerFromEndpoint is same as RegisterQueryHandler but automatically dials to "endpoint" and closes the connection when "ctx" gets done.

func RegisterQueryHandlerServer

func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, server QueryServer) error

RegisterQueryHandlerServer registers the http handlers for service Query to "mux". UnaryRPC :call QueryServer directly. StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterQueryHandlerFromEndpoint instead.

func RegisterQueryServer

func RegisterQueryServer(s grpc1.Server, srv QueryServer)

func ValidateGenesis

func ValidateGenesis(gs *GenesisState) error

Types

type DistributionKeeper

type DistributionKeeper interface {
	WithdrawValidatorCommission(ctx context.Context, valAddr sdk.ValAddress) (sdk.Coins, error)
	FundCommunityPool(ctx context.Context, amount sdk.Coins, sender sdk.AccAddress) error
}

type GenesisState

type GenesisState struct {
	VolunteerValidators []*VolunteerValidator `protobuf:"bytes,1,rep,name=volunteer_validators,json=volunteerValidators,proto3" json:"volunteer_validators,omitempty"`
}

GenesisState defines the volunteer module's genesis state.

func DefaultGenesisState

func DefaultGenesisState() *GenesisState

func NewGenesisState

func NewGenesisState(volunteerValidators []*VolunteerValidator) *GenesisState

func (*GenesisState) Descriptor

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

func (*GenesisState) GetVolunteerValidators

func (m *GenesisState) GetVolunteerValidators() []*VolunteerValidator

func (*GenesisState) Marshal

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

func (*GenesisState) MarshalTo

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

func (*GenesisState) MarshalToSizedBuffer

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

func (*GenesisState) ProtoMessage

func (*GenesisState) ProtoMessage()

func (*GenesisState) Reset

func (m *GenesisState) Reset()

func (*GenesisState) Size

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

func (*GenesisState) String

func (m *GenesisState) String() string

func (*GenesisState) Unmarshal

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

func (*GenesisState) XXX_DiscardUnknown

func (m *GenesisState) XXX_DiscardUnknown()

func (*GenesisState) XXX_Marshal

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

func (*GenesisState) XXX_Merge

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

func (*GenesisState) XXX_Size

func (m *GenesisState) XXX_Size() int

func (*GenesisState) XXX_Unmarshal

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

type MsgClient

type MsgClient interface {
	// RegisterVolunteerValidator defines a method to register a new volunteer
	// validator.
	RegisterVolunteerValidator(ctx context.Context, in *MsgRegisterVolunteerValidator, opts ...grpc.CallOption) (*MsgRegisterVolunteerValidatorResponse, error)
	// UnregisterVolunteerValidator defines a method to unregister a volunteer
	UnregisterVolunteerValidator(ctx context.Context, in *MsgUnregisterVolunteerValidator, opts ...grpc.CallOption) (*MsgUnregisterVolunteerValidatorResponse, 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 MsgRegisterVolunteerValidator

type MsgRegisterVolunteerValidator struct {
	// authority is the address of the governance account.
	Authority            string            `protobuf:"bytes,1,opt,name=authority,proto3" json:"authority,omitempty"`
	ValidatorDescription types.Description `protobuf:"bytes,2,opt,name=validator_description,json=validatorDescription,proto3" json:"validator_description"`
	DelegatorAddress     string            `` /* 134-byte string literal not displayed */
	ValidatorAddress     string            `` /* 134-byte string literal not displayed */
	Pubkey               *types1.Any       `protobuf:"bytes,5,opt,name=pubkey,proto3" json:"pubkey,omitempty"`
	Amount               types2.Coin       `protobuf:"bytes,6,opt,name=amount,proto3" json:"amount"`
}

MsgRegisterVolunteerValidator defines a message to register a new volunteer validator.

func (*MsgRegisterVolunteerValidator) Descriptor

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

func (*MsgRegisterVolunteerValidator) GetAmount

func (m *MsgRegisterVolunteerValidator) GetAmount() types2.Coin

func (*MsgRegisterVolunteerValidator) GetAuthority

func (m *MsgRegisterVolunteerValidator) GetAuthority() string

func (*MsgRegisterVolunteerValidator) GetDelegatorAddress

func (m *MsgRegisterVolunteerValidator) GetDelegatorAddress() string

func (*MsgRegisterVolunteerValidator) GetPubkey

func (m *MsgRegisterVolunteerValidator) GetPubkey() *types1.Any

func (*MsgRegisterVolunteerValidator) GetValidatorAddress

func (m *MsgRegisterVolunteerValidator) GetValidatorAddress() string

func (*MsgRegisterVolunteerValidator) GetValidatorDescription

func (m *MsgRegisterVolunteerValidator) GetValidatorDescription() types.Description

func (*MsgRegisterVolunteerValidator) Marshal

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

func (*MsgRegisterVolunteerValidator) MarshalTo

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

func (*MsgRegisterVolunteerValidator) MarshalToSizedBuffer

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

func (*MsgRegisterVolunteerValidator) ProtoMessage

func (*MsgRegisterVolunteerValidator) ProtoMessage()

func (*MsgRegisterVolunteerValidator) Reset

func (m *MsgRegisterVolunteerValidator) Reset()

func (*MsgRegisterVolunteerValidator) Size

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

func (*MsgRegisterVolunteerValidator) String

func (MsgRegisterVolunteerValidator) ToCreateValidator

func (*MsgRegisterVolunteerValidator) Unmarshal

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

func (MsgRegisterVolunteerValidator) UnpackInterfaces

func (msg MsgRegisterVolunteerValidator) UnpackInterfaces(unpacker codectypes.AnyUnpacker) error

UnpackInterfaces implements UnpackInterfacesMessage.UnpackInterfaces

func (MsgRegisterVolunteerValidator) ValidateBasic

func (msg MsgRegisterVolunteerValidator) ValidateBasic() error

func (*MsgRegisterVolunteerValidator) XXX_DiscardUnknown

func (m *MsgRegisterVolunteerValidator) XXX_DiscardUnknown()

func (*MsgRegisterVolunteerValidator) XXX_Marshal

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

func (*MsgRegisterVolunteerValidator) XXX_Merge

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

func (*MsgRegisterVolunteerValidator) XXX_Size

func (m *MsgRegisterVolunteerValidator) XXX_Size() int

func (*MsgRegisterVolunteerValidator) XXX_Unmarshal

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

type MsgRegisterVolunteerValidatorResponse

type MsgRegisterVolunteerValidatorResponse struct {
}

MsgRegisterVolunteerValidatorResponse defines the RegisterVolunteerValidator response.

func (*MsgRegisterVolunteerValidatorResponse) Descriptor

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

func (*MsgRegisterVolunteerValidatorResponse) Marshal

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

func (*MsgRegisterVolunteerValidatorResponse) MarshalTo

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

func (*MsgRegisterVolunteerValidatorResponse) MarshalToSizedBuffer

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

func (*MsgRegisterVolunteerValidatorResponse) ProtoMessage

func (*MsgRegisterVolunteerValidatorResponse) ProtoMessage()

func (*MsgRegisterVolunteerValidatorResponse) Reset

func (*MsgRegisterVolunteerValidatorResponse) Size

func (*MsgRegisterVolunteerValidatorResponse) String

func (*MsgRegisterVolunteerValidatorResponse) Unmarshal

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

func (*MsgRegisterVolunteerValidatorResponse) XXX_DiscardUnknown

func (m *MsgRegisterVolunteerValidatorResponse) XXX_DiscardUnknown()

func (*MsgRegisterVolunteerValidatorResponse) XXX_Marshal

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

func (*MsgRegisterVolunteerValidatorResponse) XXX_Merge

func (*MsgRegisterVolunteerValidatorResponse) XXX_Size

func (*MsgRegisterVolunteerValidatorResponse) XXX_Unmarshal

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

type MsgServer

type MsgServer interface {
	// RegisterVolunteerValidator defines a method to register a new volunteer
	// validator.
	RegisterVolunteerValidator(context.Context, *MsgRegisterVolunteerValidator) (*MsgRegisterVolunteerValidatorResponse, error)
	// UnregisterVolunteerValidator defines a method to unregister a volunteer
	UnregisterVolunteerValidator(context.Context, *MsgUnregisterVolunteerValidator) (*MsgUnregisterVolunteerValidatorResponse, error)
}

MsgServer is the server API for Msg service.

type MsgUnregisterVolunteerValidator

type MsgUnregisterVolunteerValidator struct {
	// authority is the address of the governance account.
	Authority        string `protobuf:"bytes,1,opt,name=authority,proto3" json:"authority,omitempty"`
	ValidatorAddress string `` /* 134-byte string literal not displayed */
}

MsgUnregisterVolunteerValidator defines a message to unregister a volunteer validator.

func (*MsgUnregisterVolunteerValidator) Descriptor

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

func (*MsgUnregisterVolunteerValidator) GetAuthority

func (m *MsgUnregisterVolunteerValidator) GetAuthority() string

func (*MsgUnregisterVolunteerValidator) GetValidatorAddress

func (m *MsgUnregisterVolunteerValidator) GetValidatorAddress() string

func (*MsgUnregisterVolunteerValidator) Marshal

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

func (*MsgUnregisterVolunteerValidator) MarshalTo

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

func (*MsgUnregisterVolunteerValidator) MarshalToSizedBuffer

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

func (*MsgUnregisterVolunteerValidator) ProtoMessage

func (*MsgUnregisterVolunteerValidator) ProtoMessage()

func (*MsgUnregisterVolunteerValidator) Reset

func (*MsgUnregisterVolunteerValidator) Size

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

func (*MsgUnregisterVolunteerValidator) String

func (*MsgUnregisterVolunteerValidator) Unmarshal

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

func (MsgUnregisterVolunteerValidator) ValidateBasic

func (msg MsgUnregisterVolunteerValidator) ValidateBasic() error

func (*MsgUnregisterVolunteerValidator) XXX_DiscardUnknown

func (m *MsgUnregisterVolunteerValidator) XXX_DiscardUnknown()

func (*MsgUnregisterVolunteerValidator) XXX_Marshal

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

func (*MsgUnregisterVolunteerValidator) XXX_Merge

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

func (*MsgUnregisterVolunteerValidator) XXX_Size

func (m *MsgUnregisterVolunteerValidator) XXX_Size() int

func (*MsgUnregisterVolunteerValidator) XXX_Unmarshal

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

type MsgUnregisterVolunteerValidatorResponse

type MsgUnregisterVolunteerValidatorResponse struct {
}

MsgUnregisterVolunteerValidatorResponse defines the UnregisterVolunteerValidator response.

func (*MsgUnregisterVolunteerValidatorResponse) Descriptor

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

func (*MsgUnregisterVolunteerValidatorResponse) Marshal

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

func (*MsgUnregisterVolunteerValidatorResponse) MarshalTo

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

func (*MsgUnregisterVolunteerValidatorResponse) MarshalToSizedBuffer

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

func (*MsgUnregisterVolunteerValidatorResponse) ProtoMessage

func (*MsgUnregisterVolunteerValidatorResponse) Reset

func (*MsgUnregisterVolunteerValidatorResponse) Size

func (*MsgUnregisterVolunteerValidatorResponse) String

func (*MsgUnregisterVolunteerValidatorResponse) Unmarshal

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

func (*MsgUnregisterVolunteerValidatorResponse) XXX_DiscardUnknown

func (m *MsgUnregisterVolunteerValidatorResponse) XXX_DiscardUnknown()

func (*MsgUnregisterVolunteerValidatorResponse) XXX_Marshal

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

func (*MsgUnregisterVolunteerValidatorResponse) XXX_Merge

func (*MsgUnregisterVolunteerValidatorResponse) XXX_Size

func (*MsgUnregisterVolunteerValidatorResponse) XXX_Unmarshal

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

type ProposalType

type ProposalType string
const (
	ProposalTypeRegisterVolunteerValidator   ProposalType = "RegisterVolunteerValidator"
	ProposalTypeUnregisterVolunteerValidator ProposalType = "UnregisterVolunteerValidator"
)

type QueryClient

type QueryClient interface {
	// VolunteerValidators
	VolunteerValidators(ctx context.Context, in *QueryVolunteerValidatorsRequest, opts ...grpc.CallOption) (*QueryVolunteerValidatorsResponse, error)
}

QueryClient is the client API for Query service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.

func NewQueryClient

func NewQueryClient(cc grpc1.ClientConn) QueryClient

type QueryServer

type QueryServer interface {
	// VolunteerValidators
	VolunteerValidators(context.Context, *QueryVolunteerValidatorsRequest) (*QueryVolunteerValidatorsResponse, error)
}

QueryServer is the server API for Query service.

type QueryVolunteerValidatorsRequest

type QueryVolunteerValidatorsRequest struct {
}

QueryVolunteerValidatorsRequest

func (*QueryVolunteerValidatorsRequest) Descriptor

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

func (*QueryVolunteerValidatorsRequest) Marshal

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

func (*QueryVolunteerValidatorsRequest) MarshalTo

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

func (*QueryVolunteerValidatorsRequest) MarshalToSizedBuffer

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

func (*QueryVolunteerValidatorsRequest) ProtoMessage

func (*QueryVolunteerValidatorsRequest) ProtoMessage()

func (*QueryVolunteerValidatorsRequest) Reset

func (*QueryVolunteerValidatorsRequest) Size

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

func (*QueryVolunteerValidatorsRequest) String

func (*QueryVolunteerValidatorsRequest) Unmarshal

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

func (*QueryVolunteerValidatorsRequest) XXX_DiscardUnknown

func (m *QueryVolunteerValidatorsRequest) XXX_DiscardUnknown()

func (*QueryVolunteerValidatorsRequest) XXX_Marshal

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

func (*QueryVolunteerValidatorsRequest) XXX_Merge

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

func (*QueryVolunteerValidatorsRequest) XXX_Size

func (m *QueryVolunteerValidatorsRequest) XXX_Size() int

func (*QueryVolunteerValidatorsRequest) XXX_Unmarshal

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

type QueryVolunteerValidatorsResponse

type QueryVolunteerValidatorsResponse struct {
	VolunteerValidators []string `protobuf:"bytes,1,rep,name=volunteer_validators,json=volunteerValidators,proto3" json:"volunteer_validators,omitempty"`
}

QueryVolunteerValidatorsResponse

func (*QueryVolunteerValidatorsResponse) Descriptor

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

func (*QueryVolunteerValidatorsResponse) GetVolunteerValidators

func (m *QueryVolunteerValidatorsResponse) GetVolunteerValidators() []string

func (*QueryVolunteerValidatorsResponse) Marshal

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

func (*QueryVolunteerValidatorsResponse) MarshalTo

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

func (*QueryVolunteerValidatorsResponse) MarshalToSizedBuffer

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

func (*QueryVolunteerValidatorsResponse) ProtoMessage

func (*QueryVolunteerValidatorsResponse) ProtoMessage()

func (*QueryVolunteerValidatorsResponse) Reset

func (*QueryVolunteerValidatorsResponse) Size

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

func (*QueryVolunteerValidatorsResponse) String

func (*QueryVolunteerValidatorsResponse) Unmarshal

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

func (*QueryVolunteerValidatorsResponse) XXX_DiscardUnknown

func (m *QueryVolunteerValidatorsResponse) XXX_DiscardUnknown()

func (*QueryVolunteerValidatorsResponse) XXX_Marshal

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

func (*QueryVolunteerValidatorsResponse) XXX_Merge

func (*QueryVolunteerValidatorsResponse) XXX_Size

func (m *QueryVolunteerValidatorsResponse) XXX_Size() int

func (*QueryVolunteerValidatorsResponse) XXX_Unmarshal

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

type RegisterVolunteerValidatorProposal deprecated

type RegisterVolunteerValidatorProposal 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"`
	ValidatorDescription types.Description `protobuf:"bytes,3,opt,name=validator_description,json=validatorDescription,proto3" json:"validator_description"`
	DelegatorAddress     string            `` /* 134-byte string literal not displayed */
	ValidatorAddress     string            `` /* 134-byte string literal not displayed */
	Pubkey               *types1.Any       `protobuf:"bytes,6,opt,name=pubkey,proto3" json:"pubkey,omitempty"`
	Amount               types2.Coin       `protobuf:"bytes,7,opt,name=amount,proto3" json:"amount"`
}

RegisterVolunteerValidatorProposal

Deprecated: Do not use.

func NewMsgRegisterVolunteerValidator

func NewMsgRegisterVolunteerValidator(title, description string, delAddr sdk.AccAddress, valAddr sdk.ValAddress, pubKey cryptotypes.PubKey,
	selfDelegation sdk.Coin, validatorDescription stakingtypes.Description) (*RegisterVolunteerValidatorProposal, error)

func (*RegisterVolunteerValidatorProposal) Descriptor

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

func (*RegisterVolunteerValidatorProposal) GetDescription

func (p *RegisterVolunteerValidatorProposal) GetDescription() string

GetDescription returns the description of a register volunteer validator proposal.

func (*RegisterVolunteerValidatorProposal) GetTitle

GetTitle returns the title of a register volunteer validator proposal.

func (*RegisterVolunteerValidatorProposal) Marshal

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

func (*RegisterVolunteerValidatorProposal) MarshalTo

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

func (*RegisterVolunteerValidatorProposal) MarshalToSizedBuffer

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

func (RegisterVolunteerValidatorProposal) ProposalRoute

func (p RegisterVolunteerValidatorProposal) ProposalRoute() string

func (RegisterVolunteerValidatorProposal) ProposalType

func (p RegisterVolunteerValidatorProposal) ProposalType() string

ProposalType returns the type

func (*RegisterVolunteerValidatorProposal) ProtoMessage

func (*RegisterVolunteerValidatorProposal) ProtoMessage()

func (*RegisterVolunteerValidatorProposal) Reset

func (*RegisterVolunteerValidatorProposal) Size

func (RegisterVolunteerValidatorProposal) String

String implements the Stringer interface.

func (RegisterVolunteerValidatorProposal) ToCreateValidator

func (*RegisterVolunteerValidatorProposal) Unmarshal

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

func (RegisterVolunteerValidatorProposal) UnpackInterfaces

func (p RegisterVolunteerValidatorProposal) UnpackInterfaces(unpacker codectypes.AnyUnpacker) error

UnpackInterfaces implements UnpackInterfacesMessage.UnpackInterfaces

func (*RegisterVolunteerValidatorProposal) ValidateBasic

func (p *RegisterVolunteerValidatorProposal) ValidateBasic() error

ValidateBasic validates the proposal

func (*RegisterVolunteerValidatorProposal) XXX_DiscardUnknown

func (m *RegisterVolunteerValidatorProposal) XXX_DiscardUnknown()

func (*RegisterVolunteerValidatorProposal) XXX_Marshal

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

func (*RegisterVolunteerValidatorProposal) XXX_Merge

func (*RegisterVolunteerValidatorProposal) XXX_Size

func (*RegisterVolunteerValidatorProposal) XXX_Unmarshal

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

type RegisterVolunteerValidatorProposalWithDeposit deprecated

type RegisterVolunteerValidatorProposalWithDeposit 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"`
	ValidatorDescription types.Description `protobuf:"bytes,3,opt,name=validator_description,json=validatorDescription,proto3" json:"validator_description"`
	DelegatorAddress     string            `` /* 134-byte string literal not displayed */
	ValidatorAddress     string            `` /* 134-byte string literal not displayed */
	Pubkey               *types1.Any       `protobuf:"bytes,6,opt,name=pubkey,proto3" json:"pubkey,omitempty"`
	Amount               types2.Coin       `protobuf:"bytes,7,opt,name=amount,proto3" json:"amount"`
	Deposit              string            `protobuf:"bytes,8,opt,name=deposit,proto3" json:"deposit,omitempty"`
}

RegisterVolunteerValidatorProposalWithDeposit

Deprecated: Do not use.

func (*RegisterVolunteerValidatorProposalWithDeposit) Descriptor

func (*RegisterVolunteerValidatorProposalWithDeposit) Marshal

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

func (*RegisterVolunteerValidatorProposalWithDeposit) MarshalTo

func (*RegisterVolunteerValidatorProposalWithDeposit) MarshalToSizedBuffer

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

func (*RegisterVolunteerValidatorProposalWithDeposit) ProtoMessage

func (*RegisterVolunteerValidatorProposalWithDeposit) Reset

func (*RegisterVolunteerValidatorProposalWithDeposit) Size

func (*RegisterVolunteerValidatorProposalWithDeposit) String

func (*RegisterVolunteerValidatorProposalWithDeposit) Unmarshal

func (*RegisterVolunteerValidatorProposalWithDeposit) XXX_DiscardUnknown

func (m *RegisterVolunteerValidatorProposalWithDeposit) XXX_DiscardUnknown()

func (*RegisterVolunteerValidatorProposalWithDeposit) XXX_Marshal

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

func (*RegisterVolunteerValidatorProposalWithDeposit) XXX_Merge

func (*RegisterVolunteerValidatorProposalWithDeposit) XXX_Size

func (*RegisterVolunteerValidatorProposalWithDeposit) XXX_Unmarshal

type StakingKeeper

type StakingKeeper interface {
	GetValidator(ctx context.Context, addr sdk.ValAddress) (validator stakingtypes.Validator, err error)
	GetValidatorByConsAddr(ctx context.Context, consAddr sdk.ConsAddress) (validator stakingtypes.Validator, err error)
	BondDenom(ctx context.Context) (string, error)
	SetValidator(ctx context.Context, validator stakingtypes.Validator) error
	SetValidatorByConsAddr(ctx context.Context, validator stakingtypes.Validator) error
	SetNewValidatorByPowerIndex(ctx context.Context, validator stakingtypes.Validator) error
	Delegate(
		ctx context.Context, delAddr sdk.AccAddress, bondAmt sdkmath.Int, tokenSrc stakingtypes.BondStatus,
		validator stakingtypes.Validator, subtractAccount bool,
	) (newShares sdkmath.LegacyDec, err error)
	Undelegate(
		ctx context.Context, delAddr sdk.AccAddress, valAddr sdk.ValAddress, sharesAmount sdkmath.LegacyDec,
	) (time.Time, sdkmath.Int, error)
	Hooks() stakingtypes.StakingHooks
	ValidatorAddressCodec() address.Codec
}

type UnimplementedMsgServer

type UnimplementedMsgServer struct {
}

UnimplementedMsgServer can be embedded to have forward compatible implementations.

func (*UnimplementedMsgServer) RegisterVolunteerValidator

type UnimplementedQueryServer

type UnimplementedQueryServer struct {
}

UnimplementedQueryServer can be embedded to have forward compatible implementations.

func (*UnimplementedQueryServer) VolunteerValidators

type UnregisterVolunteerValidatorProposal deprecated

type UnregisterVolunteerValidatorProposal 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"`
	ValidatorAddress string `protobuf:"bytes,3,opt,name=validator_address,json=validatorAddress,proto3" json:"validator_address,omitempty"`
}

UnregisterVolunteerValidatorProposal

Deprecated: Do not use.

func NewUnregisterVolunteerValidatorProposal

func NewUnregisterVolunteerValidatorProposal(title, description string, validatorAddress sdk.ValAddress) *UnregisterVolunteerValidatorProposal

func (*UnregisterVolunteerValidatorProposal) Descriptor

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

func (*UnregisterVolunteerValidatorProposal) GetDescription

func (p *UnregisterVolunteerValidatorProposal) GetDescription() string

GetDescription returns the description of a unregister volunteer validator proposal.

func (*UnregisterVolunteerValidatorProposal) GetTitle

GetTitle returns the title of a unregister volunteer validator proposal.

func (*UnregisterVolunteerValidatorProposal) Marshal

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

func (*UnregisterVolunteerValidatorProposal) MarshalTo

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

func (*UnregisterVolunteerValidatorProposal) MarshalToSizedBuffer

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

func (UnregisterVolunteerValidatorProposal) ProposalRoute

func (p UnregisterVolunteerValidatorProposal) ProposalRoute() string

func (UnregisterVolunteerValidatorProposal) ProposalType

ProposalType returns the type

func (*UnregisterVolunteerValidatorProposal) ProtoMessage

func (*UnregisterVolunteerValidatorProposal) ProtoMessage()

func (*UnregisterVolunteerValidatorProposal) Reset

func (*UnregisterVolunteerValidatorProposal) Size

func (UnregisterVolunteerValidatorProposal) String

String implements the Stringer interface.

func (*UnregisterVolunteerValidatorProposal) Unmarshal

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

func (*UnregisterVolunteerValidatorProposal) ValidateBasic

func (p *UnregisterVolunteerValidatorProposal) ValidateBasic() error

ValidateBasic validates the proposal

func (*UnregisterVolunteerValidatorProposal) XXX_DiscardUnknown

func (m *UnregisterVolunteerValidatorProposal) XXX_DiscardUnknown()

func (*UnregisterVolunteerValidatorProposal) XXX_Marshal

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

func (*UnregisterVolunteerValidatorProposal) XXX_Merge

func (*UnregisterVolunteerValidatorProposal) XXX_Size

func (*UnregisterVolunteerValidatorProposal) XXX_Unmarshal

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

type UnregisterVolunteerValidatorProposalWithDeposit deprecated

type UnregisterVolunteerValidatorProposalWithDeposit 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"`
	ValidatorAddress string `protobuf:"bytes,3,opt,name=validator_address,json=validatorAddress,proto3" json:"validator_address,omitempty"`
	Deposit          string `protobuf:"bytes,4,opt,name=deposit,proto3" json:"deposit,omitempty"`
}

UnregisterVolunteerValidatorProposalWithDeposit

Deprecated: Do not use.

func (*UnregisterVolunteerValidatorProposalWithDeposit) Descriptor

func (*UnregisterVolunteerValidatorProposalWithDeposit) Marshal

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

func (*UnregisterVolunteerValidatorProposalWithDeposit) MarshalTo

func (*UnregisterVolunteerValidatorProposalWithDeposit) MarshalToSizedBuffer

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

func (*UnregisterVolunteerValidatorProposalWithDeposit) ProtoMessage

func (*UnregisterVolunteerValidatorProposalWithDeposit) Reset

func (*UnregisterVolunteerValidatorProposalWithDeposit) Size

func (*UnregisterVolunteerValidatorProposalWithDeposit) String

func (*UnregisterVolunteerValidatorProposalWithDeposit) Unmarshal

func (*UnregisterVolunteerValidatorProposalWithDeposit) XXX_DiscardUnknown

func (m *UnregisterVolunteerValidatorProposalWithDeposit) XXX_DiscardUnknown()

func (*UnregisterVolunteerValidatorProposalWithDeposit) XXX_Marshal

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

func (*UnregisterVolunteerValidatorProposalWithDeposit) XXX_Merge

func (*UnregisterVolunteerValidatorProposalWithDeposit) XXX_Size

func (*UnregisterVolunteerValidatorProposalWithDeposit) XXX_Unmarshal

type VolunteerValidator

type VolunteerValidator struct {
	// address is the address of the validator.
	Address string `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"`
	// power defines the power of the validator.
	Power int64 `protobuf:"varint,2,opt,name=power,proto3" json:"power,omitempty"`
}

VolunteerValidator required for validator set update logic.

func NewVolunteerValidator

func NewVolunteerValidator(valAddress sdk.ValAddress, power int64) VolunteerValidator

func (*VolunteerValidator) Descriptor

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

func (*VolunteerValidator) Marshal

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

func (*VolunteerValidator) MarshalTo

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

func (*VolunteerValidator) MarshalToSizedBuffer

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

func (*VolunteerValidator) ProtoMessage

func (*VolunteerValidator) ProtoMessage()

func (*VolunteerValidator) Reset

func (m *VolunteerValidator) Reset()

func (*VolunteerValidator) Size

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

func (*VolunteerValidator) String

func (m *VolunteerValidator) String() string

func (*VolunteerValidator) Unmarshal

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

func (*VolunteerValidator) XXX_DiscardUnknown

func (m *VolunteerValidator) XXX_DiscardUnknown()

func (*VolunteerValidator) XXX_Marshal

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

func (*VolunteerValidator) XXX_Merge

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

func (*VolunteerValidator) XXX_Size

func (m *VolunteerValidator) XXX_Size() int

func (*VolunteerValidator) XXX_Unmarshal

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

Jump to

Keyboard shortcuts

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