Documentation ¶
Index ¶
- type AddSensorToDeviceParams
- type Attribute
- type Config
- type CreateAttributeParams
- type CreateDeviceAddrParams
- type CreateDeviceParams
- type CreateLocationParams
- type CreateMessageParams
- type CreateSensorsParams
- type CreateThresholdParams
- type DBTX
- type Device
- type Deviceaddr
- type Devicelocation
- type Devicestate
- type GetAllDeviceInformationRow
- type GetAttributesListRow
- type GetDeviceSensorsRow
- type GetDevicesListRow
- type GetHighestMeasurementOfLastHourParams
- type GetLatestMeasurementParams
- type GetMessageslistRow
- type GetSensorsListRow
- type InsertMeasurementParams
- type Measurement
- type Notificationmessage
- type Operator
- type Queries
- func (q *Queries) AddSensorToDevice(ctx context.Context, arg AddSensorToDeviceParams) error
- func (q *Queries) AttributeIdFromName(ctx context.Context, attributeName string) (int32, error)
- func (q *Queries) Close() error
- func (q *Queries) CreateAttribute(ctx context.Context, arg CreateAttributeParams) error
- func (q *Queries) CreateDevice(ctx context.Context, arg CreateDeviceParams) error
- func (q *Queries) CreateDeviceAddr(ctx context.Context, arg CreateDeviceAddrParams) error
- func (q *Queries) CreateLocation(ctx context.Context, arg CreateLocationParams) error
- func (q *Queries) CreateMessage(ctx context.Context, arg CreateMessageParams) (Notificationmessage, error)
- func (q *Queries) CreateSensors(ctx context.Context, arg CreateSensorsParams) error
- func (q *Queries) CreateThreshold(ctx context.Context, arg CreateThresholdParams) (Threshold, error)
- func (q *Queries) DeleteConfigByKey(ctx context.Context, ckey string) (Config, error)
- func (q *Queries) DeleteDeviceSensors(ctx context.Context, deviceID int32) error
- func (q *Queries) DeleteMessage(ctx context.Context, id int32) (Notificationmessage, error)
- func (q *Queries) DeleteThreshold(ctx context.Context, id int32) (Threshold, error)
- func (q *Queries) GetAllAttributes(ctx context.Context) ([]Attribute, error)
- func (q *Queries) GetAllDeviceInformation(ctx context.Context) ([]GetAllDeviceInformationRow, error)
- func (q *Queries) GetAttributesList(ctx context.Context) ([]GetAttributesListRow, error)
- func (q *Queries) GetConfigByKey(ctx context.Context, ckey string) (Config, error)
- func (q *Queries) GetDeviceSensors(ctx context.Context, deviceID int32) ([]GetDeviceSensorsRow, error)
- func (q *Queries) GetDevicesList(ctx context.Context) ([]GetDevicesListRow, error)
- func (q *Queries) GetExpiredSecrets(ctx context.Context) ([]Secret, error)
- func (q *Queries) GetHighestMeasurementOfLastHour(ctx context.Context, arg GetHighestMeasurementOfLastHourParams) (interface{}, error)
- func (q *Queries) GetIntervalConfig(ctx context.Context) (int32, error)
- func (q *Queries) GetLatestMeasurement(ctx context.Context, arg GetLatestMeasurementParams) (Measurement, error)
- func (q *Queries) GetLocations(ctx context.Context) ([]Devicelocation, error)
- func (q *Queries) GetMessages(ctx context.Context, id int32) (Notificationmessage, error)
- func (q *Queries) GetMessageslist(ctx context.Context) ([]GetMessageslistRow, error)
- func (q *Queries) GetOperators(ctx context.Context) ([]Operator, error)
- func (q *Queries) GetSecretByName(ctx context.Context, name string) (Secret, error)
- func (q *Queries) GetSensors(ctx context.Context) ([]Sensor, error)
- func (q *Queries) GetSensorsList(ctx context.Context) ([]GetSensorsListRow, error)
- func (q *Queries) GetThresholds(ctx context.Context) ([]Threshold, error)
- func (q *Queries) InsertMeasurement(ctx context.Context, arg InsertMeasurementParams) error
- func (q *Queries) LoadConfigData(ctx context.Context, dollar_1 []string) ([]Config, error)
- func (q *Queries) SetConfigBykey(ctx context.Context, arg SetConfigBykeyParams) error
- func (q *Queries) UpdateAttribute(ctx context.Context, arg UpdateAttributeParams) error
- func (q *Queries) UpdateDevice(ctx context.Context, arg UpdateDeviceParams) error
- func (q *Queries) UpdateDeviceAddr(ctx context.Context, arg UpdateDeviceAddrParams) error
- func (q *Queries) UpdateLocation(ctx context.Context, arg UpdateLocationParams) error
- func (q *Queries) UpdateMessage(ctx context.Context, arg UpdateMessageParams) (Notificationmessage, error)
- func (q *Queries) UpdateSecret(ctx context.Context, arg UpdateSecretParams) error
- func (q *Queries) UpdateSensors(ctx context.Context, arg UpdateSensorsParams) error
- func (q *Queries) UpdateThreshold(ctx context.Context, arg UpdateThresholdParams) (Threshold, error)
- func (q *Queries) WithTx(tx *sql.Tx) *Queries
- type Reminder
- type Remindersdevice
- type Secret
- type Sensor
- type Sensordevice
- type SetConfigBykeyParams
- type Threshold
- type UpdateAttributeParams
- type UpdateDeviceAddrParams
- type UpdateDeviceParams
- type UpdateLocationParams
- type UpdateMessageParams
- type UpdateSecretParams
- type UpdateSensorsParams
- type UpdateThresholdParams
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AddSensorToDeviceParams ¶
type Config ¶
type Config struct { Ckey string `json:"ckey"` Cvalue sql.NullString `json:"cvalue"` Ctype int32 `json:"ctype"` }
type CreateAttributeParams ¶
type CreateDeviceAddrParams ¶
type CreateDeviceParams ¶
type CreateLocationParams ¶
type CreateMessageParams ¶ added in v0.2.1
type CreateSensorsParams ¶
type CreateThresholdParams ¶ added in v0.2.1
type CreateThresholdParams struct { SensorID int32 `json:"sensor_id"` DeviceID int32 `json:"device_id"` AttributeID int32 `json:"attribute_id"` MessageID int32 `json:"message_id"` Value1 float64 `json:"value1"` Value2 sql.NullFloat64 `json:"value2"` Frequency int32 `json:"frequency"` OperatorID int32 `json:"operator_id"` Triggername string `json:"triggername"` Triggerenabled bool `json:"triggerenabled"` }
type Deviceaddr ¶
type Devicelocation ¶
type Devicestate ¶
type GetAttributesListRow ¶ added in v0.2.1
type GetDeviceSensorsRow ¶
type GetDevicesListRow ¶ added in v0.2.1
type GetMessageslistRow ¶ added in v0.2.1
type GetSensorsListRow ¶ added in v0.2.1
type InsertMeasurementParams ¶
type Measurement ¶
type Notificationmessage ¶
type Notificationmessage struct { ID int32 `json:"id"` Title string `json:"title"` Topic string `json:"topic"` Payload string `json:"payload"` Tags sql.NullString `json:"tags"` Messagepriority int32 `json:"messagepriority"` CreatedAt time.Time `json:"created_at"` UpdatedAt time.Time `json:"updated_at"` }
type Queries ¶
type Queries struct {
// contains filtered or unexported fields
}
func (*Queries) AddSensorToDevice ¶
func (q *Queries) AddSensorToDevice(ctx context.Context, arg AddSensorToDeviceParams) error
func (*Queries) AttributeIdFromName ¶
func (*Queries) CreateAttribute ¶
func (q *Queries) CreateAttribute(ctx context.Context, arg CreateAttributeParams) error
func (*Queries) CreateDevice ¶
func (q *Queries) CreateDevice(ctx context.Context, arg CreateDeviceParams) error
func (*Queries) CreateDeviceAddr ¶
func (q *Queries) CreateDeviceAddr(ctx context.Context, arg CreateDeviceAddrParams) error
func (*Queries) CreateLocation ¶
func (q *Queries) CreateLocation(ctx context.Context, arg CreateLocationParams) error
func (*Queries) CreateMessage ¶ added in v0.2.1
func (q *Queries) CreateMessage(ctx context.Context, arg CreateMessageParams) (Notificationmessage, error)
func (*Queries) CreateSensors ¶
func (q *Queries) CreateSensors(ctx context.Context, arg CreateSensorsParams) error
func (*Queries) CreateThreshold ¶ added in v0.2.1
func (*Queries) DeleteConfigByKey ¶
func (*Queries) DeleteDeviceSensors ¶
func (*Queries) DeleteMessage ¶ added in v0.2.1
func (*Queries) DeleteThreshold ¶ added in v0.2.1
func (*Queries) GetAllAttributes ¶
func (*Queries) GetAllDeviceInformation ¶
func (q *Queries) GetAllDeviceInformation(ctx context.Context) ([]GetAllDeviceInformationRow, error)
func (*Queries) GetAttributesList ¶ added in v0.2.1
func (q *Queries) GetAttributesList(ctx context.Context) ([]GetAttributesListRow, error)
func (*Queries) GetConfigByKey ¶
func (*Queries) GetDeviceSensors ¶
func (*Queries) GetDevicesList ¶ added in v0.2.1
func (q *Queries) GetDevicesList(ctx context.Context) ([]GetDevicesListRow, error)
func (*Queries) GetExpiredSecrets ¶
func (*Queries) GetHighestMeasurementOfLastHour ¶
func (q *Queries) GetHighestMeasurementOfLastHour(ctx context.Context, arg GetHighestMeasurementOfLastHourParams) (interface{}, error)
func (*Queries) GetIntervalConfig ¶
func (*Queries) GetLatestMeasurement ¶
func (q *Queries) GetLatestMeasurement(ctx context.Context, arg GetLatestMeasurementParams) (Measurement, error)
func (*Queries) GetLocations ¶
func (q *Queries) GetLocations(ctx context.Context) ([]Devicelocation, error)
func (*Queries) GetMessages ¶ added in v0.2.1
func (*Queries) GetMessageslist ¶ added in v0.2.1
func (q *Queries) GetMessageslist(ctx context.Context) ([]GetMessageslistRow, error)
func (*Queries) GetOperators ¶ added in v0.2.1
func (*Queries) GetSecretByName ¶
func (*Queries) GetSensorsList ¶ added in v0.2.1
func (q *Queries) GetSensorsList(ctx context.Context) ([]GetSensorsListRow, error)
func (*Queries) GetThresholds ¶ added in v0.2.1
func (*Queries) InsertMeasurement ¶
func (q *Queries) InsertMeasurement(ctx context.Context, arg InsertMeasurementParams) error
func (*Queries) LoadConfigData ¶
func (*Queries) SetConfigBykey ¶
func (q *Queries) SetConfigBykey(ctx context.Context, arg SetConfigBykeyParams) error
func (*Queries) UpdateAttribute ¶
func (q *Queries) UpdateAttribute(ctx context.Context, arg UpdateAttributeParams) error
func (*Queries) UpdateDevice ¶
func (q *Queries) UpdateDevice(ctx context.Context, arg UpdateDeviceParams) error
func (*Queries) UpdateDeviceAddr ¶
func (q *Queries) UpdateDeviceAddr(ctx context.Context, arg UpdateDeviceAddrParams) error
func (*Queries) UpdateLocation ¶
func (q *Queries) UpdateLocation(ctx context.Context, arg UpdateLocationParams) error
func (*Queries) UpdateMessage ¶ added in v0.2.1
func (q *Queries) UpdateMessage(ctx context.Context, arg UpdateMessageParams) (Notificationmessage, error)
func (*Queries) UpdateSecret ¶
func (q *Queries) UpdateSecret(ctx context.Context, arg UpdateSecretParams) error
func (*Queries) UpdateSensors ¶
func (q *Queries) UpdateSensors(ctx context.Context, arg UpdateSensorsParams) error
func (*Queries) UpdateThreshold ¶ added in v0.2.1
type Reminder ¶
type Reminder struct { ID int32 `json:"id"` MessageID int32 `json:"message_id"` Frequency int32 `json:"frequency"` Remindername string `json:"remindername"` Reminderenabled bool `json:"reminderenabled"` CreatedAt time.Time `json:"created_at"` UpdatedAt time.Time `json:"updated_at"` LastReminded sql.NullTime `json:"last_reminded"` }
type Remindersdevice ¶
type Sensordevice ¶
type SetConfigBykeyParams ¶
type Threshold ¶
type Threshold struct { ID int32 `json:"id"` SensorID int32 `json:"sensor_id"` DeviceID int32 `json:"device_id"` AttributeID int32 `json:"attribute_id"` MessageID int32 `json:"message_id"` Value1 float64 `json:"value1"` Value2 sql.NullFloat64 `json:"value2"` Frequency int32 `json:"frequency"` CreatedAt time.Time `json:"created_at"` UpdatedAt time.Time `json:"updated_at"` LastTriggered sql.NullTime `json:"last_triggered"` OperatorID int32 `json:"operator_id"` Triggername string `json:"triggername"` Triggerenabled bool `json:"triggerenabled"` }
type UpdateAttributeParams ¶
type UpdateDeviceAddrParams ¶
type UpdateDeviceParams ¶
type UpdateLocationParams ¶
type UpdateMessageParams ¶ added in v0.2.1
type UpdateSecretParams ¶
type UpdateSensorsParams ¶
type UpdateThresholdParams ¶ added in v0.2.1
type UpdateThresholdParams struct { SensorID int32 `json:"sensor_id"` DeviceID int32 `json:"device_id"` AttributeID int32 `json:"attribute_id"` MessageID int32 `json:"message_id"` Value1 float64 `json:"value1"` Value2 sql.NullFloat64 `json:"value2"` Frequency int32 `json:"frequency"` OperatorID int32 `json:"operator_id"` Triggername string `json:"triggername"` Triggerenabled bool `json:"triggerenabled"` ID int32 `json:"id"` }
Click to show internal directories.
Click to hide internal directories.