Documentation ¶
Overview ¶
Code generated by protoconstructorgen.py. DO NOT EDIT.
Index ¶
- Constants
- Variables
- func DataProviderRewardsPrefixKey(acc sdk.AccAddress) []byte
- func DataRequesterFeePrefixKey(acc sdk.AccAddress) []byte
- func DataSourceStoreKey(dataSourceID DataSourceID) []byte
- func OracleScriptStoreKey(oracleScriptID OracleScriptID) []byte
- func RegisterCodec(cdc *codec.Codec)
- func ReportStoreKey(requestID RequestID) []byte
- func ReporterStoreKey(validatorAddress sdk.ValAddress, reporterAddress sdk.AccAddress) []byte
- func ReportersOfValidatorPrefixKey(val sdk.ValAddress) []byte
- func ReportsOfValidatorPrefixKey(reqID RequestID, val sdk.ValAddress) []byte
- func RequestStoreKey(requestID RequestID) []byte
- func ResultStoreKey(requestID RequestID) []byte
- func ValidatorStatusStoreKey(v sdk.ValAddress) []byte
- func WrapMaxError(err error, got int, max int) error
- type AccountKeeper
- type BaseEnv
- func (env *BaseEnv) AskExternalData(eid int64, did int64, data []byte) error
- func (env *BaseEnv) GetAnsCount() (int64, error)
- func (env *BaseEnv) GetAskCount() int64
- func (env *BaseEnv) GetCalldata() []byte
- func (env *BaseEnv) GetExternalData(eid int64, vid int64) ([]byte, error)
- func (env *BaseEnv) GetExternalDataStatus(eid int64, vid int64) (int64, error)
- func (env *BaseEnv) GetMinCount() int64
- func (env *BaseEnv) SetReturnData(data []byte) error
- type CoinDecProto
- type CoinProto
- type DataSource
- func (*DataSource) Descriptor() ([]byte, []int)
- func (this *DataSource) Equal(that interface{}) bool
- func (m *DataSource) GetDescription() string
- func (m *DataSource) GetFilename() string
- func (m *DataSource) GetName() string
- func (m *DataSource) GetOwner() github_com_cosmos_cosmos_sdk_types.AccAddress
- func (m *DataSource) Marshal() (dAtA []byte, err error)
- func (m *DataSource) MarshalTo(dAtA []byte) (int, error)
- func (m *DataSource) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*DataSource) ProtoMessage()
- func (m *DataSource) Reset()
- func (m *DataSource) Size() (n int)
- func (m *DataSource) String() string
- func (m *DataSource) Unmarshal(dAtA []byte) error
- func (m *DataSource) XXX_DiscardUnknown()
- func (m *DataSource) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *DataSource) XXX_Merge(src proto.Message)
- func (m *DataSource) XXX_Size() int
- func (m *DataSource) XXX_Unmarshal(b []byte) error
- type DataSourceID
- type DistrKeeper
- type ExecuteEnv
- type ExternalID
- type MsgActivate
- func (*MsgActivate) Descriptor() ([]byte, []int)
- func (this *MsgActivate) Equal(that interface{}) bool
- func (msg MsgActivate) GetSignBytes() []byte
- func (msg MsgActivate) GetSigners() []sdk.AccAddress
- func (m *MsgActivate) GetValidator() github_com_cosmos_cosmos_sdk_types.ValAddress
- func (m *MsgActivate) Marshal() (dAtA []byte, err error)
- func (m *MsgActivate) MarshalTo(dAtA []byte) (int, error)
- func (m *MsgActivate) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*MsgActivate) ProtoMessage()
- func (m *MsgActivate) Reset()
- func (msg MsgActivate) Route() string
- func (m *MsgActivate) Size() (n int)
- func (m *MsgActivate) String() string
- func (msg MsgActivate) Type() string
- func (m *MsgActivate) Unmarshal(dAtA []byte) error
- func (msg MsgActivate) ValidateBasic() error
- func (m *MsgActivate) XXX_DiscardUnknown()
- func (m *MsgActivate) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *MsgActivate) XXX_Merge(src proto.Message)
- func (m *MsgActivate) XXX_Size() int
- func (m *MsgActivate) XXX_Unmarshal(b []byte) error
- type MsgAddReporter
- func (*MsgAddReporter) Descriptor() ([]byte, []int)
- func (this *MsgAddReporter) Equal(that interface{}) bool
- func (m *MsgAddReporter) GetReporter() github_com_cosmos_cosmos_sdk_types.AccAddress
- func (msg MsgAddReporter) GetSignBytes() []byte
- func (msg MsgAddReporter) GetSigners() []sdk.AccAddress
- func (m *MsgAddReporter) GetValidator() github_com_cosmos_cosmos_sdk_types.ValAddress
- func (m *MsgAddReporter) Marshal() (dAtA []byte, err error)
- func (m *MsgAddReporter) MarshalTo(dAtA []byte) (int, error)
- func (m *MsgAddReporter) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*MsgAddReporter) ProtoMessage()
- func (m *MsgAddReporter) Reset()
- func (msg MsgAddReporter) Route() string
- func (m *MsgAddReporter) Size() (n int)
- func (m *MsgAddReporter) String() string
- func (msg MsgAddReporter) Type() string
- func (m *MsgAddReporter) Unmarshal(dAtA []byte) error
- func (msg MsgAddReporter) ValidateBasic() error
- func (m *MsgAddReporter) XXX_DiscardUnknown()
- func (m *MsgAddReporter) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *MsgAddReporter) XXX_Merge(src proto.Message)
- func (m *MsgAddReporter) XXX_Size() int
- func (m *MsgAddReporter) XXX_Unmarshal(b []byte) error
- type MsgCreateDataSource
- func (*MsgCreateDataSource) Descriptor() ([]byte, []int)
- func (this *MsgCreateDataSource) Equal(that interface{}) bool
- func (m *MsgCreateDataSource) GetDescription() string
- func (m *MsgCreateDataSource) GetExecutable() []byte
- func (m *MsgCreateDataSource) GetName() string
- func (m *MsgCreateDataSource) GetOwner() github_com_cosmos_cosmos_sdk_types.AccAddress
- func (m *MsgCreateDataSource) GetSender() github_com_cosmos_cosmos_sdk_types.AccAddress
- func (msg MsgCreateDataSource) GetSignBytes() []byte
- func (msg MsgCreateDataSource) GetSigners() []sdk.AccAddress
- func (m *MsgCreateDataSource) Marshal() (dAtA []byte, err error)
- func (m *MsgCreateDataSource) MarshalTo(dAtA []byte) (int, error)
- func (m *MsgCreateDataSource) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*MsgCreateDataSource) ProtoMessage()
- func (m *MsgCreateDataSource) Reset()
- func (msg MsgCreateDataSource) Route() string
- func (m *MsgCreateDataSource) Size() (n int)
- func (m *MsgCreateDataSource) String() string
- func (msg MsgCreateDataSource) Type() string
- func (m *MsgCreateDataSource) Unmarshal(dAtA []byte) error
- func (msg MsgCreateDataSource) ValidateBasic() error
- func (m *MsgCreateDataSource) XXX_DiscardUnknown()
- func (m *MsgCreateDataSource) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *MsgCreateDataSource) XXX_Merge(src proto.Message)
- func (m *MsgCreateDataSource) XXX_Size() int
- func (m *MsgCreateDataSource) XXX_Unmarshal(b []byte) error
- type MsgCreateOracleScript
- func (*MsgCreateOracleScript) Descriptor() ([]byte, []int)
- func (this *MsgCreateOracleScript) Equal(that interface{}) bool
- func (m *MsgCreateOracleScript) GetCode() []byte
- func (m *MsgCreateOracleScript) GetDescription() string
- func (m *MsgCreateOracleScript) GetName() string
- func (m *MsgCreateOracleScript) GetOwner() github_com_cosmos_cosmos_sdk_types.AccAddress
- func (m *MsgCreateOracleScript) GetSchema() string
- func (m *MsgCreateOracleScript) GetSender() github_com_cosmos_cosmos_sdk_types.AccAddress
- func (msg MsgCreateOracleScript) GetSignBytes() []byte
- func (msg MsgCreateOracleScript) GetSigners() []sdk.AccAddress
- func (m *MsgCreateOracleScript) GetSourceCodeURL() string
- func (m *MsgCreateOracleScript) Marshal() (dAtA []byte, err error)
- func (m *MsgCreateOracleScript) MarshalTo(dAtA []byte) (int, error)
- func (m *MsgCreateOracleScript) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*MsgCreateOracleScript) ProtoMessage()
- func (m *MsgCreateOracleScript) Reset()
- func (msg MsgCreateOracleScript) Route() string
- func (m *MsgCreateOracleScript) Size() (n int)
- func (m *MsgCreateOracleScript) String() string
- func (msg MsgCreateOracleScript) Type() string
- func (m *MsgCreateOracleScript) Unmarshal(dAtA []byte) error
- func (msg MsgCreateOracleScript) ValidateBasic() error
- func (m *MsgCreateOracleScript) XXX_DiscardUnknown()
- func (m *MsgCreateOracleScript) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *MsgCreateOracleScript) XXX_Merge(src proto.Message)
- func (m *MsgCreateOracleScript) XXX_Size() int
- func (m *MsgCreateOracleScript) XXX_Unmarshal(b []byte) error
- type MsgEditDataSource
- func (*MsgEditDataSource) Descriptor() ([]byte, []int)
- func (this *MsgEditDataSource) Equal(that interface{}) bool
- func (m *MsgEditDataSource) GetDataSourceID() DataSourceID
- func (m *MsgEditDataSource) GetDescription() string
- func (m *MsgEditDataSource) GetExecutable() []byte
- func (m *MsgEditDataSource) GetName() string
- func (m *MsgEditDataSource) GetOwner() github_com_cosmos_cosmos_sdk_types.AccAddress
- func (m *MsgEditDataSource) GetSender() github_com_cosmos_cosmos_sdk_types.AccAddress
- func (msg MsgEditDataSource) GetSignBytes() []byte
- func (msg MsgEditDataSource) GetSigners() []sdk.AccAddress
- func (m *MsgEditDataSource) Marshal() (dAtA []byte, err error)
- func (m *MsgEditDataSource) MarshalTo(dAtA []byte) (int, error)
- func (m *MsgEditDataSource) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*MsgEditDataSource) ProtoMessage()
- func (m *MsgEditDataSource) Reset()
- func (msg MsgEditDataSource) Route() string
- func (m *MsgEditDataSource) Size() (n int)
- func (m *MsgEditDataSource) String() string
- func (msg MsgEditDataSource) Type() string
- func (m *MsgEditDataSource) Unmarshal(dAtA []byte) error
- func (msg MsgEditDataSource) ValidateBasic() error
- func (m *MsgEditDataSource) XXX_DiscardUnknown()
- func (m *MsgEditDataSource) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *MsgEditDataSource) XXX_Merge(src proto.Message)
- func (m *MsgEditDataSource) XXX_Size() int
- func (m *MsgEditDataSource) XXX_Unmarshal(b []byte) error
- type MsgEditOracleScript
- func (*MsgEditOracleScript) Descriptor() ([]byte, []int)
- func (this *MsgEditOracleScript) Equal(that interface{}) bool
- func (m *MsgEditOracleScript) GetCode() []byte
- func (m *MsgEditOracleScript) GetDescription() string
- func (m *MsgEditOracleScript) GetName() string
- func (m *MsgEditOracleScript) GetOracleScriptID() OracleScriptID
- func (m *MsgEditOracleScript) GetOwner() github_com_cosmos_cosmos_sdk_types.AccAddress
- func (m *MsgEditOracleScript) GetSchema() string
- func (m *MsgEditOracleScript) GetSender() github_com_cosmos_cosmos_sdk_types.AccAddress
- func (msg MsgEditOracleScript) GetSignBytes() []byte
- func (msg MsgEditOracleScript) GetSigners() []sdk.AccAddress
- func (m *MsgEditOracleScript) GetSourceCodeURL() string
- func (m *MsgEditOracleScript) Marshal() (dAtA []byte, err error)
- func (m *MsgEditOracleScript) MarshalTo(dAtA []byte) (int, error)
- func (m *MsgEditOracleScript) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*MsgEditOracleScript) ProtoMessage()
- func (m *MsgEditOracleScript) Reset()
- func (msg MsgEditOracleScript) Route() string
- func (m *MsgEditOracleScript) Size() (n int)
- func (m *MsgEditOracleScript) String() string
- func (msg MsgEditOracleScript) Type() string
- func (m *MsgEditOracleScript) Unmarshal(dAtA []byte) error
- func (msg MsgEditOracleScript) ValidateBasic() error
- func (m *MsgEditOracleScript) XXX_DiscardUnknown()
- func (m *MsgEditOracleScript) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *MsgEditOracleScript) XXX_Merge(src proto.Message)
- func (m *MsgEditOracleScript) XXX_Size() int
- func (m *MsgEditOracleScript) XXX_Unmarshal(b []byte) error
- type MsgRemoveReporter
- func (*MsgRemoveReporter) Descriptor() ([]byte, []int)
- func (this *MsgRemoveReporter) Equal(that interface{}) bool
- func (m *MsgRemoveReporter) GetReporter() github_com_cosmos_cosmos_sdk_types.AccAddress
- func (msg MsgRemoveReporter) GetSignBytes() []byte
- func (msg MsgRemoveReporter) GetSigners() []sdk.AccAddress
- func (m *MsgRemoveReporter) GetValidator() github_com_cosmos_cosmos_sdk_types.ValAddress
- func (m *MsgRemoveReporter) Marshal() (dAtA []byte, err error)
- func (m *MsgRemoveReporter) MarshalTo(dAtA []byte) (int, error)
- func (m *MsgRemoveReporter) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*MsgRemoveReporter) ProtoMessage()
- func (m *MsgRemoveReporter) Reset()
- func (msg MsgRemoveReporter) Route() string
- func (m *MsgRemoveReporter) Size() (n int)
- func (m *MsgRemoveReporter) String() string
- func (msg MsgRemoveReporter) Type() string
- func (m *MsgRemoveReporter) Unmarshal(dAtA []byte) error
- func (msg MsgRemoveReporter) ValidateBasic() error
- func (m *MsgRemoveReporter) XXX_DiscardUnknown()
- func (m *MsgRemoveReporter) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *MsgRemoveReporter) XXX_Merge(src proto.Message)
- func (m *MsgRemoveReporter) XXX_Size() int
- func (m *MsgRemoveReporter) XXX_Unmarshal(b []byte) error
- type MsgReportData
- func (*MsgReportData) Descriptor() ([]byte, []int)
- func (this *MsgReportData) Equal(that interface{}) bool
- func (m *MsgReportData) GetRawReports() []RawReport
- func (m *MsgReportData) GetReporter() github_com_cosmos_cosmos_sdk_types.AccAddress
- func (m *MsgReportData) GetRequestID() RequestID
- func (msg MsgReportData) GetSignBytes() []byte
- func (msg MsgReportData) GetSigners() []sdk.AccAddress
- func (m *MsgReportData) GetValidator() github_com_cosmos_cosmos_sdk_types.ValAddress
- func (m *MsgReportData) Marshal() (dAtA []byte, err error)
- func (m *MsgReportData) MarshalTo(dAtA []byte) (int, error)
- func (m *MsgReportData) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*MsgReportData) ProtoMessage()
- func (m *MsgReportData) Reset()
- func (msg MsgReportData) Route() string
- func (m *MsgReportData) Size() (n int)
- func (m *MsgReportData) String() string
- func (msg MsgReportData) Type() string
- func (m *MsgReportData) Unmarshal(dAtA []byte) error
- func (msg MsgReportData) ValidateBasic() error
- func (m *MsgReportData) XXX_DiscardUnknown()
- func (m *MsgReportData) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *MsgReportData) XXX_Merge(src proto.Message)
- func (m *MsgReportData) XXX_Size() int
- func (m *MsgReportData) XXX_Unmarshal(b []byte) error
- type MsgRequestData
- func (*MsgRequestData) Descriptor() ([]byte, []int)
- func (this *MsgRequestData) Equal(that interface{}) bool
- func (m *MsgRequestData) GetAskCount() uint64
- func (m *MsgRequestData) GetCalldata() []byte
- func (m *MsgRequestData) GetClientID() string
- func (m *MsgRequestData) GetMinCount() uint64
- func (m *MsgRequestData) GetOracleScriptID() OracleScriptID
- func (m *MsgRequestData) GetSender() github_com_cosmos_cosmos_sdk_types.AccAddress
- func (msg MsgRequestData) GetSignBytes() []byte
- func (msg MsgRequestData) GetSigners() []sdk.AccAddress
- func (m *MsgRequestData) Marshal() (dAtA []byte, err error)
- func (m *MsgRequestData) MarshalTo(dAtA []byte) (int, error)
- func (m *MsgRequestData) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*MsgRequestData) ProtoMessage()
- func (m *MsgRequestData) Reset()
- func (msg MsgRequestData) Route() string
- func (m *MsgRequestData) Size() (n int)
- func (m *MsgRequestData) String() string
- func (msg MsgRequestData) Type() string
- func (m *MsgRequestData) Unmarshal(dAtA []byte) error
- func (msg MsgRequestData) ValidateBasic() error
- func (m *MsgRequestData) XXX_DiscardUnknown()
- func (m *MsgRequestData) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *MsgRequestData) XXX_Merge(src proto.Message)
- func (m *MsgRequestData) XXX_Size() int
- func (m *MsgRequestData) XXX_Unmarshal(b []byte) error
- type OraclePool
- type OracleRequestPacketData
- func (*OracleRequestPacketData) Descriptor() ([]byte, []int)
- func (this *OracleRequestPacketData) Equal(that interface{}) bool
- func (m *OracleRequestPacketData) GetAskCount() uint64
- func (p OracleRequestPacketData) GetBytes() []byte
- func (m *OracleRequestPacketData) GetCalldata() []byte
- func (m *OracleRequestPacketData) GetClientID() string
- func (m *OracleRequestPacketData) GetMinCount() uint64
- func (m *OracleRequestPacketData) GetOracleScriptID() OracleScriptID
- func (m *OracleRequestPacketData) Marshal() (dAtA []byte, err error)
- func (m *OracleRequestPacketData) MarshalTo(dAtA []byte) (int, error)
- func (m *OracleRequestPacketData) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*OracleRequestPacketData) ProtoMessage()
- func (m *OracleRequestPacketData) Reset()
- func (m *OracleRequestPacketData) Size() (n int)
- func (m *OracleRequestPacketData) String() string
- func (m *OracleRequestPacketData) Unmarshal(dAtA []byte) error
- func (m *OracleRequestPacketData) XXX_DiscardUnknown()
- func (m *OracleRequestPacketData) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *OracleRequestPacketData) XXX_Merge(src proto.Message)
- func (m *OracleRequestPacketData) XXX_Size() int
- func (m *OracleRequestPacketData) XXX_Unmarshal(b []byte) error
- type OracleResponsePacketData
- func (*OracleResponsePacketData) Descriptor() ([]byte, []int)
- func (this *OracleResponsePacketData) Equal(that interface{}) bool
- func (m *OracleResponsePacketData) GetAnsCount() uint64
- func (p OracleResponsePacketData) GetBytes() []byte
- func (m *OracleResponsePacketData) GetClientID() string
- func (m *OracleResponsePacketData) GetRequestID() RequestID
- func (m *OracleResponsePacketData) GetRequestTime() int64
- func (m *OracleResponsePacketData) GetResolveStatus() ResolveStatus
- func (m *OracleResponsePacketData) GetResolveTime() int64
- func (m *OracleResponsePacketData) GetResult() []byte
- func (m *OracleResponsePacketData) Marshal() (dAtA []byte, err error)
- func (m *OracleResponsePacketData) MarshalTo(dAtA []byte) (int, error)
- func (m *OracleResponsePacketData) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*OracleResponsePacketData) ProtoMessage()
- func (m *OracleResponsePacketData) Reset()
- func (m *OracleResponsePacketData) Size() (n int)
- func (m *OracleResponsePacketData) String() string
- func (m *OracleResponsePacketData) Unmarshal(dAtA []byte) error
- func (m *OracleResponsePacketData) XXX_DiscardUnknown()
- func (m *OracleResponsePacketData) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *OracleResponsePacketData) XXX_Merge(src proto.Message)
- func (m *OracleResponsePacketData) XXX_Size() int
- func (m *OracleResponsePacketData) XXX_Unmarshal(b []byte) error
- type OracleScript
- func (*OracleScript) Descriptor() ([]byte, []int)
- func (this *OracleScript) Equal(that interface{}) bool
- func (m *OracleScript) GetDescription() string
- func (m *OracleScript) GetFilename() string
- func (m *OracleScript) GetName() string
- func (m *OracleScript) GetOwner() github_com_cosmos_cosmos_sdk_types.AccAddress
- func (m *OracleScript) GetSchema() string
- func (m *OracleScript) GetSourceCodeURL() string
- func (m *OracleScript) Marshal() (dAtA []byte, err error)
- func (m *OracleScript) MarshalTo(dAtA []byte) (int, error)
- func (m *OracleScript) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*OracleScript) ProtoMessage()
- func (m *OracleScript) Reset()
- func (m *OracleScript) Size() (n int)
- func (m *OracleScript) String() string
- func (m *OracleScript) Unmarshal(dAtA []byte) error
- func (m *OracleScript) XXX_DiscardUnknown()
- func (m *OracleScript) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *OracleScript) XXX_Merge(src proto.Message)
- func (m *OracleScript) XXX_Size() int
- func (m *OracleScript) XXX_Unmarshal(b []byte) error
- type OracleScriptID
- type Params
- func (*Params) Descriptor() ([]byte, []int)
- func (this *Params) Equal(that interface{}) bool
- func (m *Params) GetBaseRequestGas() uint64
- func (m *Params) GetExpirationBlockCount() uint64
- func (m *Params) GetInactivePenaltyDuration() uint64
- func (m *Params) GetMaxAskCount() uint64
- func (m *Params) GetMaxCalldataSize() uint64
- func (m *Params) GetMaxDataSize() uint64
- func (m *Params) GetMaxRawRequestCount() uint64
- func (m *Params) GetOracleRewardPercentage() uint64
- func (m *Params) GetPerValidatorRequestGas() uint64
- func (m *Params) GetSamplingTryCount() uint64
- 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() params.ParamSetPairs
- 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 (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 PrepareEnv
- type QueryActiveValidatorResult
- type QueryCountsResult
- type QueryRequestResult
- type RawReport
- func (*RawReport) Descriptor() ([]byte, []int)
- func (this *RawReport) Equal(that interface{}) bool
- func (m *RawReport) GetData() []byte
- func (m *RawReport) GetExitCode() uint32
- func (m *RawReport) GetExternalID() ExternalID
- func (m *RawReport) Marshal() (dAtA []byte, err error)
- func (m *RawReport) MarshalTo(dAtA []byte) (int, error)
- func (m *RawReport) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*RawReport) ProtoMessage()
- func (m *RawReport) Reset()
- func (m *RawReport) Size() (n int)
- func (m *RawReport) String() string
- func (m *RawReport) Unmarshal(dAtA []byte) error
- func (m *RawReport) XXX_DiscardUnknown()
- func (m *RawReport) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *RawReport) XXX_Merge(src proto.Message)
- func (m *RawReport) XXX_Size() int
- func (m *RawReport) XXX_Unmarshal(b []byte) error
- type RawRequest
- func (*RawRequest) Descriptor() ([]byte, []int)
- func (this *RawRequest) Equal(that interface{}) bool
- func (m *RawRequest) GetCalldata() []byte
- func (m *RawRequest) GetDataSourceID() DataSourceID
- func (m *RawRequest) GetExternalID() ExternalID
- func (m *RawRequest) Marshal() (dAtA []byte, err error)
- func (m *RawRequest) MarshalTo(dAtA []byte) (int, error)
- func (m *RawRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*RawRequest) ProtoMessage()
- func (m *RawRequest) Reset()
- func (m *RawRequest) Size() (n int)
- func (m *RawRequest) String() string
- func (m *RawRequest) Unmarshal(dAtA []byte) error
- func (m *RawRequest) XXX_DiscardUnknown()
- func (m *RawRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *RawRequest) XXX_Merge(src proto.Message)
- func (m *RawRequest) XXX_Size() int
- func (m *RawRequest) XXX_Unmarshal(b []byte) error
- type Report
- func (*Report) Descriptor() ([]byte, []int)
- func (this *Report) Equal(that interface{}) bool
- func (m *Report) GetInBeforeResolve() bool
- func (m *Report) GetRawReports() []RawReport
- func (m *Report) GetValidator() github_com_cosmos_cosmos_sdk_types.ValAddress
- func (m *Report) Marshal() (dAtA []byte, err error)
- func (m *Report) MarshalTo(dAtA []byte) (int, error)
- func (m *Report) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*Report) ProtoMessage()
- func (m *Report) Reset()
- func (m *Report) Size() (n int)
- func (m *Report) String() string
- func (m *Report) Unmarshal(dAtA []byte) error
- func (m *Report) XXX_DiscardUnknown()
- func (m *Report) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Report) XXX_Merge(src proto.Message)
- func (m *Report) XXX_Size() int
- func (m *Report) XXX_Unmarshal(b []byte) error
- type Request
- func (*Request) Descriptor() ([]byte, []int)
- func (this *Request) Equal(that interface{}) bool
- func (m *Request) GetCalldata() []byte
- func (m *Request) GetClientID() string
- func (m *Request) GetMinCount() uint64
- func (m *Request) GetOracleScriptID() OracleScriptID
- func (m *Request) GetRawRequests() []RawRequest
- func (m *Request) GetRequestHeight() int64
- func (m *Request) GetRequestTime() time.Time
- func (m *Request) GetRequestedValidators() []github_com_cosmos_cosmos_sdk_types.ValAddress
- func (m *Request) Marshal() (dAtA []byte, err error)
- func (m *Request) MarshalTo(dAtA []byte) (int, error)
- func (m *Request) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*Request) ProtoMessage()
- func (m *Request) Reset()
- func (m *Request) Size() (n int)
- func (m *Request) String() string
- func (m *Request) Unmarshal(dAtA []byte) error
- func (m *Request) XXX_DiscardUnknown()
- func (m *Request) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Request) XXX_Merge(src proto.Message)
- func (m *Request) XXX_Size() int
- func (m *Request) XXX_Unmarshal(b []byte) error
- type RequestID
- type RequestSpec
- type RequestWithSenderSpec
- type ResolveStatus
- type Result
- type StakingKeeper
- type SupplyKeeper
- type ValidatorStatus
- func (*ValidatorStatus) Descriptor() ([]byte, []int)
- func (this *ValidatorStatus) Equal(that interface{}) bool
- func (m *ValidatorStatus) GetIsActive() bool
- func (m *ValidatorStatus) GetSince() time.Time
- func (m *ValidatorStatus) Marshal() (dAtA []byte, err error)
- func (m *ValidatorStatus) MarshalTo(dAtA []byte) (int, error)
- func (m *ValidatorStatus) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*ValidatorStatus) ProtoMessage()
- func (m *ValidatorStatus) Reset()
- func (m *ValidatorStatus) Size() (n int)
- func (m *ValidatorStatus) String() string
- func (m *ValidatorStatus) Unmarshal(dAtA []byte) error
- func (m *ValidatorStatus) XXX_DiscardUnknown()
- func (m *ValidatorStatus) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *ValidatorStatus) XXX_Merge(src proto.Message)
- func (m *ValidatorStatus) XXX_Size() int
- func (m *ValidatorStatus) XXX_Unmarshal(b []byte) error
Constants ¶
const ( DoNotModify = "[do-not-modify]" MaxNameLength = 128 MaxDescriptionLength = 4096 MaxClientIDLength = 128 MaxSchemaLength = 512 MaxURLLength = 128 MaxExecutableSize = 8 * 1024 // 8kB MaxWasmCodeSize = 512 * 1024 // 512kB MaxCompiledWasmCodeSize = 1 * 1024 * 1024 // 1MB // DEPRECATED MaxDataSize = 1 * 1024 // 1KB WasmPrepareGas = 1000000 WasmExecuteGas = 5000000 )
nolint todo make some params configurable todo setup appropriate values
const ( EventTypeCreateDataSource = "create_data_source" EventTypeEditDataSource = "edit_data_source" EventTypeCreateOracleScript = "create_oracle_script" EventTypeEditOracleScript = "edit_oracle_script" EventTypeRequest = "request" EventTypeRawRequest = "raw_request" EventTypeReport = "report" EventTypeActivate = "activate" EventTypeDeactivate = "deactivate" EventTypeAddReporter = "add_reporter" EventTypeRemoveReporter = "remove_reporter" EventTypeResolve = "resolve" AttributeKeyID = "id" AttributeKeyDataSourceID = "data_source_id" AttributeKeyOracleScriptID = "oracle_script_id" AttributeKeyExternalID = "external_id" AttributeKeyDataSourceHash = "data_source_hash" AttributeKeyCalldata = "calldata" AttributeKeyValidator = "validator" AttributeKeyReporter = "reporter" AttributeKeyClientID = "client_id" AttributeKeyAskCount = "ask_count" AttributeKeyMinCount = "min_count" AttributeKeyResolveStatus = "resolve_status" AttributeKeyGasUsed = "gas_used" AttributeKeyResult = "result" AttributeKeyReason = "reason" )
nolint
const ( // ModuleName is the name of the module. ModuleName = "oracle" // StoreKey to be used when creating the KVStore. StoreKey = ModuleName // Default PortID that oracle module binds to. PortID = ModuleName )
const ( // DefaultParamspace is the parameter namespace key for this module - "oracle" DefaultParamspace = ModuleName // Each value below is the default value for each parameter when generating the default // genesis file. See comments in types.proto for explanation for each parameter. DefaultMaxRawRequestCount = uint64(12) DefaultMaxAskCount = uint64(16) DefaultExpirationBlockCount = uint64(100) DefaultBaseRequestGas = uint64(150000) DefaultPerValidatorRequestGas = uint64(30000) DefaultSamplingTryCount = uint64(3) DefaultOracleRewardPercentage = uint64(70) DefaultInactivePenaltyDuration = uint64(10 * time.Minute) DefaultMaxDataSize = uint64(1 * 1024) // 1 KB DefaultMaxCalldataSize = uint64(1 * 1024) // 1 KB DefaultDataProviderRewardDenom = "geo" DefaultDataRequesterBasicFeeDenom = "odin" )
nolint
const ( QueryParams = "params" QueryCounts = "counts" QueryData = "data" QueryDataSources = "data_sources" QueryOracleScripts = "oracle_scripts" QueryRequests = "requests" QueryValidatorStatus = "validator_status" QueryReporters = "reporters" QueryActiveValidators = "active_validators" QueryPendingRequests = "pending_requests" QueryDataProvidersPool = "data_providers_pool" )
Query endpoints supported by the oracle Querier.
const RouterKey = ModuleName
RouterKey is the name of the oracle module
Variables ¶
var ( ErrOwasmCompilation = sdkerrors.Register(ModuleName, 1, "owasm compilation failed") ErrBadWasmExecution = sdkerrors.Register(ModuleName, 2, "bad wasm execution") ErrDataSourceNotFound = sdkerrors.Register(ModuleName, 3, "data source not found") ErrOracleScriptNotFound = sdkerrors.Register(ModuleName, 4, "oracle script not found") ErrRequestNotFound = sdkerrors.Register(ModuleName, 5, "request not found") ErrRawRequestNotFound = sdkerrors.Register(ModuleName, 6, "raw request not found") ErrReporterNotFound = sdkerrors.Register(ModuleName, 7, "reporter not found") ErrResultNotFound = sdkerrors.Register(ModuleName, 8, "result not found") ErrReporterAlreadyExists = sdkerrors.Register(ModuleName, 9, "reporter already exists") ErrValidatorNotRequested = sdkerrors.Register(ModuleName, 10, "validator not requested") ErrValidatorAlreadyReported = sdkerrors.Register(ModuleName, 11, "validator already reported") ErrInvalidReportSize = sdkerrors.Register(ModuleName, 12, "invalid report size") ErrReporterNotAuthorized = sdkerrors.Register(ModuleName, 13, "reporter not authorized") ErrEditorNotAuthorized = sdkerrors.Register(ModuleName, 14, "editor not authorized") ErrValidatorAlreadyActive = sdkerrors.Register(ModuleName, 16, "validator already active") ErrTooSoonToActivate = sdkerrors.Register(ModuleName, 17, "too soon to activate") ErrTooLongName = sdkerrors.Register(ModuleName, 18, "too long name") ErrTooLongDescription = sdkerrors.Register(ModuleName, 19, "too long description") ErrEmptyExecutable = sdkerrors.Register(ModuleName, 20, "empty executable") ErrEmptyWasmCode = sdkerrors.Register(ModuleName, 21, "empty wasm code") ErrTooLargeExecutable = sdkerrors.Register(ModuleName, 22, "too large executable") ErrTooLargeWasmCode = sdkerrors.Register(ModuleName, 23, "too large wasm code") ErrInvalidMinCount = sdkerrors.Register(ModuleName, 24, "invalid min count") ErrInvalidAskCount = sdkerrors.Register(ModuleName, 25, "invalid ask count") ErrTooLargeCalldata = sdkerrors.Register(ModuleName, 26, "too large calldata") ErrTooLongClientID = sdkerrors.Register(ModuleName, 27, "too long client id") ErrEmptyRawRequests = sdkerrors.Register(ModuleName, 28, "empty raw requests") ErrEmptyReport = sdkerrors.Register(ModuleName, 29, "empty report") ErrDuplicateExternalID = sdkerrors.Register(ModuleName, 30, "duplicate external id") ErrTooLongSchema = sdkerrors.Register(ModuleName, 31, "too long schema") ErrTooLongURL = sdkerrors.Register(ModuleName, 32, "too long url") ErrTooLargeRawReportData = sdkerrors.Register(ModuleName, 33, "too large raw report data") ErrInsufficientValidators = sdkerrors.Register(ModuleName, 34, "insufficent available validators") ErrCreateWithDoNotModify = sdkerrors.Register(ModuleName, 35, "cannot create with [do-not-modify] content") ErrSelfReferenceAsReporter = sdkerrors.Register(ModuleName, 36, "cannot reference self as reporter") ErrOBIDecode = sdkerrors.Register(ModuleName, 37, "obi decode failed") ErrUncompressionFailed = sdkerrors.Register(ModuleName, 38, "uncompression failed") ErrRequestAlreadyExpired = sdkerrors.Register(ModuleName, 39, "request already expired") ErrBadDrbgInitialization = sdkerrors.Register(ModuleName, 40, "bad drbg initialization") )
var ( // RollingSeedSizeInBytes is the size of rolling block hash for random seed. RollingSeedSizeInBytes = 32 // GlobalStoreKeyPrefix is the prefix for global primitive state variables. GlobalStoreKeyPrefix = []byte{0x00} // RollingSeedStoreKey is the key that keeps the seed based on the first 8-bit of the most recent 32 block hashes. RollingSeedStoreKey = append(GlobalStoreKeyPrefix, []byte("RollingSeed")...) // RequestCountStoreKey is the key that keeps the total request count. RequestCountStoreKey = append(GlobalStoreKeyPrefix, []byte("RequestCount")...) // RequestLastExpiredStoreKey is the key that keeps the ID of the last expired request, or 0 if none. RequestLastExpiredStoreKey = append(GlobalStoreKeyPrefix, []byte("RequestLastExpired")...) // PendingResolveListStoreKey is the key that keeps the list of pending-resolve requests. PendingResolveListStoreKey = append(GlobalStoreKeyPrefix, []byte("PendingList")...) // DataSourceCountStoreKey is the key that keeps the total data source count. DataSourceCountStoreKey = append(GlobalStoreKeyPrefix, []byte("DataSourceCount")...) // OracleScriptCountStoreKey is the key that keeps the total oracle scripts count. OracleScriptCountStoreKey = append(GlobalStoreKeyPrefix, []byte("OracleScriptCount")...) // OraclePoolStoreKey is the key that keeps the oracle pool OraclePoolStoreKey = append(GlobalStoreKeyPrefix, []byte("OraclePool")...) // key for global oracle pool state // RequestStoreKeyPrefix is the prefix for request store. RequestStoreKeyPrefix = []byte{0x01} // ReportStoreKeyPrefix is the prefix for report store. ReportStoreKeyPrefix = []byte{0x02} // DataSourceStoreKeyPrefix is the prefix for data source store. DataSourceStoreKeyPrefix = []byte{0x03} // OracleScriptStoreKeyPrefix is the prefix for oracle script store. OracleScriptStoreKeyPrefix = []byte{0x04} // ReporterStoreKeyPrefix is the prefix for reporter store. ReporterStoreKeyPrefix = []byte{0x05} // ValidatorStatusKeyPrefix is the prefix for validator status store. ValidatorStatusKeyPrefix = []byte{0x06} // DataProviderRewardsKeyPrefix is the prefix for the data provider address with reward DataProviderRewardsKeyPrefix = []byte{0x07} // DataRequesterFeesKeyPrefix is the prefix for the data requester address with accumulated fee DataRequesterFeesKeyPrefix = []byte{0x08} // ResultStoreKeyPrefix is the prefix for request result store. ResultStoreKeyPrefix = []byte{0xff} )
var ( DefaultDataProviderRewardPerByte = NewCoinDecProto(DefaultDataProviderRewardDenom) DefaultDataRequesterBasicFee = NewCoinProto(DefaultDataRequesterBasicFeeDenom) )
var ( // Each value below is the key to store the respective oracle module parameter. See comments // in types.proto for explanation for each parameter. KeyMaxRawRequestCount = []byte("MaxRawRequestCount") KeyMaxAskCount = []byte("MaxAskCount") KeyExpirationBlockCount = []byte("ExpirationBlockCount") KeyBaseRequestGas = []byte("BaseRequestGas") KeyPerValidatorRequestGas = []byte("PerValidatorRequestGas") KeySamplingTryCount = []byte("SamplingTryCount") KeyOracleRewardPercentage = []byte("OracleRewardPercentage") KeyInactivePenaltyDuration = []byte("InactivePenaltyDuration") KeyMaxDataSize = []byte("MaxDataSize") KeyMaxCalldataSize = []byte("MaxCalldataSize") KeyDataProviderRewardPerByte = []byte("DataProviderRewardPerByte") KeyDataRequesterBasicFee = []byte("DataRequesterBasicFee") )
nolint
var ( ErrInvalidLengthTypes = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowTypes = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupTypes = fmt.Errorf("proto: unexpected end of group") )
var (
DoNotModifyBytes = []byte(DoNotModify)
)
nolint
var ModuleCdc = codec.New()
ModuleCdc is the codec for the module.
var ResolveStatus_name = map[int32]string{
0: "Open",
1: "Success",
2: "Failure",
3: "Expired",
}
var ResolveStatus_value = map[string]int32{
"Open": 0,
"Success": 1,
"Failure": 2,
"Expired": 3,
}
Functions ¶
func DataProviderRewardsPrefixKey ¶
func DataProviderRewardsPrefixKey(acc sdk.AccAddress) []byte
func DataRequesterFeePrefixKey ¶
func DataRequesterFeePrefixKey(acc sdk.AccAddress) []byte
func DataSourceStoreKey ¶
func DataSourceStoreKey(dataSourceID DataSourceID) []byte
DataSourceStoreKey returns the key to retrieve a specific data source from the store.
func OracleScriptStoreKey ¶
func OracleScriptStoreKey(oracleScriptID OracleScriptID) []byte
DataSourceStoreKey returns the key to retrieve a specific oracle script from the store.
func RegisterCodec ¶
RegisterCodec registers the module's concrete types on the codec.
func ReportStoreKey ¶
ReportStoreKey returns the key to retrieve all data reports for a request.
func ReporterStoreKey ¶
func ReporterStoreKey(validatorAddress sdk.ValAddress, reporterAddress sdk.AccAddress) []byte
ReporterStoreKey returns the key to check whether an address is a reporter of a validator.
func ReportersOfValidatorPrefixKey ¶
func ReportersOfValidatorPrefixKey(val sdk.ValAddress) []byte
ReportersOfValidatorPrefixKey returns the prefix key to get all reporters of a validator.
func ReportsOfValidatorPrefixKey ¶
func ReportsOfValidatorPrefixKey(reqID RequestID, val sdk.ValAddress) []byte
ReportsOfValidatorPrefixKey returns the prefix key to get all reports for a request from a validator.
func RequestStoreKey ¶
RequestStoreKey returns the key to retrieve a specfic request from the store.
func ResultStoreKey ¶
ResultStoreKey returns the key to a request result in the store.
func ValidatorStatusStoreKey ¶
func ValidatorStatusStoreKey(v sdk.ValAddress) []byte
ValidatorStatusStoreKey returns the key to a validator's status.
Types ¶
type AccountKeeper ¶
type AccountKeeper interface {
GetAccount(ctx sdk.Context, addr sdk.AccAddress) authexported.Account
}
AccountKeeper defines the expected account keeper.
type BaseEnv ¶
type BaseEnv struct {
// contains filtered or unexported fields
}
BaseEnv combines shared functions used in prepare and execution Owasm program,
func (*BaseEnv) AskExternalData ¶
AskExternalData implements Owasm ExecEnv interface.
func (*BaseEnv) GetAnsCount ¶
GetAnsCount implements Owasm ExecEnv interface.
func (*BaseEnv) GetAskCount ¶
GetAskCount implements Owasm ExecEnv interface.
func (*BaseEnv) GetCalldata ¶
GetCalldata implements Owasm ExecEnv interface.
func (*BaseEnv) GetExternalData ¶
GetExternalData implements Owasm ExecEnv interface.
func (*BaseEnv) GetExternalDataStatus ¶
GetExternalDataStatus implements Owasm ExecEnv interface.
func (*BaseEnv) GetMinCount ¶
GetMinCount implements Owasm ExecEnv interface.
func (*BaseEnv) SetReturnData ¶
SetReturnData implements Owasm ExecEnv interface.
type CoinDecProto ¶
func NewCoinDecProto ¶
func NewCoinDecProto(denom types.Denom) CoinDecProto
func (CoinDecProto) Equal ¶
func (p CoinDecProto) Equal(other CoinDecProto) bool
func (CoinDecProto) Size ¶
func (p CoinDecProto) Size() int
func (CoinDecProto) Unmarshal ¶
func (p CoinDecProto) Unmarshal(src []byte) error
func (CoinDecProto) Value ¶
func (p CoinDecProto) Value() sdk.DecCoin
type CoinProto ¶
func NewCoinProto ¶
type DataSource ¶
type DataSource struct { Owner github_com_cosmos_cosmos_sdk_types.AccAddress `protobuf:"bytes,1,opt,name=owner,proto3,casttype=github.com/cosmos/cosmos-sdk/types.AccAddress" json:"owner,omitempty"` Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"` Description string `protobuf:"bytes,3,opt,name=description,proto3" json:"description,omitempty"` Filename string `protobuf:"bytes,4,opt,name=filename,proto3" json:"filename,omitempty"` }
DataSource is the data structure for storing data sources in the storage.
func NewDataSource ¶
func NewDataSource( Owner github_com_cosmos_cosmos_sdk_types.AccAddress, Name string, Description string, Filename string, ) DataSource
func (*DataSource) Descriptor ¶
func (*DataSource) Descriptor() ([]byte, []int)
func (*DataSource) Equal ¶
func (this *DataSource) Equal(that interface{}) bool
func (*DataSource) GetDescription ¶
func (m *DataSource) GetDescription() string
func (*DataSource) GetFilename ¶
func (m *DataSource) GetFilename() string
func (*DataSource) GetName ¶
func (m *DataSource) GetName() string
func (*DataSource) GetOwner ¶
func (m *DataSource) GetOwner() github_com_cosmos_cosmos_sdk_types.AccAddress
func (*DataSource) Marshal ¶
func (m *DataSource) Marshal() (dAtA []byte, err error)
func (*DataSource) MarshalToSizedBuffer ¶
func (m *DataSource) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*DataSource) ProtoMessage ¶
func (*DataSource) ProtoMessage()
func (*DataSource) Reset ¶
func (m *DataSource) Reset()
func (*DataSource) Size ¶
func (m *DataSource) Size() (n int)
func (*DataSource) String ¶
func (m *DataSource) String() string
func (*DataSource) Unmarshal ¶
func (m *DataSource) Unmarshal(dAtA []byte) error
func (*DataSource) XXX_DiscardUnknown ¶
func (m *DataSource) XXX_DiscardUnknown()
func (*DataSource) XXX_Marshal ¶
func (m *DataSource) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*DataSource) XXX_Merge ¶
func (m *DataSource) XXX_Merge(src proto.Message)
func (*DataSource) XXX_Size ¶
func (m *DataSource) XXX_Size() int
func (*DataSource) XXX_Unmarshal ¶
func (m *DataSource) XXX_Unmarshal(b []byte) error
type DataSourceID ¶
type DataSourceID int64
DataSourceID is the type-safe unique identifier type for data sources.
type DistrKeeper ¶
type DistrKeeper interface { GetCommunityTax(ctx sdk.Context) (percent sdk.Dec) GetFeePool(ctx sdk.Context) (feePool distr.FeePool) SetFeePool(ctx sdk.Context, feePool distr.FeePool) AllocateTokensToValidator(ctx sdk.Context, val stakingexported.ValidatorI, tokens sdk.DecCoins) }
DistrKeeper defines the expected distribution keeper.
type ExecuteEnv ¶
ExecuteEnv implements ExecEnv interface only expected function and panic on prepare related functions.
func NewExecuteEnv ¶
func NewExecuteEnv(req Request, reports []Report) *ExecuteEnv
NewExecuteEnv creates a new environment instance for execution period.
func (*ExecuteEnv) GetAnsCount ¶
func (env *ExecuteEnv) GetAnsCount() (int64, error)
GetAnsCount implements Owasm ExecEnv interface.
func (*ExecuteEnv) GetExternalData ¶
func (env *ExecuteEnv) GetExternalData(eid int64, vid int64) ([]byte, error)
GetExternalData implements Owasm ExecEnv interface.
func (*ExecuteEnv) GetExternalDataStatus ¶
func (env *ExecuteEnv) GetExternalDataStatus(eid int64, vid int64) (int64, error)
GetExternalDataStatus implements Owasm ExecEnv interface.
func (*ExecuteEnv) SetReturnData ¶
func (env *ExecuteEnv) SetReturnData(data []byte) error
SetReturnData implements Owasm ExecEnv interface.
type ExternalID ¶
type ExternalID int64
ExternalID is the type-safe unique identifier type for raw data requests.
type MsgActivate ¶
type MsgActivate struct { // Validator is the signer of this message and the validator to be activated. Validator github_com_cosmos_cosmos_sdk_types.ValAddress `` /* 126-byte string literal not displayed */ }
MsgEditOracleScript is a message for activating a validator to become an oracle provider.
func NewMsgActivate ¶
func NewMsgActivate( Validator github_com_cosmos_cosmos_sdk_types.ValAddress, ) MsgActivate
func (*MsgActivate) Descriptor ¶
func (*MsgActivate) Descriptor() ([]byte, []int)
func (*MsgActivate) Equal ¶
func (this *MsgActivate) Equal(that interface{}) bool
func (MsgActivate) GetSignBytes ¶
func (msg MsgActivate) GetSignBytes() []byte
GetSignBytes returns raw JSON bytes to be signed by the signers (sdk.Msg interface).
func (MsgActivate) GetSigners ¶
func (msg MsgActivate) GetSigners() []sdk.AccAddress
GetSigners returns the required signers for the given MsgActivate (sdk.Msg interface).
func (*MsgActivate) GetValidator ¶
func (m *MsgActivate) GetValidator() github_com_cosmos_cosmos_sdk_types.ValAddress
func (*MsgActivate) Marshal ¶
func (m *MsgActivate) Marshal() (dAtA []byte, err error)
func (*MsgActivate) MarshalToSizedBuffer ¶
func (m *MsgActivate) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*MsgActivate) ProtoMessage ¶
func (*MsgActivate) ProtoMessage()
func (*MsgActivate) Reset ¶
func (m *MsgActivate) Reset()
func (MsgActivate) Route ¶
func (msg MsgActivate) Route() string
Route returns the route of MsgActivate - "oracle" (sdk.Msg interface).
func (*MsgActivate) Size ¶
func (m *MsgActivate) Size() (n int)
func (*MsgActivate) String ¶
func (m *MsgActivate) String() string
func (MsgActivate) Type ¶
func (msg MsgActivate) Type() string
Type returns the message type of MsgActivate (sdk.Msg interface).
func (*MsgActivate) Unmarshal ¶
func (m *MsgActivate) Unmarshal(dAtA []byte) error
func (MsgActivate) ValidateBasic ¶
func (msg MsgActivate) ValidateBasic() error
ValidateBasic checks whether the given MsgActivate instance (sdk.Msg interface).
func (*MsgActivate) XXX_DiscardUnknown ¶
func (m *MsgActivate) XXX_DiscardUnknown()
func (*MsgActivate) XXX_Marshal ¶
func (m *MsgActivate) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*MsgActivate) XXX_Merge ¶
func (m *MsgActivate) XXX_Merge(src proto.Message)
func (*MsgActivate) XXX_Size ¶
func (m *MsgActivate) XXX_Size() int
func (*MsgActivate) XXX_Unmarshal ¶
func (m *MsgActivate) XXX_Unmarshal(b []byte) error
type MsgAddReporter ¶
type MsgAddReporter struct { // Validator is the validator that wishes to add a new reporter. This is the signer. Validator github_com_cosmos_cosmos_sdk_types.ValAddress `` /* 126-byte string literal not displayed */ // Reporter is the address to be added as a reporter to the validator. Reporter github_com_cosmos_cosmos_sdk_types.AccAddress `protobuf:"bytes,2,opt,name=reporter,proto3,casttype=github.com/cosmos/cosmos-sdk/types.AccAddress" json:"reporter,omitempty"` }
MsgAddReporter is a message for adding a new reporter for a validator.
func NewMsgAddReporter ¶
func NewMsgAddReporter( Validator github_com_cosmos_cosmos_sdk_types.ValAddress, Reporter github_com_cosmos_cosmos_sdk_types.AccAddress, ) MsgAddReporter
func (*MsgAddReporter) Descriptor ¶
func (*MsgAddReporter) Descriptor() ([]byte, []int)
func (*MsgAddReporter) Equal ¶
func (this *MsgAddReporter) Equal(that interface{}) bool
func (*MsgAddReporter) GetReporter ¶
func (m *MsgAddReporter) GetReporter() github_com_cosmos_cosmos_sdk_types.AccAddress
func (MsgAddReporter) GetSignBytes ¶
func (msg MsgAddReporter) GetSignBytes() []byte
GetSignBytes returns raw JSON bytes to be signed by the signers (sdk.Msg interface).
func (MsgAddReporter) GetSigners ¶
func (msg MsgAddReporter) GetSigners() []sdk.AccAddress
GetSigners returns the required signers for the given MsgAddReporter (sdk.Msg interface).
func (*MsgAddReporter) GetValidator ¶
func (m *MsgAddReporter) GetValidator() github_com_cosmos_cosmos_sdk_types.ValAddress
func (*MsgAddReporter) Marshal ¶
func (m *MsgAddReporter) Marshal() (dAtA []byte, err error)
func (*MsgAddReporter) MarshalToSizedBuffer ¶
func (m *MsgAddReporter) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*MsgAddReporter) ProtoMessage ¶
func (*MsgAddReporter) ProtoMessage()
func (*MsgAddReporter) Reset ¶
func (m *MsgAddReporter) Reset()
func (MsgAddReporter) Route ¶
func (msg MsgAddReporter) Route() string
Route returns the route of MsgAddReporter - "oracle" (sdk.Msg interface).
func (*MsgAddReporter) Size ¶
func (m *MsgAddReporter) Size() (n int)
func (*MsgAddReporter) String ¶
func (m *MsgAddReporter) String() string
func (MsgAddReporter) Type ¶
func (msg MsgAddReporter) Type() string
Type returns the message type of MsgAddReporter (sdk.Msg interface).
func (*MsgAddReporter) Unmarshal ¶
func (m *MsgAddReporter) Unmarshal(dAtA []byte) error
func (MsgAddReporter) ValidateBasic ¶
func (msg MsgAddReporter) ValidateBasic() error
ValidateBasic checks whether the given MsgAddReporter instance (sdk.Msg interface).
func (*MsgAddReporter) XXX_DiscardUnknown ¶
func (m *MsgAddReporter) XXX_DiscardUnknown()
func (*MsgAddReporter) XXX_Marshal ¶
func (m *MsgAddReporter) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*MsgAddReporter) XXX_Merge ¶
func (m *MsgAddReporter) XXX_Merge(src proto.Message)
func (*MsgAddReporter) XXX_Size ¶
func (m *MsgAddReporter) XXX_Size() int
func (*MsgAddReporter) XXX_Unmarshal ¶
func (m *MsgAddReporter) XXX_Unmarshal(b []byte) error
type MsgCreateDataSource ¶
type MsgCreateDataSource struct { // Owner is the address who is allowed to make further changes to the data source. Owner github_com_cosmos_cosmos_sdk_types.AccAddress `protobuf:"bytes,1,opt,name=owner,proto3,casttype=github.com/cosmos/cosmos-sdk/types.AccAddress" json:"owner,omitempty"` // Name is the name of this data source (optional). Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"` // Description is the description of this data source (optional). Description string `protobuf:"bytes,3,opt,name=description,proto3" json:"description,omitempty"` // Executable is the executable script or binary to be run by validators upon execution. Executable []byte `protobuf:"bytes,4,opt,name=executable,proto3" json:"executable,omitempty"` // Sender is the signer of this message. Sender github_com_cosmos_cosmos_sdk_types.AccAddress `protobuf:"bytes,5,opt,name=sender,proto3,casttype=github.com/cosmos/cosmos-sdk/types.AccAddress" json:"sender,omitempty"` }
MsgCreateDataSource is a message for creating a new data source.
func NewMsgCreateDataSource ¶
func NewMsgCreateDataSource( Owner github_com_cosmos_cosmos_sdk_types.AccAddress, Name string, Description string, Executable []byte, Sender github_com_cosmos_cosmos_sdk_types.AccAddress, ) MsgCreateDataSource
func (*MsgCreateDataSource) Descriptor ¶
func (*MsgCreateDataSource) Descriptor() ([]byte, []int)
func (*MsgCreateDataSource) Equal ¶
func (this *MsgCreateDataSource) Equal(that interface{}) bool
func (*MsgCreateDataSource) GetDescription ¶
func (m *MsgCreateDataSource) GetDescription() string
func (*MsgCreateDataSource) GetExecutable ¶
func (m *MsgCreateDataSource) GetExecutable() []byte
func (*MsgCreateDataSource) GetName ¶
func (m *MsgCreateDataSource) GetName() string
func (*MsgCreateDataSource) GetOwner ¶
func (m *MsgCreateDataSource) GetOwner() github_com_cosmos_cosmos_sdk_types.AccAddress
func (*MsgCreateDataSource) GetSender ¶
func (m *MsgCreateDataSource) GetSender() github_com_cosmos_cosmos_sdk_types.AccAddress
func (MsgCreateDataSource) GetSignBytes ¶
func (msg MsgCreateDataSource) GetSignBytes() []byte
GetSignBytes returns raw JSON bytes to be signed by the signers (sdk.Msg interface).
func (MsgCreateDataSource) GetSigners ¶
func (msg MsgCreateDataSource) GetSigners() []sdk.AccAddress
GetSigners returns the required signers for the given MsgCreateDataSource (sdk.Msg interface).
func (*MsgCreateDataSource) Marshal ¶
func (m *MsgCreateDataSource) Marshal() (dAtA []byte, err error)
func (*MsgCreateDataSource) MarshalTo ¶
func (m *MsgCreateDataSource) MarshalTo(dAtA []byte) (int, error)
func (*MsgCreateDataSource) MarshalToSizedBuffer ¶
func (m *MsgCreateDataSource) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*MsgCreateDataSource) ProtoMessage ¶
func (*MsgCreateDataSource) ProtoMessage()
func (*MsgCreateDataSource) Reset ¶
func (m *MsgCreateDataSource) Reset()
func (MsgCreateDataSource) Route ¶
func (msg MsgCreateDataSource) Route() string
Route returns the route of MsgCreateDataSource - "oracle" (sdk.Msg interface).
func (*MsgCreateDataSource) Size ¶
func (m *MsgCreateDataSource) Size() (n int)
func (*MsgCreateDataSource) String ¶
func (m *MsgCreateDataSource) String() string
func (MsgCreateDataSource) Type ¶
func (msg MsgCreateDataSource) Type() string
Type returns the message type of MsgCreateDataSource (sdk.Msg interface).
func (*MsgCreateDataSource) Unmarshal ¶
func (m *MsgCreateDataSource) Unmarshal(dAtA []byte) error
func (MsgCreateDataSource) ValidateBasic ¶
func (msg MsgCreateDataSource) ValidateBasic() error
ValidateBasic checks whether the given MsgCreateDataSource instance (sdk.Msg interface).
func (*MsgCreateDataSource) XXX_DiscardUnknown ¶
func (m *MsgCreateDataSource) XXX_DiscardUnknown()
func (*MsgCreateDataSource) XXX_Marshal ¶
func (m *MsgCreateDataSource) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*MsgCreateDataSource) XXX_Merge ¶
func (m *MsgCreateDataSource) XXX_Merge(src proto.Message)
func (*MsgCreateDataSource) XXX_Size ¶
func (m *MsgCreateDataSource) XXX_Size() int
func (*MsgCreateDataSource) XXX_Unmarshal ¶
func (m *MsgCreateDataSource) XXX_Unmarshal(b []byte) error
type MsgCreateOracleScript ¶
type MsgCreateOracleScript struct { // Owner is the address who is allowed to make further changes to the oracle script. Owner github_com_cosmos_cosmos_sdk_types.AccAddress `protobuf:"bytes,1,opt,name=owner,proto3,casttype=github.com/cosmos/cosmos-sdk/types.AccAddress" json:"owner,omitempty"` // Name is the name of this oracle script (optional). Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"` // Description is the description of this oracle script (optional). Description string `protobuf:"bytes,3,opt,name=description,proto3" json:"description,omitempty"` // Code is the oracle WebAssembly binary code. Can be raw of gzip compressed. Code []byte `protobuf:"bytes,4,opt,name=code,proto3" json:"code,omitempty"` // Schema is the OBI schema of this oracle script (optional). Schema string `protobuf:"bytes,5,opt,name=schema,proto3" json:"schema,omitempty"` // SourceCodeURL is the absolute URI to the script's source code (optional). SourceCodeURL string `protobuf:"bytes,6,opt,name=source_code_url,json=sourceCodeUrl,proto3" json:"source_code_url,omitempty"` // Sender is the signer of this message. Sender github_com_cosmos_cosmos_sdk_types.AccAddress `protobuf:"bytes,7,opt,name=sender,proto3,casttype=github.com/cosmos/cosmos-sdk/types.AccAddress" json:"sender,omitempty"` }
MsgCreateOracleScript is a message for creating an oracle script.
func NewMsgCreateOracleScript ¶
func NewMsgCreateOracleScript( Owner github_com_cosmos_cosmos_sdk_types.AccAddress, Name string, Description string, Code []byte, Schema string, SourceCodeURL string, Sender github_com_cosmos_cosmos_sdk_types.AccAddress, ) MsgCreateOracleScript
func (*MsgCreateOracleScript) Descriptor ¶
func (*MsgCreateOracleScript) Descriptor() ([]byte, []int)
func (*MsgCreateOracleScript) Equal ¶
func (this *MsgCreateOracleScript) Equal(that interface{}) bool
func (*MsgCreateOracleScript) GetCode ¶
func (m *MsgCreateOracleScript) GetCode() []byte
func (*MsgCreateOracleScript) GetDescription ¶
func (m *MsgCreateOracleScript) GetDescription() string
func (*MsgCreateOracleScript) GetName ¶
func (m *MsgCreateOracleScript) GetName() string
func (*MsgCreateOracleScript) GetOwner ¶
func (m *MsgCreateOracleScript) GetOwner() github_com_cosmos_cosmos_sdk_types.AccAddress
func (*MsgCreateOracleScript) GetSchema ¶
func (m *MsgCreateOracleScript) GetSchema() string
func (*MsgCreateOracleScript) GetSender ¶
func (m *MsgCreateOracleScript) GetSender() github_com_cosmos_cosmos_sdk_types.AccAddress
func (MsgCreateOracleScript) GetSignBytes ¶
func (msg MsgCreateOracleScript) GetSignBytes() []byte
GetSignBytes returns raw JSON bytes to be signed by the signers (sdk.Msg interface).
func (MsgCreateOracleScript) GetSigners ¶
func (msg MsgCreateOracleScript) GetSigners() []sdk.AccAddress
GetSigners returns the required signers for the given MsgCreateOracleScript (sdk.Msg interface).
func (*MsgCreateOracleScript) GetSourceCodeURL ¶
func (m *MsgCreateOracleScript) GetSourceCodeURL() string
func (*MsgCreateOracleScript) Marshal ¶
func (m *MsgCreateOracleScript) Marshal() (dAtA []byte, err error)
func (*MsgCreateOracleScript) MarshalTo ¶
func (m *MsgCreateOracleScript) MarshalTo(dAtA []byte) (int, error)
func (*MsgCreateOracleScript) MarshalToSizedBuffer ¶
func (m *MsgCreateOracleScript) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*MsgCreateOracleScript) ProtoMessage ¶
func (*MsgCreateOracleScript) ProtoMessage()
func (*MsgCreateOracleScript) Reset ¶
func (m *MsgCreateOracleScript) Reset()
func (MsgCreateOracleScript) Route ¶
func (msg MsgCreateOracleScript) Route() string
Route returns the route of MsgCreateOracleScript - "oracle" (sdk.Msg interface).
func (*MsgCreateOracleScript) Size ¶
func (m *MsgCreateOracleScript) Size() (n int)
func (*MsgCreateOracleScript) String ¶
func (m *MsgCreateOracleScript) String() string
func (MsgCreateOracleScript) Type ¶
func (msg MsgCreateOracleScript) Type() string
Type returns the message type of MsgCreateOracleScript (sdk.Msg interface).
func (*MsgCreateOracleScript) Unmarshal ¶
func (m *MsgCreateOracleScript) Unmarshal(dAtA []byte) error
func (MsgCreateOracleScript) ValidateBasic ¶
func (msg MsgCreateOracleScript) ValidateBasic() error
ValidateBasic checks whether the given MsgCreateOracleScript instance (sdk.Msg interface).
func (*MsgCreateOracleScript) XXX_DiscardUnknown ¶
func (m *MsgCreateOracleScript) XXX_DiscardUnknown()
func (*MsgCreateOracleScript) XXX_Marshal ¶
func (m *MsgCreateOracleScript) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*MsgCreateOracleScript) XXX_Merge ¶
func (m *MsgCreateOracleScript) XXX_Merge(src proto.Message)
func (*MsgCreateOracleScript) XXX_Size ¶
func (m *MsgCreateOracleScript) XXX_Size() int
func (*MsgCreateOracleScript) XXX_Unmarshal ¶
func (m *MsgCreateOracleScript) XXX_Unmarshal(b []byte) error
type MsgEditDataSource ¶
type MsgEditDataSource struct { // DataSourceID is the unique identifier of the data source to be edited. DataSourceID DataSourceID `protobuf:"varint,1,opt,name=data_source_id,json=dataSourceId,proto3,casttype=DataSourceID" json:"data_source_id,omitempty"` // Owner is the new address who is allowed to make further changes to the data source. Owner github_com_cosmos_cosmos_sdk_types.AccAddress `protobuf:"bytes,2,opt,name=owner,proto3,casttype=github.com/cosmos/cosmos-sdk/types.AccAddress" json:"owner,omitempty"` // Name is the name of this data source (optional). Name string `protobuf:"bytes,3,opt,name=name,proto3" json:"name,omitempty"` // Description is the description of this data source (optional). Description string `protobuf:"bytes,4,opt,name=description,proto3" json:"description,omitempty"` // Executable is the executable script or binary to be run by validators upon execution. Executable []byte `protobuf:"bytes,5,opt,name=executable,proto3" json:"executable,omitempty"` // Sender is the signer of this message. Must be the current data source's owner. Sender github_com_cosmos_cosmos_sdk_types.AccAddress `protobuf:"bytes,6,opt,name=sender,proto3,casttype=github.com/cosmos/cosmos-sdk/types.AccAddress" json:"sender,omitempty"` }
MsgEditDataSource is a message for editing an existing data source.
func NewMsgEditDataSource ¶
func NewMsgEditDataSource( DataSourceID DataSourceID, Owner github_com_cosmos_cosmos_sdk_types.AccAddress, Name string, Description string, Executable []byte, Sender github_com_cosmos_cosmos_sdk_types.AccAddress, ) MsgEditDataSource
func (*MsgEditDataSource) Descriptor ¶
func (*MsgEditDataSource) Descriptor() ([]byte, []int)
func (*MsgEditDataSource) Equal ¶
func (this *MsgEditDataSource) Equal(that interface{}) bool
func (*MsgEditDataSource) GetDataSourceID ¶
func (m *MsgEditDataSource) GetDataSourceID() DataSourceID
func (*MsgEditDataSource) GetDescription ¶
func (m *MsgEditDataSource) GetDescription() string
func (*MsgEditDataSource) GetExecutable ¶
func (m *MsgEditDataSource) GetExecutable() []byte
func (*MsgEditDataSource) GetName ¶
func (m *MsgEditDataSource) GetName() string
func (*MsgEditDataSource) GetOwner ¶
func (m *MsgEditDataSource) GetOwner() github_com_cosmos_cosmos_sdk_types.AccAddress
func (*MsgEditDataSource) GetSender ¶
func (m *MsgEditDataSource) GetSender() github_com_cosmos_cosmos_sdk_types.AccAddress
func (MsgEditDataSource) GetSignBytes ¶
func (msg MsgEditDataSource) GetSignBytes() []byte
GetSignBytes returns raw JSON bytes to be signed by the signers (sdk.Msg interface).
func (MsgEditDataSource) GetSigners ¶
func (msg MsgEditDataSource) GetSigners() []sdk.AccAddress
GetSigners returns the required signers for the given MsgEditDataSource (sdk.Msg interface).
func (*MsgEditDataSource) Marshal ¶
func (m *MsgEditDataSource) Marshal() (dAtA []byte, err error)
func (*MsgEditDataSource) MarshalTo ¶
func (m *MsgEditDataSource) MarshalTo(dAtA []byte) (int, error)
func (*MsgEditDataSource) MarshalToSizedBuffer ¶
func (m *MsgEditDataSource) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*MsgEditDataSource) ProtoMessage ¶
func (*MsgEditDataSource) ProtoMessage()
func (*MsgEditDataSource) Reset ¶
func (m *MsgEditDataSource) Reset()
func (MsgEditDataSource) Route ¶
func (msg MsgEditDataSource) Route() string
Route returns the route of MsgEditDataSource - "oracle" (sdk.Msg interface).
func (*MsgEditDataSource) Size ¶
func (m *MsgEditDataSource) Size() (n int)
func (*MsgEditDataSource) String ¶
func (m *MsgEditDataSource) String() string
func (MsgEditDataSource) Type ¶
func (msg MsgEditDataSource) Type() string
Type returns the message type of MsgEditDataSource (sdk.Msg interface).
func (*MsgEditDataSource) Unmarshal ¶
func (m *MsgEditDataSource) Unmarshal(dAtA []byte) error
func (MsgEditDataSource) ValidateBasic ¶
func (msg MsgEditDataSource) ValidateBasic() error
ValidateBasic checks whether the given MsgEditDataSource instance (sdk.Msg interface).
func (*MsgEditDataSource) XXX_DiscardUnknown ¶
func (m *MsgEditDataSource) XXX_DiscardUnknown()
func (*MsgEditDataSource) XXX_Marshal ¶
func (m *MsgEditDataSource) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*MsgEditDataSource) XXX_Merge ¶
func (m *MsgEditDataSource) XXX_Merge(src proto.Message)
func (*MsgEditDataSource) XXX_Size ¶
func (m *MsgEditDataSource) XXX_Size() int
func (*MsgEditDataSource) XXX_Unmarshal ¶
func (m *MsgEditDataSource) XXX_Unmarshal(b []byte) error
type MsgEditOracleScript ¶
type MsgEditOracleScript struct { // OracleScriptID is the unique identifier of the oracle script to be edited. OracleScriptID OracleScriptID `` /* 130-byte string literal not displayed */ // Owner is new the address who is allowed to make further changes to the oracle script. Owner github_com_cosmos_cosmos_sdk_types.AccAddress `protobuf:"bytes,2,opt,name=owner,proto3,casttype=github.com/cosmos/cosmos-sdk/types.AccAddress" json:"owner,omitempty"` // Name is the name of this oracle script (optional). Name string `protobuf:"bytes,3,opt,name=name,proto3" json:"name,omitempty"` // Description is the description of this oracle script (optional). Description string `protobuf:"bytes,4,opt,name=description,proto3" json:"description,omitempty"` // Code is the oracle WebAssembly binary code. Can be raw of gzip compressed. Code []byte `protobuf:"bytes,5,opt,name=code,proto3" json:"code,omitempty"` // Schema is the OBI schema of this oracle script (optional). Schema string `protobuf:"bytes,6,opt,name=schema,proto3" json:"schema,omitempty"` // SourceCodeURL is the absolute URI to the script's source code (optional). SourceCodeURL string `protobuf:"bytes,7,opt,name=source_code_url,json=sourceCodeUrl,proto3" json:"source_code_url,omitempty"` // Sender is the signer of this message. Must be the current oracle script's owner. Sender github_com_cosmos_cosmos_sdk_types.AccAddress `protobuf:"bytes,8,opt,name=sender,proto3,casttype=github.com/cosmos/cosmos-sdk/types.AccAddress" json:"sender,omitempty"` }
MsgEditOracleScript is a message for editing an existing oracle script.
func NewMsgEditOracleScript ¶
func NewMsgEditOracleScript( OracleScriptID OracleScriptID, Owner github_com_cosmos_cosmos_sdk_types.AccAddress, Name string, Description string, Code []byte, Schema string, SourceCodeURL string, Sender github_com_cosmos_cosmos_sdk_types.AccAddress, ) MsgEditOracleScript
func (*MsgEditOracleScript) Descriptor ¶
func (*MsgEditOracleScript) Descriptor() ([]byte, []int)
func (*MsgEditOracleScript) Equal ¶
func (this *MsgEditOracleScript) Equal(that interface{}) bool
func (*MsgEditOracleScript) GetCode ¶
func (m *MsgEditOracleScript) GetCode() []byte
func (*MsgEditOracleScript) GetDescription ¶
func (m *MsgEditOracleScript) GetDescription() string
func (*MsgEditOracleScript) GetName ¶
func (m *MsgEditOracleScript) GetName() string
func (*MsgEditOracleScript) GetOracleScriptID ¶
func (m *MsgEditOracleScript) GetOracleScriptID() OracleScriptID
func (*MsgEditOracleScript) GetOwner ¶
func (m *MsgEditOracleScript) GetOwner() github_com_cosmos_cosmos_sdk_types.AccAddress
func (*MsgEditOracleScript) GetSchema ¶
func (m *MsgEditOracleScript) GetSchema() string
func (*MsgEditOracleScript) GetSender ¶
func (m *MsgEditOracleScript) GetSender() github_com_cosmos_cosmos_sdk_types.AccAddress
func (MsgEditOracleScript) GetSignBytes ¶
func (msg MsgEditOracleScript) GetSignBytes() []byte
GetSignBytes returns raw JSON bytes to be signed by the signers (sdk.Msg interface).
func (MsgEditOracleScript) GetSigners ¶
func (msg MsgEditOracleScript) GetSigners() []sdk.AccAddress
GetSigners returns the required signers for the given MsgEditOracleScript (sdk.Msg interface).
func (*MsgEditOracleScript) GetSourceCodeURL ¶
func (m *MsgEditOracleScript) GetSourceCodeURL() string
func (*MsgEditOracleScript) Marshal ¶
func (m *MsgEditOracleScript) Marshal() (dAtA []byte, err error)
func (*MsgEditOracleScript) MarshalTo ¶
func (m *MsgEditOracleScript) MarshalTo(dAtA []byte) (int, error)
func (*MsgEditOracleScript) MarshalToSizedBuffer ¶
func (m *MsgEditOracleScript) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*MsgEditOracleScript) ProtoMessage ¶
func (*MsgEditOracleScript) ProtoMessage()
func (*MsgEditOracleScript) Reset ¶
func (m *MsgEditOracleScript) Reset()
func (MsgEditOracleScript) Route ¶
func (msg MsgEditOracleScript) Route() string
Route returns the route of MsgEditOracleScript - "oracle" (sdk.Msg interface).
func (*MsgEditOracleScript) Size ¶
func (m *MsgEditOracleScript) Size() (n int)
func (*MsgEditOracleScript) String ¶
func (m *MsgEditOracleScript) String() string
func (MsgEditOracleScript) Type ¶
func (msg MsgEditOracleScript) Type() string
Type returns the message type of MsgEditOracleScript (sdk.Msg interface).
func (*MsgEditOracleScript) Unmarshal ¶
func (m *MsgEditOracleScript) Unmarshal(dAtA []byte) error
func (MsgEditOracleScript) ValidateBasic ¶
func (msg MsgEditOracleScript) ValidateBasic() error
ValidateBasic checks whether the given MsgEditOracleScript instance (sdk.Msg interface).
func (*MsgEditOracleScript) XXX_DiscardUnknown ¶
func (m *MsgEditOracleScript) XXX_DiscardUnknown()
func (*MsgEditOracleScript) XXX_Marshal ¶
func (m *MsgEditOracleScript) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*MsgEditOracleScript) XXX_Merge ¶
func (m *MsgEditOracleScript) XXX_Merge(src proto.Message)
func (*MsgEditOracleScript) XXX_Size ¶
func (m *MsgEditOracleScript) XXX_Size() int
func (*MsgEditOracleScript) XXX_Unmarshal ¶
func (m *MsgEditOracleScript) XXX_Unmarshal(b []byte) error
type MsgRemoveReporter ¶
type MsgRemoveReporter struct { // Validator is the validator that wishes to remove an existing reporter. This is the signer. Validator github_com_cosmos_cosmos_sdk_types.ValAddress `` /* 126-byte string literal not displayed */ // Reporter is the address to be removed from being the validators' reporter. Reporter github_com_cosmos_cosmos_sdk_types.AccAddress `protobuf:"bytes,2,opt,name=reporter,proto3,casttype=github.com/cosmos/cosmos-sdk/types.AccAddress" json:"reporter,omitempty"` }
MsgAddReporter is a message for removing an existing reporter from a validator.
func NewMsgRemoveReporter ¶
func NewMsgRemoveReporter( Validator github_com_cosmos_cosmos_sdk_types.ValAddress, Reporter github_com_cosmos_cosmos_sdk_types.AccAddress, ) MsgRemoveReporter
func (*MsgRemoveReporter) Descriptor ¶
func (*MsgRemoveReporter) Descriptor() ([]byte, []int)
func (*MsgRemoveReporter) Equal ¶
func (this *MsgRemoveReporter) Equal(that interface{}) bool
func (*MsgRemoveReporter) GetReporter ¶
func (m *MsgRemoveReporter) GetReporter() github_com_cosmos_cosmos_sdk_types.AccAddress
func (MsgRemoveReporter) GetSignBytes ¶
func (msg MsgRemoveReporter) GetSignBytes() []byte
GetSignBytes returns raw JSON bytes to be signed by the signers (sdk.Msg interface).
func (MsgRemoveReporter) GetSigners ¶
func (msg MsgRemoveReporter) GetSigners() []sdk.AccAddress
GetSigners returns the required signers for the given MsgRemoveReporter (sdk.Msg interface).
func (*MsgRemoveReporter) GetValidator ¶
func (m *MsgRemoveReporter) GetValidator() github_com_cosmos_cosmos_sdk_types.ValAddress
func (*MsgRemoveReporter) Marshal ¶
func (m *MsgRemoveReporter) Marshal() (dAtA []byte, err error)
func (*MsgRemoveReporter) MarshalTo ¶
func (m *MsgRemoveReporter) MarshalTo(dAtA []byte) (int, error)
func (*MsgRemoveReporter) MarshalToSizedBuffer ¶
func (m *MsgRemoveReporter) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*MsgRemoveReporter) ProtoMessage ¶
func (*MsgRemoveReporter) ProtoMessage()
func (*MsgRemoveReporter) Reset ¶
func (m *MsgRemoveReporter) Reset()
func (MsgRemoveReporter) Route ¶
func (msg MsgRemoveReporter) Route() string
Route returns the route of MsgRemoveReporter - "oracle" (sdk.Msg interface).
func (*MsgRemoveReporter) Size ¶
func (m *MsgRemoveReporter) Size() (n int)
func (*MsgRemoveReporter) String ¶
func (m *MsgRemoveReporter) String() string
func (MsgRemoveReporter) Type ¶
func (msg MsgRemoveReporter) Type() string
Type returns the message type of MsgRemoveReporter (sdk.Msg interface).
func (*MsgRemoveReporter) Unmarshal ¶
func (m *MsgRemoveReporter) Unmarshal(dAtA []byte) error
func (MsgRemoveReporter) ValidateBasic ¶
func (msg MsgRemoveReporter) ValidateBasic() error
ValidateBasic checks whether the given MsgRemoveReporter instance (sdk.Msg interface).
func (*MsgRemoveReporter) XXX_DiscardUnknown ¶
func (m *MsgRemoveReporter) XXX_DiscardUnknown()
func (*MsgRemoveReporter) XXX_Marshal ¶
func (m *MsgRemoveReporter) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*MsgRemoveReporter) XXX_Merge ¶
func (m *MsgRemoveReporter) XXX_Merge(src proto.Message)
func (*MsgRemoveReporter) XXX_Size ¶
func (m *MsgRemoveReporter) XXX_Size() int
func (*MsgRemoveReporter) XXX_Unmarshal ¶
func (m *MsgRemoveReporter) XXX_Unmarshal(b []byte) error
type MsgReportData ¶
type MsgReportData struct { // RequestID is the identifier of the request to report to. RequestID RequestID `protobuf:"varint,1,opt,name=request_id,json=requestId,proto3,casttype=RequestID" json:"request_id,omitempty"` // RawReports is the list of report information for each of the request's external ID. RawReports []RawReport `protobuf:"bytes,2,rep,name=raw_reports,json=rawReports,proto3" json:"raw_reports"` // Validator is the address of the validator that owns this report. Validator github_com_cosmos_cosmos_sdk_types.ValAddress `` /* 126-byte string literal not displayed */ // Reporter is the message signer who submits this report transaction for the validator. Reporter github_com_cosmos_cosmos_sdk_types.AccAddress `protobuf:"bytes,4,opt,name=reporter,proto3,casttype=github.com/cosmos/cosmos-sdk/types.AccAddress" json:"reporter,omitempty"` }
MsgReportData is a message for reporting to a data request by a validator.
func NewMsgReportData ¶
func NewMsgReportData( RequestID RequestID, RawReports []RawReport, Validator github_com_cosmos_cosmos_sdk_types.ValAddress, Reporter github_com_cosmos_cosmos_sdk_types.AccAddress, ) MsgReportData
func (*MsgReportData) Descriptor ¶
func (*MsgReportData) Descriptor() ([]byte, []int)
func (*MsgReportData) Equal ¶
func (this *MsgReportData) Equal(that interface{}) bool
func (*MsgReportData) GetRawReports ¶
func (m *MsgReportData) GetRawReports() []RawReport
func (*MsgReportData) GetReporter ¶
func (m *MsgReportData) GetReporter() github_com_cosmos_cosmos_sdk_types.AccAddress
func (*MsgReportData) GetRequestID ¶
func (m *MsgReportData) GetRequestID() RequestID
func (MsgReportData) GetSignBytes ¶
func (msg MsgReportData) GetSignBytes() []byte
GetSignBytes returns raw JSON bytes to be signed by the signers (sdk.Msg interface).
func (MsgReportData) GetSigners ¶
func (msg MsgReportData) GetSigners() []sdk.AccAddress
GetSigners returns the required signers for the given MsgReportData (sdk.Msg interface).
func (*MsgReportData) GetValidator ¶
func (m *MsgReportData) GetValidator() github_com_cosmos_cosmos_sdk_types.ValAddress
func (*MsgReportData) Marshal ¶
func (m *MsgReportData) Marshal() (dAtA []byte, err error)
func (*MsgReportData) MarshalToSizedBuffer ¶
func (m *MsgReportData) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*MsgReportData) ProtoMessage ¶
func (*MsgReportData) ProtoMessage()
func (*MsgReportData) Reset ¶
func (m *MsgReportData) Reset()
func (MsgReportData) Route ¶
func (msg MsgReportData) Route() string
Route returns the route of MsgReportData - "oracle" (sdk.Msg interface).
func (*MsgReportData) Size ¶
func (m *MsgReportData) Size() (n int)
func (*MsgReportData) String ¶
func (m *MsgReportData) String() string
func (MsgReportData) Type ¶
func (msg MsgReportData) Type() string
Type returns the message type of MsgReportData (sdk.Msg interface).
func (*MsgReportData) Unmarshal ¶
func (m *MsgReportData) Unmarshal(dAtA []byte) error
func (MsgReportData) ValidateBasic ¶
func (msg MsgReportData) ValidateBasic() error
ValidateBasic checks whether the given MsgReportData instance (sdk.Msg interface).
func (*MsgReportData) XXX_DiscardUnknown ¶
func (m *MsgReportData) XXX_DiscardUnknown()
func (*MsgReportData) XXX_Marshal ¶
func (m *MsgReportData) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*MsgReportData) XXX_Merge ¶
func (m *MsgReportData) XXX_Merge(src proto.Message)
func (*MsgReportData) XXX_Size ¶
func (m *MsgReportData) XXX_Size() int
func (*MsgReportData) XXX_Unmarshal ¶
func (m *MsgReportData) XXX_Unmarshal(b []byte) error
type MsgRequestData ¶
type MsgRequestData struct { // OracleScriptID is the identifier of the oracle script to call. OracleScriptID OracleScriptID `` /* 130-byte string literal not displayed */ // Calldata is the OBI encoded call parameters to the oracle script. Calldata []byte `protobuf:"bytes,2,opt,name=calldata,proto3" json:"calldata,omitempty"` // AskCount is the number of validators to perform the oracle task. AskCount uint64 `protobuf:"varint,3,opt,name=ask_count,json=askCount,proto3" json:"ask_count,omitempty"` // MinCount is the minimum number of validators sufficient to resolve the tasks. MinCount uint64 `protobuf:"varint,4,opt,name=min_count,json=minCount,proto3" json:"min_count,omitempty"` // ClientID is the client-provided unique identifier to tracking the request. ClientID string `protobuf:"bytes,5,opt,name=client_id,json=clientId,proto3" json:"client_id,omitempty"` // Sender is the sender of this message. Sender github_com_cosmos_cosmos_sdk_types.AccAddress `protobuf:"bytes,6,opt,name=sender,proto3,casttype=github.com/cosmos/cosmos-sdk/types.AccAddress" json:"sender,omitempty"` }
MsgRequestData is a message for sending a data oracle request.
func NewMsgRequestData ¶
func NewMsgRequestData( OracleScriptID OracleScriptID, Calldata []byte, AskCount uint64, MinCount uint64, ClientID string, Sender github_com_cosmos_cosmos_sdk_types.AccAddress, ) MsgRequestData
func (*MsgRequestData) Descriptor ¶
func (*MsgRequestData) Descriptor() ([]byte, []int)
func (*MsgRequestData) Equal ¶
func (this *MsgRequestData) Equal(that interface{}) bool
func (*MsgRequestData) GetAskCount ¶
func (m *MsgRequestData) GetAskCount() uint64
func (*MsgRequestData) GetCalldata ¶
func (m *MsgRequestData) GetCalldata() []byte
func (*MsgRequestData) GetClientID ¶
func (m *MsgRequestData) GetClientID() string
func (*MsgRequestData) GetMinCount ¶
func (m *MsgRequestData) GetMinCount() uint64
func (*MsgRequestData) GetOracleScriptID ¶
func (m *MsgRequestData) GetOracleScriptID() OracleScriptID
func (*MsgRequestData) GetSender ¶
func (m *MsgRequestData) GetSender() github_com_cosmos_cosmos_sdk_types.AccAddress
func (MsgRequestData) GetSignBytes ¶
func (msg MsgRequestData) GetSignBytes() []byte
GetSignBytes returns raw JSON bytes to be signed by the signers (sdk.Msg interface).
func (MsgRequestData) GetSigners ¶
func (msg MsgRequestData) GetSigners() []sdk.AccAddress
GetSigners returns the required signers for the given MsgRequestData (sdk.Msg interface).
func (*MsgRequestData) Marshal ¶
func (m *MsgRequestData) Marshal() (dAtA []byte, err error)
func (*MsgRequestData) MarshalToSizedBuffer ¶
func (m *MsgRequestData) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*MsgRequestData) ProtoMessage ¶
func (*MsgRequestData) ProtoMessage()
func (*MsgRequestData) Reset ¶
func (m *MsgRequestData) Reset()
func (MsgRequestData) Route ¶
func (msg MsgRequestData) Route() string
Route returns the route of MsgRequestData - "oracle" (sdk.Msg interface).
func (*MsgRequestData) Size ¶
func (m *MsgRequestData) Size() (n int)
func (*MsgRequestData) String ¶
func (m *MsgRequestData) String() string
func (MsgRequestData) Type ¶
func (msg MsgRequestData) Type() string
Type returns the message type of MsgRequestData (sdk.Msg interface).
func (*MsgRequestData) Unmarshal ¶
func (m *MsgRequestData) Unmarshal(dAtA []byte) error
func (MsgRequestData) ValidateBasic ¶
func (msg MsgRequestData) ValidateBasic() error
ValidateBasic checks whether the given MsgRequestData instance (sdk.Msg interface).
func (*MsgRequestData) XXX_DiscardUnknown ¶
func (m *MsgRequestData) XXX_DiscardUnknown()
func (*MsgRequestData) XXX_Marshal ¶
func (m *MsgRequestData) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*MsgRequestData) XXX_Merge ¶
func (m *MsgRequestData) XXX_Merge(src proto.Message)
func (*MsgRequestData) XXX_Size ¶
func (m *MsgRequestData) XXX_Size() int
func (*MsgRequestData) XXX_Unmarshal ¶
func (m *MsgRequestData) XXX_Unmarshal(b []byte) error
type OraclePool ¶
type OraclePool struct {
DataProvidersPool sdk.DecCoins `json:"data_providers_pool" yaml:"data_providers_pool"`
}
pool of <odin> tokens bought by data providers for <geo> tokens
func (OraclePool) ValidateGenesis ¶
func (f OraclePool) ValidateGenesis() error
ValidateGenesis validates the oracle pool for a genesis state
type OracleRequestPacketData ¶
type OracleRequestPacketData struct { // ClientID is the unique identifier of this oracle request, as specified by the client. // This same unique ID will be sent back to the requester with the oracle response. ClientID string `protobuf:"bytes,1,opt,name=client_id,json=clientId,proto3" json:"client_id,omitempty"` // OracleScriptID is the unique identifier of the oracle script to be executed. OracleScriptID OracleScriptID `` /* 130-byte string literal not displayed */ // Calldata is the calldata bytes available for oracle executor to read. Calldata []byte `protobuf:"bytes,3,opt,name=calldata,proto3" json:"calldata,omitempty"` // AskCount is the number of validators that are requested to respond to this oracle request. // Higher value means more security, at a higher gas cost. AskCount uint64 `protobuf:"varint,4,opt,name=ask_count,json=askCount,proto3" json:"ask_count,omitempty"` // MinCount is the minimum number of validators necessary for the request to proceed to the // execution phase. Higher value means more security, at the cost of liveness. MinCount uint64 `protobuf:"varint,5,opt,name=min_count,json=minCount,proto3" json:"min_count,omitempty"` }
OracleRequestPacketData encodes an oracle request sent from other blockchains to BandChain.
func NewOracleRequestPacketData ¶
func NewOracleRequestPacketData( ClientID string, OracleScriptID OracleScriptID, Calldata []byte, AskCount uint64, MinCount uint64, ) OracleRequestPacketData
func (*OracleRequestPacketData) Descriptor ¶
func (*OracleRequestPacketData) Descriptor() ([]byte, []int)
func (*OracleRequestPacketData) Equal ¶
func (this *OracleRequestPacketData) Equal(that interface{}) bool
func (*OracleRequestPacketData) GetAskCount ¶
func (m *OracleRequestPacketData) GetAskCount() uint64
func (OracleRequestPacketData) GetBytes ¶
func (p OracleRequestPacketData) GetBytes() []byte
GetBytes returns the bytes representation of this oracle request packet data.
func (*OracleRequestPacketData) GetCalldata ¶
func (m *OracleRequestPacketData) GetCalldata() []byte
func (*OracleRequestPacketData) GetClientID ¶
func (m *OracleRequestPacketData) GetClientID() string
func (*OracleRequestPacketData) GetMinCount ¶
func (m *OracleRequestPacketData) GetMinCount() uint64
func (*OracleRequestPacketData) GetOracleScriptID ¶
func (m *OracleRequestPacketData) GetOracleScriptID() OracleScriptID
func (*OracleRequestPacketData) Marshal ¶
func (m *OracleRequestPacketData) Marshal() (dAtA []byte, err error)
func (*OracleRequestPacketData) MarshalTo ¶
func (m *OracleRequestPacketData) MarshalTo(dAtA []byte) (int, error)
func (*OracleRequestPacketData) MarshalToSizedBuffer ¶
func (m *OracleRequestPacketData) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*OracleRequestPacketData) ProtoMessage ¶
func (*OracleRequestPacketData) ProtoMessage()
func (*OracleRequestPacketData) Reset ¶
func (m *OracleRequestPacketData) Reset()
func (*OracleRequestPacketData) Size ¶
func (m *OracleRequestPacketData) Size() (n int)
func (*OracleRequestPacketData) String ¶
func (m *OracleRequestPacketData) String() string
func (*OracleRequestPacketData) Unmarshal ¶
func (m *OracleRequestPacketData) Unmarshal(dAtA []byte) error
func (*OracleRequestPacketData) XXX_DiscardUnknown ¶
func (m *OracleRequestPacketData) XXX_DiscardUnknown()
func (*OracleRequestPacketData) XXX_Marshal ¶
func (m *OracleRequestPacketData) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*OracleRequestPacketData) XXX_Merge ¶
func (m *OracleRequestPacketData) XXX_Merge(src proto.Message)
func (*OracleRequestPacketData) XXX_Size ¶
func (m *OracleRequestPacketData) XXX_Size() int
func (*OracleRequestPacketData) XXX_Unmarshal ¶
func (m *OracleRequestPacketData) XXX_Unmarshal(b []byte) error
type OracleResponsePacketData ¶
type OracleResponsePacketData struct { // ClientID is the unique identifier matched with that of the oracle request packet. ClientID string `protobuf:"bytes,1,opt,name=client_id,json=clientId,proto3" json:"client_id,omitempty"` // RequestID is BandChain's unique identifier for this oracle request. RequestID RequestID `protobuf:"varint,2,opt,name=request_id,json=requestId,proto3,casttype=RequestID" json:"request_id,omitempty"` // AnsCount is the number of validators among to the asked validators that actually responded // to this oracle request prior to this oracle request being resolved. AnsCount uint64 `protobuf:"varint,3,opt,name=ans_count,json=ansCount,proto3" json:"ans_count,omitempty"` // RequestTime is the UNIX epoch time at which the request was sent to BandChain. RequestTime int64 `protobuf:"varint,4,opt,name=request_time,json=requestTime,proto3" json:"request_time,omitempty"` // ResolveTime is the UNIX epoch time at which the request was resolved to the final result. ResolveTime int64 `protobuf:"varint,5,opt,name=resolve_time,json=resolveTime,proto3" json:"resolve_time,omitempty"` // ResolveStatus is the status of this oracle request, which can be OK, FAILURE, or EXPIRED. ResolveStatus ResolveStatus `` /* 148-byte string literal not displayed */ // Result is the final aggregated value only available if status if OK. Result []byte `protobuf:"bytes,7,opt,name=result,proto3" json:"result,omitempty"` }
OracleResponsePacketData encodes an oracle response from BandChain to the requester.
func NewOracleResponsePacketData ¶
func NewOracleResponsePacketData( ClientID string, RequestID RequestID, AnsCount uint64, RequestTime int64, ResolveTime int64, ResolveStatus ResolveStatus, Result []byte, ) OracleResponsePacketData
func (*OracleResponsePacketData) Descriptor ¶
func (*OracleResponsePacketData) Descriptor() ([]byte, []int)
func (*OracleResponsePacketData) Equal ¶
func (this *OracleResponsePacketData) Equal(that interface{}) bool
func (*OracleResponsePacketData) GetAnsCount ¶
func (m *OracleResponsePacketData) GetAnsCount() uint64
func (OracleResponsePacketData) GetBytes ¶
func (p OracleResponsePacketData) GetBytes() []byte
GetBytes returns the bytes representation of this oracle response packet data.
func (*OracleResponsePacketData) GetClientID ¶
func (m *OracleResponsePacketData) GetClientID() string
func (*OracleResponsePacketData) GetRequestID ¶
func (m *OracleResponsePacketData) GetRequestID() RequestID
func (*OracleResponsePacketData) GetRequestTime ¶
func (m *OracleResponsePacketData) GetRequestTime() int64
func (*OracleResponsePacketData) GetResolveStatus ¶
func (m *OracleResponsePacketData) GetResolveStatus() ResolveStatus
func (*OracleResponsePacketData) GetResolveTime ¶
func (m *OracleResponsePacketData) GetResolveTime() int64
func (*OracleResponsePacketData) GetResult ¶
func (m *OracleResponsePacketData) GetResult() []byte
func (*OracleResponsePacketData) Marshal ¶
func (m *OracleResponsePacketData) Marshal() (dAtA []byte, err error)
func (*OracleResponsePacketData) MarshalTo ¶
func (m *OracleResponsePacketData) MarshalTo(dAtA []byte) (int, error)
func (*OracleResponsePacketData) MarshalToSizedBuffer ¶
func (m *OracleResponsePacketData) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*OracleResponsePacketData) ProtoMessage ¶
func (*OracleResponsePacketData) ProtoMessage()
func (*OracleResponsePacketData) Reset ¶
func (m *OracleResponsePacketData) Reset()
func (*OracleResponsePacketData) Size ¶
func (m *OracleResponsePacketData) Size() (n int)
func (*OracleResponsePacketData) String ¶
func (m *OracleResponsePacketData) String() string
func (*OracleResponsePacketData) Unmarshal ¶
func (m *OracleResponsePacketData) Unmarshal(dAtA []byte) error
func (*OracleResponsePacketData) XXX_DiscardUnknown ¶
func (m *OracleResponsePacketData) XXX_DiscardUnknown()
func (*OracleResponsePacketData) XXX_Marshal ¶
func (m *OracleResponsePacketData) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*OracleResponsePacketData) XXX_Merge ¶
func (m *OracleResponsePacketData) XXX_Merge(src proto.Message)
func (*OracleResponsePacketData) XXX_Size ¶
func (m *OracleResponsePacketData) XXX_Size() int
func (*OracleResponsePacketData) XXX_Unmarshal ¶
func (m *OracleResponsePacketData) XXX_Unmarshal(b []byte) error
type OracleScript ¶
type OracleScript struct { Owner github_com_cosmos_cosmos_sdk_types.AccAddress `protobuf:"bytes,1,opt,name=owner,proto3,casttype=github.com/cosmos/cosmos-sdk/types.AccAddress" json:"owner,omitempty"` Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"` Description string `protobuf:"bytes,3,opt,name=description,proto3" json:"description,omitempty"` Filename string `protobuf:"bytes,4,opt,name=filename,proto3" json:"filename,omitempty"` Schema string `protobuf:"bytes,5,opt,name=schema,proto3" json:"schema,omitempty"` SourceCodeURL string `protobuf:"bytes,6,opt,name=source_code_url,json=sourceCodeUrl,proto3" json:"source_code_url,omitempty"` }
OracleScript is the data structure for storing oracle scripts in the storage.
func NewOracleScript ¶
func NewOracleScript( Owner github_com_cosmos_cosmos_sdk_types.AccAddress, Name string, Description string, Filename string, Schema string, SourceCodeURL string, ) OracleScript
func (*OracleScript) Descriptor ¶
func (*OracleScript) Descriptor() ([]byte, []int)
func (*OracleScript) Equal ¶
func (this *OracleScript) Equal(that interface{}) bool
func (*OracleScript) GetDescription ¶
func (m *OracleScript) GetDescription() string
func (*OracleScript) GetFilename ¶
func (m *OracleScript) GetFilename() string
func (*OracleScript) GetName ¶
func (m *OracleScript) GetName() string
func (*OracleScript) GetOwner ¶
func (m *OracleScript) GetOwner() github_com_cosmos_cosmos_sdk_types.AccAddress
func (*OracleScript) GetSchema ¶
func (m *OracleScript) GetSchema() string
func (*OracleScript) GetSourceCodeURL ¶
func (m *OracleScript) GetSourceCodeURL() string
func (*OracleScript) Marshal ¶
func (m *OracleScript) Marshal() (dAtA []byte, err error)
func (*OracleScript) MarshalToSizedBuffer ¶
func (m *OracleScript) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*OracleScript) ProtoMessage ¶
func (*OracleScript) ProtoMessage()
func (*OracleScript) Reset ¶
func (m *OracleScript) Reset()
func (*OracleScript) Size ¶
func (m *OracleScript) Size() (n int)
func (*OracleScript) String ¶
func (m *OracleScript) String() string
func (*OracleScript) Unmarshal ¶
func (m *OracleScript) Unmarshal(dAtA []byte) error
func (*OracleScript) XXX_DiscardUnknown ¶
func (m *OracleScript) XXX_DiscardUnknown()
func (*OracleScript) XXX_Marshal ¶
func (m *OracleScript) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*OracleScript) XXX_Merge ¶
func (m *OracleScript) XXX_Merge(src proto.Message)
func (*OracleScript) XXX_Size ¶
func (m *OracleScript) XXX_Size() int
func (*OracleScript) XXX_Unmarshal ¶
func (m *OracleScript) XXX_Unmarshal(b []byte) error
type OracleScriptID ¶
type OracleScriptID int64
OracleScriptID is the type-safe unique identifier type for oracle scripts.
type Params ¶
type Params struct { // MaxRawRequestCount is the maximum number of data source raw requests a request can make. MaxRawRequestCount uint64 `protobuf:"varint,1,opt,name=max_raw_request_count,json=maxRawRequestCount,proto3" json:"max_raw_request_count,omitempty"` // MaxAskCount is the maximum number of validators a request can target. MaxAskCount uint64 `protobuf:"varint,2,opt,name=max_ask_count,json=maxAskCount,proto3" json:"max_ask_count,omitempty"` // ExpirationBlockCount is the number of blocks a request stays valid before it gets // expired due to insufficient reports. ExpirationBlockCount uint64 `protobuf:"varint,3,opt,name=expiration_block_count,json=expirationBlockCount,proto3" json:"expiration_block_count,omitempty"` // BaseRequestGas is the base amount of Cosmos-SDK gas charged for an oracle request. BaseRequestGas uint64 `protobuf:"varint,4,opt,name=base_request_gas,json=baseRequestGas,proto3" json:"base_request_gas,omitempty"` // PerValidatorRequestGas is the amount of Cosmos-SDK gas charged per requested validator. PerValidatorRequestGas uint64 `` /* 132-byte string literal not displayed */ // SamplingTryCount the number of validator sampling tries to pick the highest voting power // subset of validators to perform an oracle task. SamplingTryCount uint64 `protobuf:"varint,6,opt,name=sampling_try_count,json=samplingTryCount,proto3" json:"sampling_try_count,omitempty"` // OracleRewardPercentage is the percentage of block rewards allocated to active oracle validators. OracleRewardPercentage uint64 `` /* 130-byte string literal not displayed */ // InactivePenaltyDuration is the duration period where a validator cannot activate back // after missing an oracle report. InactivePenaltyDuration uint64 `` /* 133-byte string literal not displayed */ // MaxDataSize is the maximum number of bytes that can be present in the report as the result MaxDataSize uint64 `protobuf:"varint,9,opt,name=max_data_size,json=maxDataSize,proto3" json:"max_data_size,omitempty"` // MaxCalldataSize is the maximum number of bytes that can be present in the calldata MaxCalldataSize uint64 `protobuf:"varint,10,opt,name=max_calldata_size,json=maxCalldataSize,proto3" json:"max_calldata_size,omitempty"` // DataProviderRewardPerByte is the amount of tokens, user gets for the byte of data provided DataProviderRewardPerByte CoinDecProto `` /* 157-byte string literal not displayed */ // DataRequesterBasicFee is the amount of tokens user has to pay in DataProvidersPool for the data provided DataRequesterBasicFee CoinProto `` /* 140-byte string literal not displayed */ }
Params is the data structure that keeps the parameters of the oracle module.
func NewParams ¶
func NewParams( MaxRawRequestCount uint64, MaxAskCount uint64, ExpirationBlockCount uint64, BaseRequestGas uint64, PerValidatorRequestGas uint64, SamplingTryCount uint64, OracleRewardPercentage uint64, InactivePenaltyDuration uint64, MaxDataSize uint64, MaxCalldataSize uint64, DataProviderRewardPerByte CoinDecProto, DataRequesterBasicFee CoinProto, ) Params
func (*Params) Descriptor ¶
func (*Params) GetBaseRequestGas ¶
func (*Params) GetExpirationBlockCount ¶
func (*Params) GetInactivePenaltyDuration ¶
func (*Params) GetMaxAskCount ¶
func (*Params) GetMaxCalldataSize ¶
func (*Params) GetMaxDataSize ¶
func (*Params) GetMaxRawRequestCount ¶
func (*Params) GetOracleRewardPercentage ¶
func (*Params) GetPerValidatorRequestGas ¶
func (*Params) GetSamplingTryCount ¶
func (*Params) MarshalToSizedBuffer ¶
func (*Params) ParamSetPairs ¶
func (p *Params) ParamSetPairs() params.ParamSetPairs
ParamSetPairs implements the params.ParamSet interface for Params.
func (*Params) ProtoMessage ¶
func (*Params) ProtoMessage()
func (*Params) XXX_DiscardUnknown ¶
func (m *Params) XXX_DiscardUnknown()
func (*Params) XXX_Marshal ¶
func (*Params) XXX_Unmarshal ¶
type PrepareEnv ¶
type PrepareEnv struct { BaseEnv // contains filtered or unexported fields }
PrepareEnv implements ExecEnv interface only expected function and panic on non-prepare functions.
func NewPrepareEnv ¶
func NewPrepareEnv(req Request, maxRawRequests, maxDataSize int64) *PrepareEnv
NewPrepareEnv creates a new environment instance for prepare period.
func (*PrepareEnv) AskExternalData ¶
func (env *PrepareEnv) AskExternalData(eid int64, did int64, data []byte) error
AskExternalData implements Owasm ExecEnv interface.
func (*PrepareEnv) GetRawRequests ¶
func (env *PrepareEnv) GetRawRequests() []RawRequest
GetRawRequests returns the list of raw requests made during Owasm prepare run.
type QueryActiveValidatorResult ¶
type QueryActiveValidatorResult struct { Address sdk.ValAddress `json:"address"` Power uint64 `json:"power"` }
QueryActiveValidatorResult is the struct for the result of request active validators.
type QueryCountsResult ¶
type QueryCountsResult struct { DataSourceCount int64 `json:"data_source_count"` OracleScriptCount int64 `json:"oracle_script_count"` RequestCount int64 `json:"request_count"` }
QueryCountsResult is the struct for the result of query counts.
type QueryRequestResult ¶
type QueryRequestResult struct { Request Request `json:"request"` Reports []Report `json:"reports"` Result *Result `json:"result"` }
QueryRequestResult is the struct for the result of request query.
type RawReport ¶
type RawReport struct { ExternalID ExternalID `protobuf:"varint,1,opt,name=external_id,json=externalId,proto3,casttype=ExternalID" json:"external_id,omitempty"` ExitCode uint32 `protobuf:"varint,2,opt,name=exit_code,json=exitCode,proto3" json:"exit_code,omitempty"` Data []byte `protobuf:"bytes,3,opt,name=data,proto3" json:"data,omitempty"` }
RawRequest is the data structure for storing raw reporter in the storage.
func NewRawReport ¶
func NewRawReport( ExternalID ExternalID, ExitCode uint32, Data []byte, ) RawReport
func (*RawReport) Descriptor ¶
func (*RawReport) GetExitCode ¶
func (*RawReport) GetExternalID ¶
func (m *RawReport) GetExternalID() ExternalID
func (*RawReport) MarshalToSizedBuffer ¶
func (*RawReport) ProtoMessage ¶
func (*RawReport) ProtoMessage()
func (*RawReport) XXX_DiscardUnknown ¶
func (m *RawReport) XXX_DiscardUnknown()
func (*RawReport) XXX_Marshal ¶
func (*RawReport) XXX_Unmarshal ¶
type RawRequest ¶
type RawRequest struct { ExternalID ExternalID `protobuf:"varint,1,opt,name=external_id,json=externalId,proto3,casttype=ExternalID" json:"external_id,omitempty"` DataSourceID DataSourceID `protobuf:"varint,2,opt,name=data_source_id,json=dataSourceId,proto3,casttype=DataSourceID" json:"data_source_id,omitempty"` Calldata []byte `protobuf:"bytes,3,opt,name=calldata,proto3" json:"calldata,omitempty"` }
RawRequest is the data structure for storing raw requests in the storage.
func NewRawRequest ¶
func NewRawRequest( ExternalID ExternalID, DataSourceID DataSourceID, Calldata []byte, ) RawRequest
func (*RawRequest) Descriptor ¶
func (*RawRequest) Descriptor() ([]byte, []int)
func (*RawRequest) Equal ¶
func (this *RawRequest) Equal(that interface{}) bool
func (*RawRequest) GetCalldata ¶
func (m *RawRequest) GetCalldata() []byte
func (*RawRequest) GetDataSourceID ¶
func (m *RawRequest) GetDataSourceID() DataSourceID
func (*RawRequest) GetExternalID ¶
func (m *RawRequest) GetExternalID() ExternalID
func (*RawRequest) Marshal ¶
func (m *RawRequest) Marshal() (dAtA []byte, err error)
func (*RawRequest) MarshalToSizedBuffer ¶
func (m *RawRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*RawRequest) ProtoMessage ¶
func (*RawRequest) ProtoMessage()
func (*RawRequest) Reset ¶
func (m *RawRequest) Reset()
func (*RawRequest) Size ¶
func (m *RawRequest) Size() (n int)
func (*RawRequest) String ¶
func (m *RawRequest) String() string
func (*RawRequest) Unmarshal ¶
func (m *RawRequest) Unmarshal(dAtA []byte) error
func (*RawRequest) XXX_DiscardUnknown ¶
func (m *RawRequest) XXX_DiscardUnknown()
func (*RawRequest) XXX_Marshal ¶
func (m *RawRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*RawRequest) XXX_Merge ¶
func (m *RawRequest) XXX_Merge(src proto.Message)
func (*RawRequest) XXX_Size ¶
func (m *RawRequest) XXX_Size() int
func (*RawRequest) XXX_Unmarshal ¶
func (m *RawRequest) XXX_Unmarshal(b []byte) error
type Report ¶
type Report struct { Validator github_com_cosmos_cosmos_sdk_types.ValAddress `` /* 126-byte string literal not displayed */ InBeforeResolve bool `protobuf:"varint,2,opt,name=in_before_resolve,json=inBeforeResolve,proto3" json:"in_before_resolve,omitempty"` RawReports []RawReport `protobuf:"bytes,3,rep,name=raw_reports,json=rawReports,proto3" json:"raw_reports"` }
Report is the data structure for storing reports in the storage.
func NewReport ¶
func NewReport( Validator github_com_cosmos_cosmos_sdk_types.ValAddress, InBeforeResolve bool, RawReports []RawReport, ) Report
func (*Report) Descriptor ¶
func (*Report) GetInBeforeResolve ¶
func (*Report) GetRawReports ¶
func (*Report) GetValidator ¶
func (m *Report) GetValidator() github_com_cosmos_cosmos_sdk_types.ValAddress
func (*Report) MarshalToSizedBuffer ¶
func (*Report) ProtoMessage ¶
func (*Report) ProtoMessage()
func (*Report) XXX_DiscardUnknown ¶
func (m *Report) XXX_DiscardUnknown()
func (*Report) XXX_Marshal ¶
func (*Report) XXX_Unmarshal ¶
type Request ¶
type Request struct { OracleScriptID OracleScriptID `` /* 130-byte string literal not displayed */ Calldata []byte `protobuf:"bytes,2,opt,name=calldata,proto3" json:"calldata,omitempty"` RequestedValidators []github_com_cosmos_cosmos_sdk_types.ValAddress `` /* 173-byte string literal not displayed */ MinCount uint64 `protobuf:"varint,4,opt,name=min_count,json=minCount,proto3" json:"min_count,omitempty"` RequestHeight int64 `protobuf:"varint,5,opt,name=request_height,json=requestHeight,proto3" json:"request_height,omitempty"` RequestTime time.Time `protobuf:"bytes,6,opt,name=request_time,json=requestTime,proto3,stdtime" json:"request_time"` ClientID string `protobuf:"bytes,7,opt,name=client_id,json=clientId,proto3" json:"client_id,omitempty"` RawRequests []RawRequest `protobuf:"bytes,8,rep,name=raw_requests,json=rawRequests,proto3" json:"raw_requests"` }
Request is the data structure for storing requests in the storage.
func NewRequest ¶
func NewRequest( OracleScriptID OracleScriptID, Calldata []byte, RequestedValidators []github_com_cosmos_cosmos_sdk_types.ValAddress, MinCount uint64, RequestHeight int64, RequestTime time.Time, ClientID string, RawRequests []RawRequest, ) Request
func (*Request) Descriptor ¶
func (*Request) GetCalldata ¶
func (*Request) GetClientID ¶
func (*Request) GetMinCount ¶
func (*Request) GetOracleScriptID ¶
func (m *Request) GetOracleScriptID() OracleScriptID
func (*Request) GetRawRequests ¶
func (m *Request) GetRawRequests() []RawRequest
func (*Request) GetRequestHeight ¶
func (*Request) GetRequestTime ¶
func (*Request) GetRequestedValidators ¶
func (m *Request) GetRequestedValidators() []github_com_cosmos_cosmos_sdk_types.ValAddress
func (*Request) MarshalToSizedBuffer ¶
func (*Request) ProtoMessage ¶
func (*Request) ProtoMessage()
func (*Request) XXX_DiscardUnknown ¶
func (m *Request) XXX_DiscardUnknown()
func (*Request) XXX_Marshal ¶
func (*Request) XXX_Unmarshal ¶
type RequestID ¶
type RequestID int64
RequestID is the type-safe unique identifier type for data requests.
type RequestSpec ¶
type RequestSpec interface { GetOracleScriptID() OracleScriptID GetCalldata() []byte GetAskCount() uint64 GetMinCount() uint64 GetClientID() string }
RequestSpec captures the essence of what it means to be a request-making object.
type RequestWithSenderSpec ¶
type RequestWithSenderSpec interface { RequestSpec GetSender() sdk.AccAddress }
type ResolveStatus ¶
type ResolveStatus int32
ResolveStatus encodes the status of an oracle request.
const ( // Open - the request is not yet resolved. ResolveStatus_Open ResolveStatus = 0 // Success - the request has been resolved successfully with no errors. ResolveStatus_Success ResolveStatus = 1 // Failure - an error occured during the request's resolve call. ResolveStatus_Failure ResolveStatus = 2 // Expired - the request does not get enough reports from validator within the timeframe. ResolveStatus_Expired ResolveStatus = 3 )
func (ResolveStatus) EnumDescriptor ¶
func (ResolveStatus) EnumDescriptor() ([]byte, []int)
func (ResolveStatus) String ¶
func (x ResolveStatus) String() string
type Result ¶
type Result struct { RequestPacketData OracleRequestPacketData `json:"request_packet_data"` ResponsePacketData OracleResponsePacketData `json:"response_packet_data"` }
Result is a convenience struct that keeps both request and response packets of a request.
func NewResult ¶
func NewResult(req OracleRequestPacketData, res OracleResponsePacketData) Result
NewResult creates a new Result instance.
type StakingKeeper ¶
type StakingKeeper interface { ValidatorByConsAddr(sdk.Context, sdk.ConsAddress) stakingexported.ValidatorI IterateBondedValidatorsByPower(ctx sdk.Context, fn func(index int64, validator stakingexported.ValidatorI) (stop bool)) Validator(ctx sdk.Context, address sdk.ValAddress) stakingexported.ValidatorI }
StakingKeeper defines the expected staking keeper.
type SupplyKeeper ¶
type SupplyKeeper interface { GetModuleAddress(name string) sdk.AccAddress GetModuleAccount(ctx sdk.Context, name string) supplyexported.ModuleAccountI SetModuleAccount(sdk.Context, supplyexported.ModuleAccountI) SendCoinsFromModuleToModule(ctx sdk.Context, senderModule string, recipientModule string, amt sdk.Coins) error SendCoinsFromModuleToAccount(ctx sdk.Context, senderModule string, recipientAddr sdk.AccAddress, amt sdk.Coins) error SendCoinsFromAccountToModule(ctx sdk.Context, senderAddr sdk.AccAddress, recipientModule string, amt sdk.Coins) error }
SupplyKeeper defines the expected supply Keeper.
type ValidatorStatus ¶
type ValidatorStatus struct { IsActive bool `protobuf:"varint,1,opt,name=is_active,json=isActive,proto3" json:"is_active,omitempty"` Since time.Time `protobuf:"bytes,2,opt,name=since,proto3,stdtime" json:"since"` }
ValidatorStatus maintains whether a validator is an active oracle provider.
func NewValidatorStatus ¶
func NewValidatorStatus( IsActive bool, Since time.Time, ) ValidatorStatus
func (*ValidatorStatus) Descriptor ¶
func (*ValidatorStatus) Descriptor() ([]byte, []int)
func (*ValidatorStatus) Equal ¶
func (this *ValidatorStatus) Equal(that interface{}) bool
func (*ValidatorStatus) GetIsActive ¶
func (m *ValidatorStatus) GetIsActive() bool
func (*ValidatorStatus) GetSince ¶
func (m *ValidatorStatus) GetSince() time.Time
func (*ValidatorStatus) Marshal ¶
func (m *ValidatorStatus) Marshal() (dAtA []byte, err error)
func (*ValidatorStatus) MarshalToSizedBuffer ¶
func (m *ValidatorStatus) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*ValidatorStatus) ProtoMessage ¶
func (*ValidatorStatus) ProtoMessage()
func (*ValidatorStatus) Reset ¶
func (m *ValidatorStatus) Reset()
func (*ValidatorStatus) Size ¶
func (m *ValidatorStatus) Size() (n int)
func (*ValidatorStatus) String ¶
func (m *ValidatorStatus) String() string
func (*ValidatorStatus) Unmarshal ¶
func (m *ValidatorStatus) Unmarshal(dAtA []byte) error
func (*ValidatorStatus) XXX_DiscardUnknown ¶
func (m *ValidatorStatus) XXX_DiscardUnknown()
func (*ValidatorStatus) XXX_Marshal ¶
func (m *ValidatorStatus) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*ValidatorStatus) XXX_Merge ¶
func (m *ValidatorStatus) XXX_Merge(src proto.Message)
func (*ValidatorStatus) XXX_Size ¶
func (m *ValidatorStatus) XXX_Size() int
func (*ValidatorStatus) XXX_Unmarshal ¶
func (m *ValidatorStatus) XXX_Unmarshal(b []byte) error