Documentation ¶
Overview ¶
Package types is a reverse proxy.
It translates gRPC into RESTful JSON APIs.
Index ¶
- Constants
- Variables
- func KeyPrefix(p string) []byte
- func ParamKeyTable() paramtypes.KeyTabledeprecated
- func RegisterInterfaces(registry types.InterfaceRegistry)
- func RegisterLegacyAminoCodec(cdc *codec.LegacyAmino)
- func RegisterMsgServiceServer(s grpc1.Server, srv MsgServiceServer)
- func RegisterQueryServiceHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error
- func RegisterQueryServiceHandlerClient(ctx context.Context, mux *runtime.ServeMux, client QueryServiceClient) error
- func RegisterQueryServiceHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, ...) (err error)
- func RegisterQueryServiceHandlerServer(ctx context.Context, mux *runtime.ServeMux, server QueryServiceServer) error
- func RegisterQueryServiceServer(s grpc1.Server, srv QueryServiceServer)
- type AccountKeeper
- type Answer
- func (*Answer) Descriptor() ([]byte, []int)
- func (m *Answer) GetHasMore() bool
- func (m *Answer) GetResults() []Result
- func (m *Answer) GetVariables() []string
- func (m *Answer) Marshal() (dAtA []byte, err error)
- func (m *Answer) MarshalTo(dAtA []byte) (int, error)
- func (m *Answer) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*Answer) ProtoMessage()
- func (m *Answer) Reset()
- func (m *Answer) Size() (n int)
- func (m *Answer) String() string
- func (m *Answer) Unmarshal(dAtA []byte) error
- func (m *Answer) XXX_DiscardUnknown()
- func (m *Answer) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Answer) XXX_Merge(src proto.Message)
- func (m *Answer) XXX_Size() int
- func (m *Answer) XXX_Unmarshal(b []byte) error
- type BankKeeper
- type ContextKey
- type Filter
- func (*Filter) Descriptor() ([]byte, []int)
- func (m *Filter) GetBlacklist() []string
- func (m *Filter) GetWhitelist() []string
- func (m *Filter) Marshal() (dAtA []byte, err error)
- func (m *Filter) MarshalTo(dAtA []byte) (int, error)
- func (m *Filter) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*Filter) ProtoMessage()
- func (m *Filter) Reset()
- func (m *Filter) Size() (n int)
- func (m *Filter) String() string
- func (m *Filter) Unmarshal(dAtA []byte) error
- func (m *Filter) XXX_DiscardUnknown()
- func (m *Filter) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Filter) XXX_Merge(src proto.Message)
- func (m *Filter) XXX_Size() int
- func (m *Filter) XXX_Unmarshal(b []byte) error
- type GasPolicy
- func (*GasPolicy) Descriptor() ([]byte, []int)
- func (m *GasPolicy) GetPredicateCosts() []PredicateCost
- func (m *GasPolicy) Marshal() (dAtA []byte, err error)
- func (m *GasPolicy) MarshalTo(dAtA []byte) (int, error)
- func (m *GasPolicy) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*GasPolicy) ProtoMessage()
- func (m *GasPolicy) Reset()
- func (m *GasPolicy) Size() (n int)
- func (m *GasPolicy) String() string
- func (m *GasPolicy) Unmarshal(dAtA []byte) error
- func (m *GasPolicy) XXX_DiscardUnknown()
- func (m *GasPolicy) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *GasPolicy) XXX_Merge(src proto.Message)
- func (m *GasPolicy) XXX_Size() int
- func (m *GasPolicy) XXX_Unmarshal(b []byte) error
- type GenesisState
- func (*GenesisState) Descriptor() ([]byte, []int)
- func (m *GenesisState) GetParams() Params
- func (m *GenesisState) Marshal() (dAtA []byte, err error)
- func (m *GenesisState) MarshalTo(dAtA []byte) (int, error)
- func (m *GenesisState) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*GenesisState) ProtoMessage()
- func (m *GenesisState) Reset()
- func (m *GenesisState) Size() (n int)
- func (m *GenesisState) String() string
- func (m *GenesisState) Unmarshal(dAtA []byte) error
- func (gs GenesisState) Validate() error
- func (m *GenesisState) XXX_DiscardUnknown()
- func (m *GenesisState) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *GenesisState) XXX_Merge(src proto.Message)
- func (m *GenesisState) XXX_Size() int
- func (m *GenesisState) XXX_Unmarshal(b []byte) error
- type Interpreter
- func (*Interpreter) Descriptor() ([]byte, []int)
- func (m *Interpreter) GetBootstrap() string
- func (m *Interpreter) GetPredicatesFilter() Filter
- func (m *Interpreter) GetVirtualFilesFilter() Filter
- func (m *Interpreter) Marshal() (dAtA []byte, err error)
- func (m *Interpreter) MarshalTo(dAtA []byte) (int, error)
- func (m *Interpreter) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*Interpreter) ProtoMessage()
- func (m *Interpreter) Reset()
- func (m *Interpreter) Size() (n int)
- func (m *Interpreter) String() string
- func (m *Interpreter) Unmarshal(dAtA []byte) error
- func (m *Interpreter) XXX_DiscardUnknown()
- func (m *Interpreter) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Interpreter) XXX_Merge(src proto.Message)
- func (m *Interpreter) XXX_Size() int
- func (m *Interpreter) XXX_Unmarshal(b []byte) error
- type InterpreterOption
- func WithBootstrap(bootstrap string) InterpreterOption
- func WithPredicatesBlacklist(blacklist []string) InterpreterOption
- func WithPredicatesWhitelist(whitelist []string) InterpreterOption
- func WithVirtualFilesBlacklist(blacklist []string) InterpreterOption
- func WithVirtualFilesWhitelist(whitelist []string) InterpreterOption
- type Limits
- func (*Limits) Descriptor() ([]byte, []int)
- func (m *Limits) Marshal() (dAtA []byte, err error)
- func (m *Limits) MarshalTo(dAtA []byte) (int, error)
- func (m *Limits) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*Limits) ProtoMessage()
- func (m *Limits) Reset()
- func (m *Limits) Size() (n int)
- func (m *Limits) String() string
- func (m *Limits) Unmarshal(dAtA []byte) error
- func (m *Limits) XXX_DiscardUnknown()
- func (m *Limits) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Limits) XXX_Merge(src proto.Message)
- func (m *Limits) XXX_Size() int
- func (m *Limits) XXX_Unmarshal(b []byte) error
- type LimitsOption
- type MsgServiceClient
- type MsgServiceServer
- type MsgUpdateParams
- func (*MsgUpdateParams) Descriptor() ([]byte, []int)
- func (m *MsgUpdateParams) GetAuthority() string
- func (m *MsgUpdateParams) GetParams() Params
- func (m *MsgUpdateParams) Marshal() (dAtA []byte, err error)
- func (m *MsgUpdateParams) MarshalTo(dAtA []byte) (int, error)
- func (m *MsgUpdateParams) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*MsgUpdateParams) ProtoMessage()
- func (m *MsgUpdateParams) Reset()
- func (m *MsgUpdateParams) Size() (n int)
- func (m *MsgUpdateParams) String() string
- func (m *MsgUpdateParams) Unmarshal(dAtA []byte) error
- func (m *MsgUpdateParams) XXX_DiscardUnknown()
- func (m *MsgUpdateParams) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *MsgUpdateParams) XXX_Merge(src proto.Message)
- func (m *MsgUpdateParams) XXX_Size() int
- func (m *MsgUpdateParams) XXX_Unmarshal(b []byte) error
- type MsgUpdateParamsResponse
- func (*MsgUpdateParamsResponse) Descriptor() ([]byte, []int)
- func (m *MsgUpdateParamsResponse) Marshal() (dAtA []byte, err error)
- func (m *MsgUpdateParamsResponse) MarshalTo(dAtA []byte) (int, error)
- func (m *MsgUpdateParamsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*MsgUpdateParamsResponse) ProtoMessage()
- func (m *MsgUpdateParamsResponse) Reset()
- func (m *MsgUpdateParamsResponse) Size() (n int)
- func (m *MsgUpdateParamsResponse) String() string
- func (m *MsgUpdateParamsResponse) Unmarshal(dAtA []byte) error
- func (m *MsgUpdateParamsResponse) XXX_DiscardUnknown()
- func (m *MsgUpdateParamsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *MsgUpdateParamsResponse) XXX_Merge(src proto.Message)
- func (m *MsgUpdateParamsResponse) XXX_Size() int
- func (m *MsgUpdateParamsResponse) XXX_Unmarshal(b []byte) error
- type Params
- func (*Params) Descriptor() ([]byte, []int)
- func (m *Params) GetGasPolicy() GasPolicy
- func (m *Params) GetInterpreter() Interpreter
- func (m *Params) GetLimits() Limits
- func (m *Params) Marshal() (dAtA []byte, err error)
- func (m *Params) MarshalTo(dAtA []byte) (int, error)
- func (m *Params) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (p *Params) ParamSetPairs() paramtypes.ParamSetPairsdeprecated
- func (*Params) ProtoMessage()
- func (m *Params) Reset()
- func (m *Params) Size() (n int)
- func (p Params) String() string
- func (m *Params) Unmarshal(dAtA []byte) error
- func (p Params) Validate() error
- func (m *Params) XXX_DiscardUnknown()
- func (m *Params) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Params) XXX_Merge(src proto.Message)
- func (m *Params) XXX_Size() int
- func (m *Params) XXX_Unmarshal(b []byte) error
- type PredicateCost
- func (*PredicateCost) Descriptor() ([]byte, []int)
- func (m *PredicateCost) GetPredicate() string
- func (m *PredicateCost) Marshal() (dAtA []byte, err error)
- func (m *PredicateCost) MarshalTo(dAtA []byte) (int, error)
- func (m *PredicateCost) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*PredicateCost) ProtoMessage()
- func (m *PredicateCost) Reset()
- func (m *PredicateCost) Size() (n int)
- func (m *PredicateCost) String() string
- func (m *PredicateCost) Unmarshal(dAtA []byte) error
- func (m *PredicateCost) XXX_DiscardUnknown()
- func (m *PredicateCost) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *PredicateCost) XXX_Merge(src proto.Message)
- func (m *PredicateCost) XXX_Size() int
- func (m *PredicateCost) XXX_Unmarshal(b []byte) error
- type QueryServiceAskRequest
- func (*QueryServiceAskRequest) Descriptor() ([]byte, []int)
- func (m *QueryServiceAskRequest) GetProgram() string
- func (m *QueryServiceAskRequest) GetQuery() string
- func (m *QueryServiceAskRequest) Marshal() (dAtA []byte, err error)
- func (m *QueryServiceAskRequest) MarshalTo(dAtA []byte) (int, error)
- func (m *QueryServiceAskRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*QueryServiceAskRequest) ProtoMessage()
- func (m *QueryServiceAskRequest) Reset()
- func (m *QueryServiceAskRequest) Size() (n int)
- func (m *QueryServiceAskRequest) String() string
- func (m *QueryServiceAskRequest) Unmarshal(dAtA []byte) error
- func (m *QueryServiceAskRequest) XXX_DiscardUnknown()
- func (m *QueryServiceAskRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *QueryServiceAskRequest) XXX_Merge(src proto.Message)
- func (m *QueryServiceAskRequest) XXX_Size() int
- func (m *QueryServiceAskRequest) XXX_Unmarshal(b []byte) error
- type QueryServiceAskResponse
- func (*QueryServiceAskResponse) Descriptor() ([]byte, []int)
- func (m *QueryServiceAskResponse) GetAnswer() *Answer
- func (m *QueryServiceAskResponse) GetGasUsed() uint64
- func (m *QueryServiceAskResponse) GetHeight() uint64
- func (m *QueryServiceAskResponse) GetUserOutput() string
- func (m *QueryServiceAskResponse) Marshal() (dAtA []byte, err error)
- func (m *QueryServiceAskResponse) MarshalTo(dAtA []byte) (int, error)
- func (m *QueryServiceAskResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*QueryServiceAskResponse) ProtoMessage()
- func (m *QueryServiceAskResponse) Reset()
- func (m *QueryServiceAskResponse) Size() (n int)
- func (m *QueryServiceAskResponse) String() string
- func (m *QueryServiceAskResponse) Unmarshal(dAtA []byte) error
- func (m *QueryServiceAskResponse) XXX_DiscardUnknown()
- func (m *QueryServiceAskResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *QueryServiceAskResponse) XXX_Merge(src proto.Message)
- func (m *QueryServiceAskResponse) XXX_Size() int
- func (m *QueryServiceAskResponse) XXX_Unmarshal(b []byte) error
- type QueryServiceClient
- type QueryServiceParamsRequest
- func (*QueryServiceParamsRequest) Descriptor() ([]byte, []int)
- func (m *QueryServiceParamsRequest) Marshal() (dAtA []byte, err error)
- func (m *QueryServiceParamsRequest) MarshalTo(dAtA []byte) (int, error)
- func (m *QueryServiceParamsRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*QueryServiceParamsRequest) ProtoMessage()
- func (m *QueryServiceParamsRequest) Reset()
- func (m *QueryServiceParamsRequest) Size() (n int)
- func (m *QueryServiceParamsRequest) String() string
- func (m *QueryServiceParamsRequest) Unmarshal(dAtA []byte) error
- func (m *QueryServiceParamsRequest) XXX_DiscardUnknown()
- func (m *QueryServiceParamsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *QueryServiceParamsRequest) XXX_Merge(src proto.Message)
- func (m *QueryServiceParamsRequest) XXX_Size() int
- func (m *QueryServiceParamsRequest) XXX_Unmarshal(b []byte) error
- type QueryServiceParamsResponse
- func (*QueryServiceParamsResponse) Descriptor() ([]byte, []int)
- func (m *QueryServiceParamsResponse) GetParams() Params
- func (m *QueryServiceParamsResponse) Marshal() (dAtA []byte, err error)
- func (m *QueryServiceParamsResponse) MarshalTo(dAtA []byte) (int, error)
- func (m *QueryServiceParamsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*QueryServiceParamsResponse) ProtoMessage()
- func (m *QueryServiceParamsResponse) Reset()
- func (m *QueryServiceParamsResponse) Size() (n int)
- func (m *QueryServiceParamsResponse) String() string
- func (m *QueryServiceParamsResponse) Unmarshal(dAtA []byte) error
- func (m *QueryServiceParamsResponse) XXX_DiscardUnknown()
- func (m *QueryServiceParamsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *QueryServiceParamsResponse) XXX_Merge(src proto.Message)
- func (m *QueryServiceParamsResponse) XXX_Size() int
- func (m *QueryServiceParamsResponse) XXX_Unmarshal(b []byte) error
- type QueryServiceServer
- type Result
- func (*Result) Descriptor() ([]byte, []int)
- func (m *Result) GetError() string
- func (m *Result) GetSubstitutions() []Substitution
- func (m *Result) Marshal() (dAtA []byte, err error)
- func (m *Result) MarshalTo(dAtA []byte) (int, error)
- func (m *Result) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*Result) ProtoMessage()
- func (m *Result) Reset()
- func (m *Result) Size() (n int)
- func (m *Result) String() string
- func (m *Result) Unmarshal(dAtA []byte) error
- func (m *Result) XXX_DiscardUnknown()
- func (m *Result) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Result) XXX_Merge(src proto.Message)
- func (m *Result) XXX_Size() int
- func (m *Result) XXX_Unmarshal(b []byte) error
- type Substitution
- func (*Substitution) Descriptor() ([]byte, []int)
- func (m *Substitution) GetExpression() string
- func (m *Substitution) GetVariable() string
- func (m *Substitution) Marshal() (dAtA []byte, err error)
- func (m *Substitution) MarshalTo(dAtA []byte) (int, error)
- func (m *Substitution) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*Substitution) ProtoMessage()
- func (m *Substitution) Reset()
- func (m *Substitution) Size() (n int)
- func (m *Substitution) String() string
- func (m *Substitution) Unmarshal(dAtA []byte) error
- func (m *Substitution) XXX_DiscardUnknown()
- func (m *Substitution) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Substitution) XXX_Merge(src proto.Message)
- func (m *Substitution) XXX_Size() int
- func (m *Substitution) XXX_Unmarshal(b []byte) error
- type UnimplementedMsgServiceServer
- type UnimplementedQueryServiceServer
- type WasmKeeper
Constants ¶
const ( // AuthKeeperContextKey is the context key for the auth keeper. AuthKeeperContextKey = ContextKey("authKeeper") // BankKeeperContextKey is the context key for the bank keeper. BankKeeperContextKey = ContextKey("bankKeeper") )
const ( // ModuleName defines the module name. ModuleName = "logic" // StoreKey defines the primary module store key. StoreKey = ModuleName // RouterKey defines the module's message routing key. RouterKey = ModuleName // MemStoreKey defines the in-memory store key. MemStoreKey = "mem_logic" )
const DefaultIndex uint64 = 1
DefaultIndex is the default global index.
Variables ¶
var ( InvalidArgument = sdkerrors.RegisterWithGRPCCode(ModuleName, 1, codes.InvalidArgument, "invalid argument") // LimitExceeded is returned when a limit is exceeded. LimitExceeded = sdkerrors.RegisterWithGRPCCode(ModuleName, 2, codes.InvalidArgument, "limit exceeded") // Internal is returned when an internal error occurs. Internal = sdkerrors.RegisterWithGRPCCode(ModuleName, 3, codes.Internal, "internal error") )
var ( ErrInvalidLengthGenesis = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowGenesis = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupGenesis = fmt.Errorf("proto: unexpected end of group") )
var ( ParamsKey = []byte("Params") KeyInterpreter = []byte("Interpreter") KeyLimits = []byte("Limits") )
Parameter store keys.
var ( DefaultPredicatesWhitelist = make([]string, 0) DefaultPredicatesBlacklist = make([]string, 0) DefaultBootstrap = "" DefaultMaxGas = math.NewUint(uint64(100000)) DefaultMaxSize = math.NewUint(uint64(5000)) DefaultMaxResultCount = math.NewUint(uint64(1)) )
var ( ErrInvalidLengthParams = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowParams = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupParams = fmt.Errorf("proto: unexpected end of group") )
var ( ErrInvalidLengthQuery = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowQuery = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupQuery = fmt.Errorf("proto: unexpected end of group") )
Functions ¶
func ParamKeyTable
deprecated
func ParamKeyTable() paramtypes.KeyTable
ParamKeyTable the param key table for launch module.
Deprecated: kept for migration purpose, will be removed soon.
func RegisterInterfaces ¶
func RegisterInterfaces(registry types.InterfaceRegistry)
RegisterInterfaces registers the interfaces types with the interface registry.
func RegisterLegacyAminoCodec ¶
func RegisterLegacyAminoCodec(cdc *codec.LegacyAmino)
RegisterLegacyAminoCodec registers concrete types on the LegacyAmino codec.
func RegisterMsgServiceServer ¶
func RegisterMsgServiceServer(s grpc1.Server, srv MsgServiceServer)
func RegisterQueryServiceHandler ¶
func RegisterQueryServiceHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error
RegisterQueryServiceHandler registers the http handlers for service QueryService to "mux". The handlers forward requests to the grpc endpoint over "conn".
func RegisterQueryServiceHandlerClient ¶
func RegisterQueryServiceHandlerClient(ctx context.Context, mux *runtime.ServeMux, client QueryServiceClient) error
RegisterQueryServiceHandlerClient registers the http handlers for service QueryService to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "QueryServiceClient". Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "QueryServiceClient" doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in "QueryServiceClient" to call the correct interceptors.
func RegisterQueryServiceHandlerFromEndpoint ¶
func RegisterQueryServiceHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error)
RegisterQueryServiceHandlerFromEndpoint is same as RegisterQueryServiceHandler but automatically dials to "endpoint" and closes the connection when "ctx" gets done.
func RegisterQueryServiceHandlerServer ¶
func RegisterQueryServiceHandlerServer(ctx context.Context, mux *runtime.ServeMux, server QueryServiceServer) error
RegisterQueryServiceHandlerServer registers the http handlers for service QueryService to "mux". UnaryRPC :call QueryServiceServer 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 RegisterQueryServiceHandlerFromEndpoint instead.
func RegisterQueryServiceServer ¶
func RegisterQueryServiceServer(s grpc1.Server, srv QueryServiceServer)
Types ¶
type AccountKeeper ¶
AccountKeeper defines the expected account keeper used for simulations (noalias).
type Answer ¶
type Answer struct { // has_more specifies if there are more solutions than the ones returned. HasMore bool `protobuf:"varint,2,opt,name=has_more,json=hasMore,proto3" json:"has_more,omitempty" yaml:"has_more",omitempty` // variables represent all the variables in the query. Variables []string `protobuf:"bytes,3,rep,name=variables,proto3" json:"variables,omitempty" yaml:"variables",omitempty` // results represent all the results of the query. Results []Result `protobuf:"bytes,4,rep,name=results,proto3" json:"results" yaml:"results",omitempty` }
Answer represents the answer to a logic query.
func (*Answer) Descriptor ¶
func (*Answer) GetHasMore ¶
func (*Answer) GetResults ¶
func (*Answer) GetVariables ¶
func (*Answer) MarshalToSizedBuffer ¶
func (*Answer) ProtoMessage ¶
func (*Answer) ProtoMessage()
func (*Answer) XXX_DiscardUnknown ¶
func (m *Answer) XXX_DiscardUnknown()
func (*Answer) XXX_Marshal ¶
func (*Answer) XXX_Unmarshal ¶
type BankKeeper ¶
type BankKeeper interface { GetBalance(ctx context.Context, addr sdk.AccAddress, denom string) sdk.Coin GetAllBalances(ctx context.Context, addr sdk.AccAddress) sdk.Coins GetAccountsBalances(ctx context.Context) []bank.Balance SpendableCoins(ctx context.Context, addr sdk.AccAddress) sdk.Coins LockedCoins(ctx context.Context, addr sdk.AccAddress) sdk.Coins }
BankKeeper defines the expected interface needed to retrieve account balances.
type Filter ¶
type Filter struct { // whitelist specifies a list of strings that are allowed. // If this field is not specified, all strings (in the context of the filter) are allowed. Whitelist []string `protobuf:"bytes,1,rep,name=whitelist,proto3" json:"whitelist,omitempty" yaml:"whitelist"` // blacklist specifies a list of strings that are excluded from the set of allowed strings. // If a string is included in both whitelist and blacklist, it will be excluded. This means that // blacklisted strings prevails over whitelisted ones. // If this field is not specified, no strings are excluded. Blacklist []string `protobuf:"bytes,2,rep,name=blacklist,proto3" json:"blacklist,omitempty" yaml:"blacklist"` }
Filter defines the parameters for filtering the set of strings which can designate anything. The filter is used to whitelist or blacklist strings.
func (*Filter) Descriptor ¶
func (*Filter) GetBlacklist ¶
func (*Filter) GetWhitelist ¶
func (*Filter) MarshalToSizedBuffer ¶
func (*Filter) ProtoMessage ¶
func (*Filter) ProtoMessage()
func (*Filter) XXX_DiscardUnknown ¶
func (m *Filter) XXX_DiscardUnknown()
func (*Filter) XXX_Marshal ¶
func (*Filter) XXX_Unmarshal ¶
type GasPolicy ¶
type GasPolicy struct { // WeightingFactor is the factor that is applied to the unit cost of each predicate // to yield the gas value. // If not provided or set to 0, the value is set to 1. WeightingFactor *cosmossdk_io_math.Uint `` /* 164-byte string literal not displayed */ // DefaultPredicateCost is the default unit cost of a predicate when not specified in the PredicateCosts list. // If not provided or set to 0, the value is set to 1. DefaultPredicateCost *cosmossdk_io_math.Uint `` /* 187-byte string literal not displayed */ // PredicateCosts is the list of predicates and their associated unit costs. PredicateCosts []PredicateCost `protobuf:"bytes,3,rep,name=predicate_costs,json=predicateCosts,proto3" json:"predicate_costs" yaml:"predicate_cost"` }
GasPolicy defines the policy for calculating predicate invocation costs and the resulting gas consumption. The gas policy is defined as a list of predicates and their associated unit costs, a default unit cost for predicates if not specified in the list, and a weighting factor that is applied to the unit cost of each predicate to yield.
func (*GasPolicy) Descriptor ¶
func (*GasPolicy) GetPredicateCosts ¶
func (m *GasPolicy) GetPredicateCosts() []PredicateCost
func (*GasPolicy) MarshalToSizedBuffer ¶
func (*GasPolicy) ProtoMessage ¶
func (*GasPolicy) ProtoMessage()
func (*GasPolicy) XXX_DiscardUnknown ¶
func (m *GasPolicy) XXX_DiscardUnknown()
func (*GasPolicy) XXX_Marshal ¶
func (*GasPolicy) XXX_Unmarshal ¶
type GenesisState ¶
type GenesisState struct { // The state parameters for the logic module. Params Params `protobuf:"bytes,1,opt,name=params,proto3" json:"params"` }
GenesisState defines the logic module's genesis state.
func DefaultGenesis ¶
func DefaultGenesis() *GenesisState
DefaultGenesis returns the default genesis state.
func (*GenesisState) Descriptor ¶
func (*GenesisState) Descriptor() ([]byte, []int)
func (*GenesisState) GetParams ¶
func (m *GenesisState) GetParams() Params
func (*GenesisState) Marshal ¶
func (m *GenesisState) Marshal() (dAtA []byte, err error)
func (*GenesisState) MarshalToSizedBuffer ¶
func (m *GenesisState) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*GenesisState) ProtoMessage ¶
func (*GenesisState) ProtoMessage()
func (*GenesisState) Reset ¶
func (m *GenesisState) Reset()
func (*GenesisState) Size ¶
func (m *GenesisState) Size() (n int)
func (*GenesisState) String ¶
func (m *GenesisState) String() string
func (*GenesisState) Unmarshal ¶
func (m *GenesisState) Unmarshal(dAtA []byte) error
func (GenesisState) Validate ¶
func (gs GenesisState) Validate() error
Validate performs basic genesis state validation returning an error upon any failure.
func (*GenesisState) XXX_DiscardUnknown ¶
func (m *GenesisState) XXX_DiscardUnknown()
func (*GenesisState) XXX_Marshal ¶
func (m *GenesisState) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*GenesisState) XXX_Merge ¶
func (m *GenesisState) XXX_Merge(src proto.Message)
func (*GenesisState) XXX_Size ¶
func (m *GenesisState) XXX_Size() int
func (*GenesisState) XXX_Unmarshal ¶
func (m *GenesisState) XXX_Unmarshal(b []byte) error
type Interpreter ¶
type Interpreter struct { // predicates_filter specifies the filter for the predicates that are allowed to be used by the interpreter. // The filter is used to whitelist or blacklist predicates represented as `<predicate_name>/[<arity>]`, for example: // `findall/3`, or `call`. If a predicate name without arity is included in the filter, then all predicates with that // name will be considered regardless of arity. For example, if `call` is included in the filter, then all predicates // `call/1`, `call/2`, `call/3`... will be allowed. PredicatesFilter Filter `protobuf:"bytes,1,opt,name=predicates_filter,json=predicatesFilter,proto3" json:"predicates_filter" yaml:"predicates_filter"` // bootstrap specifies the initial program to run when booting the logic interpreter. // If not specified, the default boot sequence will be executed. Bootstrap string `protobuf:"bytes,3,opt,name=bootstrap,proto3" json:"bootstrap,omitempty" yaml:"bootstrap"` // virtual_files_filter specifies the filter for the virtual files that are allowed to be used by the interpreter. // The filter is used to whitelist or blacklist virtual files represented as URI, for example: // `file:///path/to/file`, `cosmwasm:cw-storage:axone...?query=foo` // The filter is applied to the components of the URI, for example: // `file:///path/to/file` -> `file`, `/path/to/file` // `cosmwasm:cw-storage:axone...?query=foo` -> `cosmwasm`, `cw-storage`, `axone...`, `query=foo` // If a component is included in the filter, then all components with that name will be considered, starting from the // beginning of the URI. For example, if `file` is included in the filter, then all URIs that start with `file` will be // allowed, regardless of the rest of the components. But `file2` will not be allowed. // If the component is not included in the filter, then the component is ignored and the next component is considered. VirtualFilesFilter Filter `` /* 132-byte string literal not displayed */ }
Interpreter defines the various parameters for the interpreter.
func NewInterpreter ¶
func NewInterpreter(opts ...InterpreterOption) Interpreter
NewInterpreter creates a new Interpreter with the given options.
func (*Interpreter) Descriptor ¶
func (*Interpreter) Descriptor() ([]byte, []int)
func (*Interpreter) GetBootstrap ¶
func (m *Interpreter) GetBootstrap() string
func (*Interpreter) GetPredicatesFilter ¶
func (m *Interpreter) GetPredicatesFilter() Filter
func (*Interpreter) GetVirtualFilesFilter ¶
func (m *Interpreter) GetVirtualFilesFilter() Filter
func (*Interpreter) Marshal ¶
func (m *Interpreter) Marshal() (dAtA []byte, err error)
func (*Interpreter) MarshalToSizedBuffer ¶
func (m *Interpreter) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*Interpreter) ProtoMessage ¶
func (*Interpreter) ProtoMessage()
func (*Interpreter) Reset ¶
func (m *Interpreter) Reset()
func (*Interpreter) Size ¶
func (m *Interpreter) Size() (n int)
func (*Interpreter) String ¶
func (m *Interpreter) String() string
func (*Interpreter) Unmarshal ¶
func (m *Interpreter) Unmarshal(dAtA []byte) error
func (*Interpreter) XXX_DiscardUnknown ¶
func (m *Interpreter) XXX_DiscardUnknown()
func (*Interpreter) XXX_Marshal ¶
func (m *Interpreter) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*Interpreter) XXX_Merge ¶
func (m *Interpreter) XXX_Merge(src proto.Message)
func (*Interpreter) XXX_Size ¶
func (m *Interpreter) XXX_Size() int
func (*Interpreter) XXX_Unmarshal ¶
func (m *Interpreter) XXX_Unmarshal(b []byte) error
type InterpreterOption ¶
type InterpreterOption func(*Interpreter)
InterpreterOption is a functional option for configuring the Interpreter.
func WithBootstrap ¶
func WithBootstrap(bootstrap string) InterpreterOption
WithBootstrap sets the bootstrap program.
func WithPredicatesBlacklist ¶
func WithPredicatesBlacklist(blacklist []string) InterpreterOption
WithPredicatesBlacklist sets the blacklist of predicates.
func WithPredicatesWhitelist ¶
func WithPredicatesWhitelist(whitelist []string) InterpreterOption
WithPredicatesWhitelist sets the whitelist of predicates.
func WithVirtualFilesBlacklist ¶
func WithVirtualFilesBlacklist(blacklist []string) InterpreterOption
WithVirtualFilesBlacklist sets the blacklist of predicates.
func WithVirtualFilesWhitelist ¶
func WithVirtualFilesWhitelist(whitelist []string) InterpreterOption
WithVirtualFilesWhitelist sets the whitelist of predicates.
type Limits ¶
type Limits struct { // max_gas specifies the maximum amount of computing power, measured in "gas," that is allowed to be consumed when // executing a request by the interpreter. The interpreter calculates the gas consumption based on the number and type // of operations that are executed, as well as, in some cases, the complexity of the processed data. // nil value remove max gas limitation. MaxGas *cosmossdk_io_math.Uint `` /* 138-byte string literal not displayed */ // max_size specifies the maximum size, in bytes, that is accepted for a program. // nil value remove size limitation. MaxSize *cosmossdk_io_math.Uint `` /* 132-byte string literal not displayed */ // max_result_count specifies the maximum number of results that can be requested for a query. // nil value remove max result count limitation. MaxResultCount *cosmossdk_io_math.Uint `` /* 163-byte string literal not displayed */ // max_user_output_size specifies the maximum number of bytes to keep in the user output. If the user output exceeds // this size, the interpreter will overwrite the oldest bytes with the new ones to keep the size constant. // nil value or 0 value means that no user output is used at all. MaxUserOutputSize *cosmossdk_io_math.Uint `` /* 178-byte string literal not displayed */ }
Limits defines the limits of the logic module.
func (*Limits) Descriptor ¶
func (*Limits) MarshalToSizedBuffer ¶
func (*Limits) ProtoMessage ¶
func (*Limits) ProtoMessage()
func (*Limits) XXX_DiscardUnknown ¶
func (m *Limits) XXX_DiscardUnknown()
func (*Limits) XXX_Marshal ¶
func (*Limits) XXX_Unmarshal ¶
type LimitsOption ¶
type LimitsOption func(*Limits)
LimitsOption is a functional option for configuring the Limits.
func WithMaxGas ¶
func WithMaxGas(maxGas math.Uint) LimitsOption
WithMaxGas sets the max gas limits for interpreter.
func WithMaxResultCount ¶
func WithMaxResultCount(maxResultCount math.Uint) LimitsOption
WithMaxResultCount sets the maximum number of results that can be requested for a query.
func WithMaxSize ¶
func WithMaxSize(maxSize math.Uint) LimitsOption
WithMaxSize sets the max size limits accepted for a prolog program.
func WithMaxUserOutputSize ¶
func WithMaxUserOutputSize(maxUserOutputSize math.Uint) LimitsOption
WithMaxUserOutputSize specifies the maximum number of bytes to keep in the user output.
type MsgServiceClient ¶
type MsgServiceClient interface { // UpdateParams defined a governance operation for updating the x/logic module parameters. // The authority is hard-coded to the Cosmos SDK x/gov module account UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) }
MsgServiceClient is the client API for MsgService service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
func NewMsgServiceClient ¶
func NewMsgServiceClient(cc grpc1.ClientConn) MsgServiceClient
type MsgServiceServer ¶
type MsgServiceServer interface { // UpdateParams defined a governance operation for updating the x/logic module parameters. // The authority is hard-coded to the Cosmos SDK x/gov module account UpdateParams(context.Context, *MsgUpdateParams) (*MsgUpdateParamsResponse, error) }
MsgServiceServer is the server API for MsgService service.
type MsgUpdateParams ¶
type MsgUpdateParams struct { // authority is the address of the governance account. Authority string `protobuf:"bytes,1,opt,name=authority,proto3" json:"authority,omitempty"` // params defines the x/logic parameters to update. // NOTE: All parameters must be supplied. Params Params `protobuf:"bytes,2,opt,name=params,proto3" json:"params"` }
MsgUpdateParams defines a Msg for updating the x/logic module parameters.
func (*MsgUpdateParams) Descriptor ¶
func (*MsgUpdateParams) Descriptor() ([]byte, []int)
func (*MsgUpdateParams) GetAuthority ¶
func (m *MsgUpdateParams) GetAuthority() string
func (*MsgUpdateParams) GetParams ¶
func (m *MsgUpdateParams) GetParams() Params
func (*MsgUpdateParams) Marshal ¶
func (m *MsgUpdateParams) Marshal() (dAtA []byte, err error)
func (*MsgUpdateParams) MarshalToSizedBuffer ¶
func (m *MsgUpdateParams) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*MsgUpdateParams) ProtoMessage ¶
func (*MsgUpdateParams) ProtoMessage()
func (*MsgUpdateParams) Reset ¶
func (m *MsgUpdateParams) Reset()
func (*MsgUpdateParams) Size ¶
func (m *MsgUpdateParams) Size() (n int)
func (*MsgUpdateParams) String ¶
func (m *MsgUpdateParams) String() string
func (*MsgUpdateParams) Unmarshal ¶
func (m *MsgUpdateParams) Unmarshal(dAtA []byte) error
func (*MsgUpdateParams) XXX_DiscardUnknown ¶
func (m *MsgUpdateParams) XXX_DiscardUnknown()
func (*MsgUpdateParams) XXX_Marshal ¶
func (m *MsgUpdateParams) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*MsgUpdateParams) XXX_Merge ¶
func (m *MsgUpdateParams) XXX_Merge(src proto.Message)
func (*MsgUpdateParams) XXX_Size ¶
func (m *MsgUpdateParams) XXX_Size() int
func (*MsgUpdateParams) XXX_Unmarshal ¶
func (m *MsgUpdateParams) XXX_Unmarshal(b []byte) error
type MsgUpdateParamsResponse ¶
type MsgUpdateParamsResponse struct { }
MsgUpdateParamsResponse defines the response structure for executing a MsgUpdateParams message.
func (*MsgUpdateParamsResponse) Descriptor ¶
func (*MsgUpdateParamsResponse) Descriptor() ([]byte, []int)
func (*MsgUpdateParamsResponse) Marshal ¶
func (m *MsgUpdateParamsResponse) Marshal() (dAtA []byte, err error)
func (*MsgUpdateParamsResponse) MarshalTo ¶
func (m *MsgUpdateParamsResponse) MarshalTo(dAtA []byte) (int, error)
func (*MsgUpdateParamsResponse) MarshalToSizedBuffer ¶
func (m *MsgUpdateParamsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*MsgUpdateParamsResponse) ProtoMessage ¶
func (*MsgUpdateParamsResponse) ProtoMessage()
func (*MsgUpdateParamsResponse) Reset ¶
func (m *MsgUpdateParamsResponse) Reset()
func (*MsgUpdateParamsResponse) Size ¶
func (m *MsgUpdateParamsResponse) Size() (n int)
func (*MsgUpdateParamsResponse) String ¶
func (m *MsgUpdateParamsResponse) String() string
func (*MsgUpdateParamsResponse) Unmarshal ¶
func (m *MsgUpdateParamsResponse) Unmarshal(dAtA []byte) error
func (*MsgUpdateParamsResponse) XXX_DiscardUnknown ¶
func (m *MsgUpdateParamsResponse) XXX_DiscardUnknown()
func (*MsgUpdateParamsResponse) XXX_Marshal ¶
func (m *MsgUpdateParamsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*MsgUpdateParamsResponse) XXX_Merge ¶
func (m *MsgUpdateParamsResponse) XXX_Merge(src proto.Message)
func (*MsgUpdateParamsResponse) XXX_Size ¶
func (m *MsgUpdateParamsResponse) XXX_Size() int
func (*MsgUpdateParamsResponse) XXX_Unmarshal ¶
func (m *MsgUpdateParamsResponse) XXX_Unmarshal(b []byte) error
type Params ¶
type Params struct { // Interpreter specifies the parameter for the logic interpreter. Interpreter Interpreter `protobuf:"bytes,1,opt,name=interpreter,proto3" json:"interpreter" yaml:"interpreter"` // Limits defines the limits of the logic module. // The limits are used to prevent the interpreter from running for too long. // If the interpreter runs for too long, the execution will be aborted. Limits Limits `protobuf:"bytes,2,opt,name=limits,proto3" json:"limits" yaml:"limits"` // GasPolicy defines the parameters for calculating predicate invocation costs. GasPolicy GasPolicy `protobuf:"bytes,3,opt,name=gas_policy,json=gasPolicy,proto3" json:"gas_policy" yaml:"gas_policy"` }
Params defines all the configuration parameters of the "logic" module.
func NewParams ¶
func NewParams(interpreter Interpreter, limits Limits) Params
NewParams creates a new Params object.
func (*Params) Descriptor ¶
func (*Params) GetGasPolicy ¶
func (*Params) GetInterpreter ¶
func (m *Params) GetInterpreter() Interpreter
func (*Params) MarshalToSizedBuffer ¶
func (*Params) ParamSetPairs
deprecated
func (p *Params) ParamSetPairs() paramtypes.ParamSetPairs
ParamSetPairs get the params.ParamSet.
Deprecated: kept for migration purpose, will be removed soon.
func (*Params) ProtoMessage ¶
func (*Params) ProtoMessage()
func (*Params) XXX_DiscardUnknown ¶
func (m *Params) XXX_DiscardUnknown()
func (*Params) XXX_Marshal ¶
func (*Params) XXX_Unmarshal ¶
type PredicateCost ¶
type PredicateCost struct { // Predicate is the name of the predicate, optionally followed by its arity (e.g. "findall/3"). // If no arity is specified, the unit cost is applied to all predicates with the same name. Predicate string `protobuf:"bytes,1,opt,name=predicate,proto3" json:"predicate,omitempty" yaml:"predicate"` // Cost is the unit cost of the predicate. Cost *cosmossdk_io_math.Uint `protobuf:"bytes,2,opt,name=cost,proto3,customtype=cosmossdk.io/math.Uint" json:"cost,omitempty" yaml:"cost",omitempty` }
PredicateCost defines the unit cost of a predicate during its invocation by the interpreter.
func (*PredicateCost) Descriptor ¶
func (*PredicateCost) Descriptor() ([]byte, []int)
func (*PredicateCost) GetPredicate ¶
func (m *PredicateCost) GetPredicate() string
func (*PredicateCost) Marshal ¶
func (m *PredicateCost) Marshal() (dAtA []byte, err error)
func (*PredicateCost) MarshalToSizedBuffer ¶
func (m *PredicateCost) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*PredicateCost) ProtoMessage ¶
func (*PredicateCost) ProtoMessage()
func (*PredicateCost) Reset ¶
func (m *PredicateCost) Reset()
func (*PredicateCost) Size ¶
func (m *PredicateCost) Size() (n int)
func (*PredicateCost) String ¶
func (m *PredicateCost) String() string
func (*PredicateCost) Unmarshal ¶
func (m *PredicateCost) Unmarshal(dAtA []byte) error
func (*PredicateCost) XXX_DiscardUnknown ¶
func (m *PredicateCost) XXX_DiscardUnknown()
func (*PredicateCost) XXX_Marshal ¶
func (m *PredicateCost) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*PredicateCost) XXX_Merge ¶
func (m *PredicateCost) XXX_Merge(src proto.Message)
func (*PredicateCost) XXX_Size ¶
func (m *PredicateCost) XXX_Size() int
func (*PredicateCost) XXX_Unmarshal ¶
func (m *PredicateCost) XXX_Unmarshal(b []byte) error
type QueryServiceAskRequest ¶
type QueryServiceAskRequest struct { // program is the logic program to be queried. Program string `protobuf:"bytes,1,opt,name=program,proto3" json:"program,omitempty" yaml:"program",omitempty` // query is the query string to be executed. Query string `protobuf:"bytes,2,opt,name=query,proto3" json:"query,omitempty" yaml:"query",omitempty` // limit specifies the maximum number of solutions to be returned. This field is governed by // max_result_count, which defines the upper limit of results that may be requested per query. // If this field is not explicitly set, a default value of 1 is applied. Limit *cosmossdk_io_math.Uint `protobuf:"bytes,3,opt,name=limit,proto3,customtype=cosmossdk.io/math.Uint" json:"limit,omitempty" yaml:"limit",omitempty` }
QueryServiceAskRequest is request type for the QueryService/Ask RPC method.
func (*QueryServiceAskRequest) Descriptor ¶
func (*QueryServiceAskRequest) Descriptor() ([]byte, []int)
func (*QueryServiceAskRequest) GetProgram ¶
func (m *QueryServiceAskRequest) GetProgram() string
func (*QueryServiceAskRequest) GetQuery ¶
func (m *QueryServiceAskRequest) GetQuery() string
func (*QueryServiceAskRequest) Marshal ¶
func (m *QueryServiceAskRequest) Marshal() (dAtA []byte, err error)
func (*QueryServiceAskRequest) MarshalTo ¶
func (m *QueryServiceAskRequest) MarshalTo(dAtA []byte) (int, error)
func (*QueryServiceAskRequest) MarshalToSizedBuffer ¶
func (m *QueryServiceAskRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*QueryServiceAskRequest) ProtoMessage ¶
func (*QueryServiceAskRequest) ProtoMessage()
func (*QueryServiceAskRequest) Reset ¶
func (m *QueryServiceAskRequest) Reset()
func (*QueryServiceAskRequest) Size ¶
func (m *QueryServiceAskRequest) Size() (n int)
func (*QueryServiceAskRequest) String ¶
func (m *QueryServiceAskRequest) String() string
func (*QueryServiceAskRequest) Unmarshal ¶
func (m *QueryServiceAskRequest) Unmarshal(dAtA []byte) error
func (*QueryServiceAskRequest) XXX_DiscardUnknown ¶
func (m *QueryServiceAskRequest) XXX_DiscardUnknown()
func (*QueryServiceAskRequest) XXX_Marshal ¶
func (m *QueryServiceAskRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*QueryServiceAskRequest) XXX_Merge ¶
func (m *QueryServiceAskRequest) XXX_Merge(src proto.Message)
func (*QueryServiceAskRequest) XXX_Size ¶
func (m *QueryServiceAskRequest) XXX_Size() int
func (*QueryServiceAskRequest) XXX_Unmarshal ¶
func (m *QueryServiceAskRequest) XXX_Unmarshal(b []byte) error
type QueryServiceAskResponse ¶
type QueryServiceAskResponse struct { // height is the block height at which the query was executed. Height uint64 `protobuf:"varint,1,opt,name=height,proto3" json:"height,omitempty" yaml:"height",omitempty` // gas_used is the amount of gas used to execute the query. GasUsed uint64 `protobuf:"varint,2,opt,name=gas_used,json=gasUsed,proto3" json:"gas_used,omitempty" yaml:"gas_used",omitempty` // answer is the answer to the query. Answer *Answer `protobuf:"bytes,3,opt,name=answer,proto3" json:"answer,omitempty" yaml:"answer",omitempty` // user_output is the output of the query execution, if any. // the length of the output is limited by the max_query_output_size parameter. UserOutput string `protobuf:"bytes,4,opt,name=user_output,json=userOutput,proto3" json:"user_output,omitempty" yaml:"user_output",omitempty` }
QueryServiceAskResponse is response type for the QueryService/Ask RPC method.
func (*QueryServiceAskResponse) Descriptor ¶
func (*QueryServiceAskResponse) Descriptor() ([]byte, []int)
func (*QueryServiceAskResponse) GetAnswer ¶
func (m *QueryServiceAskResponse) GetAnswer() *Answer
func (*QueryServiceAskResponse) GetGasUsed ¶
func (m *QueryServiceAskResponse) GetGasUsed() uint64
func (*QueryServiceAskResponse) GetHeight ¶
func (m *QueryServiceAskResponse) GetHeight() uint64
func (*QueryServiceAskResponse) GetUserOutput ¶
func (m *QueryServiceAskResponse) GetUserOutput() string
func (*QueryServiceAskResponse) Marshal ¶
func (m *QueryServiceAskResponse) Marshal() (dAtA []byte, err error)
func (*QueryServiceAskResponse) MarshalTo ¶
func (m *QueryServiceAskResponse) MarshalTo(dAtA []byte) (int, error)
func (*QueryServiceAskResponse) MarshalToSizedBuffer ¶
func (m *QueryServiceAskResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*QueryServiceAskResponse) ProtoMessage ¶
func (*QueryServiceAskResponse) ProtoMessage()
func (*QueryServiceAskResponse) Reset ¶
func (m *QueryServiceAskResponse) Reset()
func (*QueryServiceAskResponse) Size ¶
func (m *QueryServiceAskResponse) Size() (n int)
func (*QueryServiceAskResponse) String ¶
func (m *QueryServiceAskResponse) String() string
func (*QueryServiceAskResponse) Unmarshal ¶
func (m *QueryServiceAskResponse) Unmarshal(dAtA []byte) error
func (*QueryServiceAskResponse) XXX_DiscardUnknown ¶
func (m *QueryServiceAskResponse) XXX_DiscardUnknown()
func (*QueryServiceAskResponse) XXX_Marshal ¶
func (m *QueryServiceAskResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*QueryServiceAskResponse) XXX_Merge ¶
func (m *QueryServiceAskResponse) XXX_Merge(src proto.Message)
func (*QueryServiceAskResponse) XXX_Size ¶
func (m *QueryServiceAskResponse) XXX_Size() int
func (*QueryServiceAskResponse) XXX_Unmarshal ¶
func (m *QueryServiceAskResponse) XXX_Unmarshal(b []byte) error
type QueryServiceClient ¶
type QueryServiceClient interface { // Params queries all parameters for the logic module. Params(ctx context.Context, in *QueryServiceParamsRequest, opts ...grpc.CallOption) (*QueryServiceParamsResponse, error) // Ask executes a logic query and returns the solutions found. // Since the query is without any side-effect, the query is not executed in the context of a transaction and no fee // is charged for this, but the execution is constrained by the current limits configured in the module. Ask(ctx context.Context, in *QueryServiceAskRequest, opts ...grpc.CallOption) (*QueryServiceAskResponse, error) }
QueryServiceClient is the client API for QueryService service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
func NewQueryServiceClient ¶
func NewQueryServiceClient(cc grpc1.ClientConn) QueryServiceClient
type QueryServiceParamsRequest ¶
type QueryServiceParamsRequest struct { }
QueryServiceParamsRequest is request type for the QueryService/Params RPC method.
func (*QueryServiceParamsRequest) Descriptor ¶
func (*QueryServiceParamsRequest) Descriptor() ([]byte, []int)
func (*QueryServiceParamsRequest) Marshal ¶
func (m *QueryServiceParamsRequest) Marshal() (dAtA []byte, err error)
func (*QueryServiceParamsRequest) MarshalTo ¶
func (m *QueryServiceParamsRequest) MarshalTo(dAtA []byte) (int, error)
func (*QueryServiceParamsRequest) MarshalToSizedBuffer ¶
func (m *QueryServiceParamsRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*QueryServiceParamsRequest) ProtoMessage ¶
func (*QueryServiceParamsRequest) ProtoMessage()
func (*QueryServiceParamsRequest) Reset ¶
func (m *QueryServiceParamsRequest) Reset()
func (*QueryServiceParamsRequest) Size ¶
func (m *QueryServiceParamsRequest) Size() (n int)
func (*QueryServiceParamsRequest) String ¶
func (m *QueryServiceParamsRequest) String() string
func (*QueryServiceParamsRequest) Unmarshal ¶
func (m *QueryServiceParamsRequest) Unmarshal(dAtA []byte) error
func (*QueryServiceParamsRequest) XXX_DiscardUnknown ¶
func (m *QueryServiceParamsRequest) XXX_DiscardUnknown()
func (*QueryServiceParamsRequest) XXX_Marshal ¶
func (m *QueryServiceParamsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*QueryServiceParamsRequest) XXX_Merge ¶
func (m *QueryServiceParamsRequest) XXX_Merge(src proto.Message)
func (*QueryServiceParamsRequest) XXX_Size ¶
func (m *QueryServiceParamsRequest) XXX_Size() int
func (*QueryServiceParamsRequest) XXX_Unmarshal ¶
func (m *QueryServiceParamsRequest) XXX_Unmarshal(b []byte) error
type QueryServiceParamsResponse ¶
type QueryServiceParamsResponse struct { // params holds all the parameters of this module. Params Params `protobuf:"bytes,1,opt,name=params,proto3" json:"params" yaml:"params",omitempty` }
QueryServiceParamsResponse is response type for the QueryService/Params RPC method.
func (*QueryServiceParamsResponse) Descriptor ¶
func (*QueryServiceParamsResponse) Descriptor() ([]byte, []int)
func (*QueryServiceParamsResponse) GetParams ¶
func (m *QueryServiceParamsResponse) GetParams() Params
func (*QueryServiceParamsResponse) Marshal ¶
func (m *QueryServiceParamsResponse) Marshal() (dAtA []byte, err error)
func (*QueryServiceParamsResponse) MarshalTo ¶
func (m *QueryServiceParamsResponse) MarshalTo(dAtA []byte) (int, error)
func (*QueryServiceParamsResponse) MarshalToSizedBuffer ¶
func (m *QueryServiceParamsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*QueryServiceParamsResponse) ProtoMessage ¶
func (*QueryServiceParamsResponse) ProtoMessage()
func (*QueryServiceParamsResponse) Reset ¶
func (m *QueryServiceParamsResponse) Reset()
func (*QueryServiceParamsResponse) Size ¶
func (m *QueryServiceParamsResponse) Size() (n int)
func (*QueryServiceParamsResponse) String ¶
func (m *QueryServiceParamsResponse) String() string
func (*QueryServiceParamsResponse) Unmarshal ¶
func (m *QueryServiceParamsResponse) Unmarshal(dAtA []byte) error
func (*QueryServiceParamsResponse) XXX_DiscardUnknown ¶
func (m *QueryServiceParamsResponse) XXX_DiscardUnknown()
func (*QueryServiceParamsResponse) XXX_Marshal ¶
func (m *QueryServiceParamsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*QueryServiceParamsResponse) XXX_Merge ¶
func (m *QueryServiceParamsResponse) XXX_Merge(src proto.Message)
func (*QueryServiceParamsResponse) XXX_Size ¶
func (m *QueryServiceParamsResponse) XXX_Size() int
func (*QueryServiceParamsResponse) XXX_Unmarshal ¶
func (m *QueryServiceParamsResponse) XXX_Unmarshal(b []byte) error
type QueryServiceServer ¶
type QueryServiceServer interface { // Params queries all parameters for the logic module. Params(context.Context, *QueryServiceParamsRequest) (*QueryServiceParamsResponse, error) // Ask executes a logic query and returns the solutions found. // Since the query is without any side-effect, the query is not executed in the context of a transaction and no fee // is charged for this, but the execution is constrained by the current limits configured in the module. Ask(context.Context, *QueryServiceAskRequest) (*QueryServiceAskResponse, error) }
QueryServiceServer is the server API for QueryService service.
type Result ¶
type Result struct { // error specifies the error message if the query caused an error. Error string `protobuf:"bytes,5,opt,name=error,proto3" json:"error,omitempty" yaml:"error",omitempty` // substitutions represent all the substitutions made to the variables in the query to obtain the answer. Substitutions []Substitution `protobuf:"bytes,2,rep,name=substitutions,proto3" json:"substitutions" yaml:"substitutions",omitempty` }
Result represents the result of a query.
func (*Result) Descriptor ¶
func (*Result) GetSubstitutions ¶
func (m *Result) GetSubstitutions() []Substitution
func (*Result) MarshalToSizedBuffer ¶
func (*Result) ProtoMessage ¶
func (*Result) ProtoMessage()
func (*Result) XXX_DiscardUnknown ¶
func (m *Result) XXX_DiscardUnknown()
func (*Result) XXX_Marshal ¶
func (*Result) XXX_Unmarshal ¶
type Substitution ¶
type Substitution struct { // variable is the name of the variable. Variable string `protobuf:"bytes,1,opt,name=variable,proto3" json:"variable,omitempty" yaml:"variable",omitempty` // expression is the value substituted for the variable, represented directly as a Prolog term (e.g., atom, number, compound). Expression string `protobuf:"bytes,2,opt,name=expression,proto3" json:"expression,omitempty" yaml:"expression",omitempty` }
Substitution represents a substitution made to the variables in the query to obtain the answer.
func (*Substitution) Descriptor ¶
func (*Substitution) Descriptor() ([]byte, []int)
func (*Substitution) GetExpression ¶
func (m *Substitution) GetExpression() string
func (*Substitution) GetVariable ¶
func (m *Substitution) GetVariable() string
func (*Substitution) Marshal ¶
func (m *Substitution) Marshal() (dAtA []byte, err error)
func (*Substitution) MarshalToSizedBuffer ¶
func (m *Substitution) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*Substitution) ProtoMessage ¶
func (*Substitution) ProtoMessage()
func (*Substitution) Reset ¶
func (m *Substitution) Reset()
func (*Substitution) Size ¶
func (m *Substitution) Size() (n int)
func (*Substitution) String ¶
func (m *Substitution) String() string
func (*Substitution) Unmarshal ¶
func (m *Substitution) Unmarshal(dAtA []byte) error
func (*Substitution) XXX_DiscardUnknown ¶
func (m *Substitution) XXX_DiscardUnknown()
func (*Substitution) XXX_Marshal ¶
func (m *Substitution) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*Substitution) XXX_Merge ¶
func (m *Substitution) XXX_Merge(src proto.Message)
func (*Substitution) XXX_Size ¶
func (m *Substitution) XXX_Size() int
func (*Substitution) XXX_Unmarshal ¶
func (m *Substitution) XXX_Unmarshal(b []byte) error
type UnimplementedMsgServiceServer ¶
type UnimplementedMsgServiceServer struct { }
UnimplementedMsgServiceServer can be embedded to have forward compatible implementations.
func (*UnimplementedMsgServiceServer) UpdateParams ¶
func (*UnimplementedMsgServiceServer) UpdateParams(ctx context.Context, req *MsgUpdateParams) (*MsgUpdateParamsResponse, error)
type UnimplementedQueryServiceServer ¶
type UnimplementedQueryServiceServer struct { }
UnimplementedQueryServiceServer can be embedded to have forward compatible implementations.
func (*UnimplementedQueryServiceServer) Ask ¶
func (*UnimplementedQueryServiceServer) Ask(ctx context.Context, req *QueryServiceAskRequest) (*QueryServiceAskResponse, error)
func (*UnimplementedQueryServiceServer) Params ¶
func (*UnimplementedQueryServiceServer) Params(ctx context.Context, req *QueryServiceParamsRequest) (*QueryServiceParamsResponse, error)
type WasmKeeper ¶
type WasmKeeper interface {
QuerySmart(ctx context.Context, contractAddr sdk.AccAddress, req []byte) ([]byte, error)
}
WasmKeeper defines the expected interface needed to request smart contracts.