model

package
v0.0.0-...-77837a8 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 29, 2024 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const SensorTypeLocation = "L"
View Source
const SensorTypePulse = "P"
View Source
const SensorTypeRespiration = "R"
View Source
const SensorTypeTemperature = "T"

Variables

Functions

func RandSensorData

func RandSensorData(s *Sensor) float32

func RandomString

func RandomString(n int) string

Types

type Measure

type Measure struct {
	SensorID UUID
	TS       time.Time
	Value    float32
}

type Owner

type Owner struct {
	OwnerID UUID
	Address string
	Name    string
}

func RandOwner

func RandOwner() *Owner

type Pet

type Pet struct {
	OwnerID UUID
	PetID   UUID
	ChipID  string
	Species string
	Breed   string
	Color   string
	Gender  string
	Age     int
	Weight  float32
	Address string
	Name    string
}

func RandPet

func RandPet(o *Owner) *Pet

type Sensor

type Sensor struct {
	PetID    UUID
	SensorID UUID
	Type     string
}

func RandSensor

func RandSensor(o *Pet) *Sensor

type SensorAvg

type SensorAvg struct {
	SensorID UUID
	Date     time.Time
	Hour     int
	Value    float32
}

type UUID

type UUID = gocql.UUID

func RandomUUID

func RandomUUID() UUID

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL