aggregate

package
v1.37.3 Latest Latest
Warning

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

Go to latest
Published: Apr 19, 2026 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var IgnoreFieldMismatch = datastore.IgnoreFieldMismatch

Functions

func Init

func Init(a *Aggregate, name string, t time.Time, freq Frequency)

func Query

Types

type Aggregate

type Aggregate struct {
	mixin.Model[Aggregate]

	Instance     string    `json:"instance"`
	Name         string    `json:"name"`
	Type         string    `json:"type"`
	BinTimestamp time.Time `json:"binTimestamp"`
	Value        int64     `json:"value"`
	VectorValue  []int64   `json:"vectorValue,omitempty" orm:"default:[]"`
}

func New

func New(db *datastore.Datastore) *Aggregate

func (*Aggregate) Load

func (a *Aggregate) Load(p []datastore.Property) (err error)

func (*Aggregate) Save

func (a *Aggregate) Save() (p []datastore.Property, err error)

type Frequency

type Frequency string
const (
	Hourly Frequency = "Hourly"
	Daily            = "Daily"
)

Jump to

Keyboard shortcuts

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