Documentation ¶
Index ¶
- Variables
- func NewID(signers []*Signer, filters []*Filter) string
- type Condition
- func (c Condition) DeepClone() *Condition
- func (*Condition) Descriptor() ([]byte, []int)deprecated
- func (x *Condition) GetOperator() Condition_Operator
- func (x *Condition) GetValue() string
- func (*Condition) ProtoMessage()
- func (x *Condition) ProtoReflect() protoreflect.Message
- func (x *Condition) Reset()
- func (x *Condition) String() string
- type Condition_Operator
- func (Condition_Operator) Descriptor() protoreflect.EnumDescriptor
- func (x Condition_Operator) Enum() *Condition_Operator
- func (Condition_Operator) EnumDescriptor() ([]byte, []int)deprecated
- func (x Condition_Operator) Number() protoreflect.EnumNumber
- func (x Condition_Operator) String() string
- func (Condition_Operator) Type() protoreflect.EnumType
- type Data
- func (d Data) DeepClone() *Data
- func (*Data) Descriptor() ([]byte, []int)deprecated
- func (x *Data) GetBroadcastAt() int64
- func (x *Data) GetData() []*Property
- func (x *Data) GetError() string
- func (x *Data) GetMatchedSpecIds() []string
- func (x *Data) GetMetaData() []*Property
- func (x *Data) GetSigners() []*Signer
- func (*Data) ProtoMessage()
- func (x *Data) ProtoReflect() protoreflect.Message
- func (x *Data) Reset()
- func (x *Data) String() string
- type ETHAddress
- type ExternalData
- func (o ExternalData) DeepClone() ExternalData
- func (*ExternalData) Descriptor() ([]byte, []int)deprecated
- func (x *ExternalData) GetData() *Data
- func (*ExternalData) ProtoMessage()
- func (x *ExternalData) ProtoReflect() protoreflect.Message
- func (x *ExternalData) Reset()
- func (x *ExternalData) String() string
- type Filter
- func (f Filter) DeepClone() *Filter
- func (*Filter) Descriptor() ([]byte, []int)deprecated
- func (x *Filter) GetConditions() []*Condition
- func (x *Filter) GetKey() *PropertyKey
- func (*Filter) ProtoMessage()
- func (x *Filter) ProtoReflect() protoreflect.Message
- func (x *Filter) Reset()
- func (x *Filter) String() string
- type InternalTimeTrigger
- func (*InternalTimeTrigger) Descriptor() ([]byte, []int)deprecated
- func (x *InternalTimeTrigger) GetEvery() int64
- func (x *InternalTimeTrigger) GetInitial() int64
- func (*InternalTimeTrigger) ProtoMessage()
- func (x *InternalTimeTrigger) ProtoReflect() protoreflect.Message
- func (x *InternalTimeTrigger) Reset()
- func (x *InternalTimeTrigger) String() string
- type Property
- func (p Property) DeepClone() *Property
- func (*Property) Descriptor() ([]byte, []int)deprecated
- func (x *Property) GetName() string
- func (x *Property) GetValue() string
- func (*Property) ProtoMessage()
- func (x *Property) ProtoReflect() protoreflect.Message
- func (x *Property) Reset()
- func (x *Property) String() string
- type PropertyKey
- func (p PropertyKey) DeepClone() *PropertyKey
- func (*PropertyKey) Descriptor() ([]byte, []int)deprecated
- func (x *PropertyKey) GetName() string
- func (x *PropertyKey) GetNumberDecimalPlaces() uint64
- func (x *PropertyKey) GetType() PropertyKey_Type
- func (*PropertyKey) ProtoMessage()
- func (x *PropertyKey) ProtoReflect() protoreflect.Message
- func (x *PropertyKey) Reset()
- func (x *PropertyKey) String() string
- type PropertyKey_Type
- func (PropertyKey_Type) Descriptor() protoreflect.EnumDescriptor
- func (x PropertyKey_Type) Enum() *PropertyKey_Type
- func (PropertyKey_Type) EnumDescriptor() ([]byte, []int)deprecated
- func (x PropertyKey_Type) Number() protoreflect.EnumNumber
- func (x PropertyKey_Type) String() string
- func (PropertyKey_Type) Type() protoreflect.EnumType
- type PubKey
- type Signer
- func (s Signer) DeepClone() *Signer
- func (*Signer) Descriptor() ([]byte, []int)deprecated
- func (x *Signer) GetEthAddress() *ETHAddress
- func (x *Signer) GetPubKey() *PubKey
- func (m *Signer) GetSigner() isSigner_Signer
- func (*Signer) ProtoMessage()
- func (x *Signer) ProtoReflect() protoreflect.Message
- func (x *Signer) Reset()
- func (x *Signer) String() string
- type Signer_EthAddress
- type Signer_PubKey
Constants ¶
This section is empty.
Variables ¶
var ( PropertyKey_Type_name = map[int32]string{ 0: "TYPE_UNSPECIFIED", 1: "TYPE_EMPTY", 2: "TYPE_INTEGER", 3: "TYPE_STRING", 4: "TYPE_BOOLEAN", 5: "TYPE_DECIMAL", 6: "TYPE_TIMESTAMP", } PropertyKey_Type_value = map[string]int32{ "TYPE_UNSPECIFIED": 0, "TYPE_EMPTY": 1, "TYPE_INTEGER": 2, "TYPE_STRING": 3, "TYPE_BOOLEAN": 4, "TYPE_DECIMAL": 5, "TYPE_TIMESTAMP": 6, } )
Enum value maps for PropertyKey_Type.
var ( Condition_Operator_name = map[int32]string{ 0: "OPERATOR_UNSPECIFIED", 1: "OPERATOR_EQUALS", 2: "OPERATOR_GREATER_THAN", 3: "OPERATOR_GREATER_THAN_OR_EQUAL", 4: "OPERATOR_LESS_THAN", 5: "OPERATOR_LESS_THAN_OR_EQUAL", } Condition_Operator_value = map[string]int32{ "OPERATOR_UNSPECIFIED": 0, "OPERATOR_EQUALS": 1, "OPERATOR_GREATER_THAN": 2, "OPERATOR_GREATER_THAN_OR_EQUAL": 3, "OPERATOR_LESS_THAN": 4, "OPERATOR_LESS_THAN_OR_EQUAL": 5, } )
Enum value maps for Condition_Operator.
var File_vega_data_v1_data_proto protoreflect.FileDescriptor
var File_vega_data_v1_spec_proto protoreflect.FileDescriptor
Functions ¶
Types ¶
type Condition ¶
type Condition struct { // Type of comparison to make on the value. Operator Condition_Operator `protobuf:"varint,1,opt,name=operator,proto3,enum=vega.data.v1.Condition_Operator" json:"operator,omitempty"` // Value to be compared with by the operator. Value string `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"` // contains filtered or unexported fields }
Condition describes the condition that must be validated by the network
func (*Condition) Descriptor
deprecated
func (*Condition) GetOperator ¶
func (x *Condition) GetOperator() Condition_Operator
func (*Condition) ProtoMessage ¶
func (*Condition) ProtoMessage()
func (*Condition) ProtoReflect ¶
func (x *Condition) ProtoReflect() protoreflect.Message
type Condition_Operator ¶
type Condition_Operator int32
Operator describes the type of comparison.
const ( // The default value Condition_OPERATOR_UNSPECIFIED Condition_Operator = 0 // Verify if the property values are strictly equal or not. Condition_OPERATOR_EQUALS Condition_Operator = 1 // Verify if the data source data value is greater than the Condition value. Condition_OPERATOR_GREATER_THAN Condition_Operator = 2 // Verify if the data source data value is greater than or equal to the Condition // value. Condition_OPERATOR_GREATER_THAN_OR_EQUAL Condition_Operator = 3 // Verify if the data source data value is less than the Condition value. Condition_OPERATOR_LESS_THAN Condition_Operator = 4 // Verify if the data source data value is less or equal to than the Condition // value. Condition_OPERATOR_LESS_THAN_OR_EQUAL Condition_Operator = 5 )
func (Condition_Operator) Descriptor ¶
func (Condition_Operator) Descriptor() protoreflect.EnumDescriptor
func (Condition_Operator) Enum ¶
func (x Condition_Operator) Enum() *Condition_Operator
func (Condition_Operator) EnumDescriptor
deprecated
func (Condition_Operator) EnumDescriptor() ([]byte, []int)
Deprecated: Use Condition_Operator.Descriptor instead.
func (Condition_Operator) Number ¶
func (x Condition_Operator) Number() protoreflect.EnumNumber
func (Condition_Operator) String ¶
func (x Condition_Operator) String() string
func (Condition_Operator) Type ¶
func (Condition_Operator) Type() protoreflect.EnumType
type Data ¶
type Data struct { Signers []*Signer `protobuf:"bytes,1,rep,name=signers,proto3" json:"signers,omitempty"` // Data holds all the properties of the data Data []*Property `protobuf:"bytes,2,rep,name=data,proto3" json:"data,omitempty"` // `matched_specs_ids` lists all the specs that matched this data. // When the array is empty, it means no spec matched this data. MatchedSpecIds []string `protobuf:"bytes,3,rep,name=matched_spec_ids,json=matchedSpecIds,proto3" json:"matched_spec_ids,omitempty"` // Timestamp in Unix nanoseconds for when the data was broadcast to the markets // with a matching spec. It has no value when the data did not match any spec. BroadcastAt int64 `protobuf:"varint,4,opt,name=broadcast_at,json=broadcastAt,proto3" json:"broadcast_at,omitempty"` // Holds all metadata properties MetaData []*Property `protobuf:"bytes,5,rep,name=meta_data,json=metaData,proto3" json:"meta_data,omitempty"` // Error message if the data could not be sourced. Error *string `protobuf:"bytes,6,opt,name=error,proto3,oneof" json:"error,omitempty"` // contains filtered or unexported fields }
Data describes valid source data that has been received by the node. It represents both matched and unmatched data.
func (*Data) Descriptor
deprecated
func (*Data) GetBroadcastAt ¶
func (*Data) GetMatchedSpecIds ¶
func (*Data) GetMetaData ¶ added in v0.73.0
func (*Data) GetSigners ¶
func (*Data) ProtoMessage ¶
func (*Data) ProtoMessage()
func (*Data) ProtoReflect ¶
func (x *Data) ProtoReflect() protoreflect.Message
type ETHAddress ¶
type ETHAddress struct { Address string `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"` // contains filtered or unexported fields }
func (*ETHAddress) Descriptor
deprecated
func (*ETHAddress) Descriptor() ([]byte, []int)
Deprecated: Use ETHAddress.ProtoReflect.Descriptor instead.
func (*ETHAddress) GetAddress ¶
func (x *ETHAddress) GetAddress() string
func (*ETHAddress) ProtoMessage ¶
func (*ETHAddress) ProtoMessage()
func (*ETHAddress) ProtoReflect ¶
func (x *ETHAddress) ProtoReflect() protoreflect.Message
func (*ETHAddress) Reset ¶
func (x *ETHAddress) Reset()
func (*ETHAddress) String ¶
func (x *ETHAddress) String() string
type ExternalData ¶
type ExternalData struct { Data *Data `protobuf:"bytes,1,opt,name=data,proto3" json:"data,omitempty"` // contains filtered or unexported fields }
func (ExternalData) DeepClone ¶
func (o ExternalData) DeepClone() ExternalData
func (*ExternalData) Descriptor
deprecated
func (*ExternalData) Descriptor() ([]byte, []int)
Deprecated: Use ExternalData.ProtoReflect.Descriptor instead.
func (*ExternalData) GetData ¶
func (x *ExternalData) GetData() *Data
func (*ExternalData) ProtoMessage ¶
func (*ExternalData) ProtoMessage()
func (*ExternalData) ProtoReflect ¶
func (x *ExternalData) ProtoReflect() protoreflect.Message
func (*ExternalData) Reset ¶
func (x *ExternalData) Reset()
func (*ExternalData) String ¶
func (x *ExternalData) String() string
type Filter ¶
type Filter struct { // Data source's data property key targeted by the filter. Key *PropertyKey `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"` // Conditions that should be matched by the data to be // considered of interest. Conditions []*Condition `protobuf:"bytes,2,rep,name=conditions,proto3" json:"conditions,omitempty"` // contains filtered or unexported fields }
Filter describes the conditions under which a data source data is considered of interest or not.
func (*Filter) Descriptor
deprecated
func (*Filter) GetConditions ¶
func (*Filter) GetKey ¶
func (x *Filter) GetKey() *PropertyKey
func (*Filter) ProtoMessage ¶
func (*Filter) ProtoMessage()
func (*Filter) ProtoReflect ¶
func (x *Filter) ProtoReflect() protoreflect.Message
type InternalTimeTrigger ¶ added in v0.73.0
type InternalTimeTrigger struct { // Trigger when the vega time is greater or equal to this time, in Unix seconds. Initial *int64 `protobuf:"varint,1,opt,name=initial,proto3,oneof" json:"initial,omitempty"` // Repeat the trigger every n seconds after the initial. If no time for // initial was specified, begin repeating immediately. Every int64 `protobuf:"varint,2,opt,name=every,proto3" json:"every,omitempty"` // contains filtered or unexported fields }
Trigger for an internal time data source.
func (*InternalTimeTrigger) Descriptor
deprecated
added in
v0.73.0
func (*InternalTimeTrigger) Descriptor() ([]byte, []int)
Deprecated: Use InternalTimeTrigger.ProtoReflect.Descriptor instead.
func (*InternalTimeTrigger) GetEvery ¶ added in v0.73.0
func (x *InternalTimeTrigger) GetEvery() int64
func (*InternalTimeTrigger) GetInitial ¶ added in v0.73.0
func (x *InternalTimeTrigger) GetInitial() int64
func (*InternalTimeTrigger) ProtoMessage ¶ added in v0.73.0
func (*InternalTimeTrigger) ProtoMessage()
func (*InternalTimeTrigger) ProtoReflect ¶ added in v0.73.0
func (x *InternalTimeTrigger) ProtoReflect() protoreflect.Message
func (*InternalTimeTrigger) Reset ¶ added in v0.73.0
func (x *InternalTimeTrigger) Reset()
func (*InternalTimeTrigger) String ¶ added in v0.73.0
func (x *InternalTimeTrigger) String() string
type Property ¶
type Property struct { // Name of the property. Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // Value of the property. Value string `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"` // contains filtered or unexported fields }
Property describes one property of data spec with a key with its value.
func (*Property) Descriptor
deprecated
func (*Property) ProtoMessage ¶
func (*Property) ProtoMessage()
func (*Property) ProtoReflect ¶
func (x *Property) ProtoReflect() protoreflect.Message
type PropertyKey ¶
type PropertyKey struct { // Name of the property. Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // Data type of the property. Type PropertyKey_Type `protobuf:"varint,2,opt,name=type,proto3,enum=vega.data.v1.PropertyKey_Type" json:"type,omitempty"` // Optional decimal place to be be applied on the provided value // valid only for PropertyType of type DECIMAL and INTEGER NumberDecimalPlaces *uint64 `` /* 127-byte string literal not displayed */ // contains filtered or unexported fields }
PropertyKey describes the property key contained in data source data.
func (PropertyKey) DeepClone ¶
func (p PropertyKey) DeepClone() *PropertyKey
func (*PropertyKey) Descriptor
deprecated
func (*PropertyKey) Descriptor() ([]byte, []int)
Deprecated: Use PropertyKey.ProtoReflect.Descriptor instead.
func (*PropertyKey) GetName ¶
func (x *PropertyKey) GetName() string
func (*PropertyKey) GetNumberDecimalPlaces ¶ added in v0.65.0
func (x *PropertyKey) GetNumberDecimalPlaces() uint64
func (*PropertyKey) GetType ¶
func (x *PropertyKey) GetType() PropertyKey_Type
func (*PropertyKey) ProtoMessage ¶
func (*PropertyKey) ProtoMessage()
func (*PropertyKey) ProtoReflect ¶
func (x *PropertyKey) ProtoReflect() protoreflect.Message
func (*PropertyKey) Reset ¶
func (x *PropertyKey) Reset()
func (*PropertyKey) String ¶
func (x *PropertyKey) String() string
type PropertyKey_Type ¶
type PropertyKey_Type int32
Type describes the data type of properties that are supported by the data source engine.
const ( // The default value. PropertyKey_TYPE_UNSPECIFIED PropertyKey_Type = 0 // Any type. PropertyKey_TYPE_EMPTY PropertyKey_Type = 1 // Integer type. PropertyKey_TYPE_INTEGER PropertyKey_Type = 2 // String type. PropertyKey_TYPE_STRING PropertyKey_Type = 3 // Boolean type. PropertyKey_TYPE_BOOLEAN PropertyKey_Type = 4 // Any floating point decimal type. PropertyKey_TYPE_DECIMAL PropertyKey_Type = 5 // Timestamp date type. PropertyKey_TYPE_TIMESTAMP PropertyKey_Type = 6 )
func (PropertyKey_Type) Descriptor ¶
func (PropertyKey_Type) Descriptor() protoreflect.EnumDescriptor
func (PropertyKey_Type) Enum ¶
func (x PropertyKey_Type) Enum() *PropertyKey_Type
func (PropertyKey_Type) EnumDescriptor
deprecated
func (PropertyKey_Type) EnumDescriptor() ([]byte, []int)
Deprecated: Use PropertyKey_Type.Descriptor instead.
func (PropertyKey_Type) Number ¶
func (x PropertyKey_Type) Number() protoreflect.EnumNumber
func (PropertyKey_Type) String ¶
func (x PropertyKey_Type) String() string
func (PropertyKey_Type) Type ¶
func (PropertyKey_Type) Type() protoreflect.EnumType
type PubKey ¶
type PubKey struct { Key string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"` // contains filtered or unexported fields }
PubKey is the public key that signed this data. Different public keys coming from different sources will be further separated.
func (*PubKey) Descriptor
deprecated
func (*PubKey) ProtoMessage ¶
func (*PubKey) ProtoMessage()
func (*PubKey) ProtoReflect ¶
func (x *PubKey) ProtoReflect() protoreflect.Message
type Signer ¶
type Signer struct { // Types that are assignable to Signer: // // *Signer_PubKey // *Signer_EthAddress Signer isSigner_Signer `protobuf_oneof:"signer"` // contains filtered or unexported fields }
func (*Signer) Descriptor
deprecated
func (*Signer) GetEthAddress ¶
func (x *Signer) GetEthAddress() *ETHAddress
func (*Signer) ProtoMessage ¶
func (*Signer) ProtoMessage()
func (*Signer) ProtoReflect ¶
func (x *Signer) ProtoReflect() protoreflect.Message
type Signer_EthAddress ¶
type Signer_EthAddress struct { // In case of an open oracle - Ethereum address will be submitted. EthAddress *ETHAddress `protobuf:"bytes,2,opt,name=eth_address,json=ethAddress,proto3,oneof"` }
type Signer_PubKey ¶
type Signer_PubKey struct { // List of authorized public keys that signed the data for this // source. All the public keys in the data should be contained in these // public keys. PubKey *PubKey `protobuf:"bytes,1,opt,name=pub_key,json=pubKey,proto3,oneof"` }