Documentation ¶
Index ¶
- Variables
- type DataPoint
- func (*DataPoint) Descriptor() ([]byte, []int)deprecated
- func (x *DataPoint) GetAttr() string
- func (x *DataPoint) GetBoolVal() bool
- func (x *DataPoint) GetBytesVal() []byte
- func (x *DataPoint) GetFl64Val() float64
- func (x *DataPoint) GetIntVal() int32
- func (x *DataPoint) GetStrVal() string
- func (x *DataPoint) GetToken() string
- func (x *DataPoint) GetTraceId() string
- func (x *DataPoint) GetTs() *timestamppb.Timestamp
- func (x *DataPoint) GetUniqId() string
- func (m *DataPoint) GetValOneof() isDataPoint_ValOneof
- func (*DataPoint) ProtoMessage()
- func (x *DataPoint) ProtoReflect() protoreflect.Message
- func (x *DataPoint) Reset()
- func (x *DataPoint) String() string
- func (m *DataPoint) Validate() error
- func (m *DataPoint) ValidateAll() error
- type DataPointMultiError
- type DataPointValidationError
- type DataPoint_BoolVal
- type DataPoint_BytesVal
- type DataPoint_Fl64Val
- type DataPoint_IntVal
- type DataPoint_StrVal
Constants ¶
This section is empty.
Variables ¶
var File_common_thingspect_datapoint_proto protoreflect.FileDescriptor
Functions ¶
This section is empty.
Types ¶
type DataPoint ¶
type DataPoint struct { // Device unique ID. Ignored during MQTT ingest if provided as part of the topic. Required for API publish. UniqId string `protobuf:"bytes,1,opt,name=uniq_id,json=uniqID,proto3" json:"uniq_id,omitempty"` // Device attribute. Attr string `protobuf:"bytes,2,opt,name=attr,proto3" json:"attr,omitempty"` // Attribute value. // // Types that are assignable to ValOneof: // // *DataPoint_IntVal // *DataPoint_Fl64Val // *DataPoint_StrVal // *DataPoint_BoolVal // *DataPoint_BytesVal ValOneof isDataPoint_ValOneof `protobuf_oneof:"val_oneof"` // Timestamp. If not present during MQTT ingest or API publish, the current time will be used. Ts *timestamppb.Timestamp `protobuf:"bytes,7,opt,name=ts,proto3" json:"ts,omitempty"` // Authentication token (UUID). Only used during MQTT ingest. Will be ignored if provided as part of the Payload message. Token string `protobuf:"bytes,8,opt,name=token,proto3" json:"token,omitempty"` // Trace ID (UUID). Assigned by the platform, will be ignored if provided during MQTT ingest or API publish. TraceId string `protobuf:"bytes,9,opt,name=trace_id,json=traceId,proto3" json:"trace_id,omitempty"` // contains filtered or unexported fields }
DataPoint represents a data point as stored in the database.
func (*DataPoint) Descriptor
deprecated
func (*DataPoint) GetBoolVal ¶
func (*DataPoint) GetBytesVal ¶
func (*DataPoint) GetFl64Val ¶
func (*DataPoint) GetTraceId ¶
func (*DataPoint) GetTs ¶
func (x *DataPoint) GetTs() *timestamppb.Timestamp
func (*DataPoint) GetValOneof ¶
func (m *DataPoint) GetValOneof() isDataPoint_ValOneof
func (*DataPoint) ProtoMessage ¶
func (*DataPoint) ProtoMessage()
func (*DataPoint) ProtoReflect ¶
func (x *DataPoint) ProtoReflect() protoreflect.Message
func (*DataPoint) Validate ¶
Validate checks the field values on DataPoint with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.
func (*DataPoint) ValidateAll ¶
ValidateAll checks the field values on DataPoint with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in DataPointMultiError, or nil if none found.
type DataPointMultiError ¶
type DataPointMultiError []error
DataPointMultiError is an error wrapping multiple validation errors returned by DataPoint.ValidateAll() if the designated constraints aren't met.
func (DataPointMultiError) AllErrors ¶
func (m DataPointMultiError) AllErrors() []error
AllErrors returns a list of validation violation errors.
func (DataPointMultiError) Error ¶
func (m DataPointMultiError) Error() string
Error returns a concatenation of all the error messages it wraps.
type DataPointValidationError ¶
type DataPointValidationError struct {
// contains filtered or unexported fields
}
DataPointValidationError is the validation error returned by DataPoint.Validate if the designated constraints aren't met.
func (DataPointValidationError) Cause ¶
func (e DataPointValidationError) Cause() error
Cause function returns cause value.
func (DataPointValidationError) Error ¶
func (e DataPointValidationError) Error() string
Error satisfies the builtin error interface
func (DataPointValidationError) ErrorName ¶
func (e DataPointValidationError) ErrorName() string
ErrorName returns error name.
func (DataPointValidationError) Field ¶
func (e DataPointValidationError) Field() string
Field function returns field value.
func (DataPointValidationError) Key ¶
func (e DataPointValidationError) Key() bool
Key function returns key value.
func (DataPointValidationError) Reason ¶
func (e DataPointValidationError) Reason() string
Reason function returns reason value.
type DataPoint_BoolVal ¶
type DataPoint_BoolVal struct { // Boolean value. BoolVal bool `protobuf:"varint,6,opt,name=bool_val,json=boolVal,proto3,oneof"` }
type DataPoint_BytesVal ¶
type DataPoint_BytesVal struct { // Bytes value. When used in JSON, the value will be represented as a base64 string. BytesVal []byte `protobuf:"bytes,16,opt,name=bytes_val,json=bytesVal,proto3,oneof"` }
type DataPoint_Fl64Val ¶
type DataPoint_Fl64Val struct { // Float value, 64-bit. Fl64Val float64 `protobuf:"fixed64,4,opt,name=fl64_val,json=fl64Val,proto3,oneof"` }
type DataPoint_IntVal ¶
type DataPoint_IntVal struct { // Integer value, 32-bit. IntVal int32 `protobuf:"zigzag32,3,opt,name=int_val,json=intVal,proto3,oneof"` }
type DataPoint_StrVal ¶
type DataPoint_StrVal struct { // String value. StrVal string `protobuf:"bytes,5,opt,name=str_val,json=strVal,proto3,oneof"` }