Documentation ¶
Index ¶
- Variables
- func AdjustToStartOfWeek(t time.Time) time.Time
- func Calculate(metricStore, activityStore store.Store) http.HandlerFunc
- func Create(metricStore store.Store) http.HandlerFunc
- func Delete(metricStore store.Store) http.HandlerFunc
- func List(metricStore store.Store) http.HandlerFunc
- func Load(metricStore store.Store) http.HandlerFunc
- func Update(metricStore store.Store) http.HandlerFunc
- type ByDate
- type Configuration
- type Result
- type Value
Constants ¶
This section is empty.
Variables ¶
View Source
var Collection store.CollectionName = "metricConfigurations"
Functions ¶
Types ¶
type Configuration ¶
type Configuration struct { Id primitive.ObjectID `json:"id,omitempty" bson:"_id,omitempty"` UserId string `json:"userId" bson:"userId"` Name string `json:"name" bson:"name"` Tags []string `json:"tags" bson:"tags"` Threshold float64 `json:"threshold" bson:"threshold"` }
func (Configuration) ObjectId ¶
func (c Configuration) ObjectId() primitive.ObjectID
func (Configuration) SetObjectId ¶
func (c Configuration) SetObjectId(id primitive.ObjectID)
type Result ¶
type Result struct { Id string `json:"id,omitempty" bson:"_id,omitempty"` Name string `json:"name,omitempty" bson:"_id,omitempty"` TotalExceedingDuration time.Duration `json:"totalExceedingDuration" bson:"totalExceedingDuration"` CurrentExceedingDuration time.Duration `json:"currentExceedingDuration" bson:"currentExceedingDuration"` Threshold float64 `json:"threshold,omitempty" bson:"threshold,omitempty"` Values []Value `json:"values,omitempty" bson:"values,omitempty"` }
Click to show internal directories.
Click to hide internal directories.