Documentation ¶
Index ¶
- Constants
- func AlertNames() []string
- func AlertSettingFallSnoozes() []int
- func AlertSettingFallUnits() []string
- func AlertSettingFallValuesForUnits(units string) []float64
- func AlertSettingFixedLowSnoozes() []int
- func AlertSettingFixedLowUnits() []string
- func AlertSettingFixedLowValuesForUnits(units string) []float64
- func AlertSettingHighSnoozes() []int
- func AlertSettingHighUnits() []string
- func AlertSettingHighValuesForUnits(units string) []float64
- func AlertSettingLowSnoozes() []int
- func AlertSettingLowUnits() []string
- func AlertSettingLowValuesForUnits(units string) []float64
- func AlertSettingOutOfRangeSnoozes() []int
- func AlertSettingOutOfRangeUnits() []string
- func AlertSettingOutOfRangeValuesForUnits(units string) []float64
- func AlertSettingRiseSnoozes() []int
- func AlertSettingRiseUnits() []string
- func AlertSettingRiseValuesForUnits(units string) []float64
- type AlertSetting
- type AlertSettings
- type Calibration
- type CalibrationsResponse
- type Client
- type Device
- type DevicesResponse
- type EGV
- type EGVsResponse
- type Event
- type EventsResponse
Constants ¶
View Source
const ( AlertNameFixedLow = "fixedLow" AlertNameLow = "low" AlertNameHigh = "high" AlertNameRise = "rise" AlertNameFall = "fall" AlertNameOutOfRange = "outOfRange" EventCarbs = "carbs" EventExercise = "exercise" EventHealth = "health" EventInsulin = "insulin" ExerciseLight = "light" ExerciseMedium = "medium" ExerciseHeavy = "heavy" HealthIllness = "illness" HealthStress = "stress" HealthHighSymptoms = "highSymptoms" HealthLowSymptoms = "lowSymptoms" HealthCycle = "cycle" HealthAlcohol = "alcohol" ModelG5MobileApp = "G5 Mobile App" ModelG5Receiver = "G5 Receiver" ModelG4Receiver = "G4 Receiver" ModelUnknown = "Unknown" StatusHigh = "high" StatusLow = "low" StatusOK = "ok" StatusOutOfCalibration = "outOfCalibration" StatusSensorNoise = "sensorNoise" TrendDoubleUp = "doubleUp" TrendSingleUp = "singleUp" TrendFortyFiveUp = "fortyFiveUp" TrendFlat = "flat" TrendFortyFiveDown = "fortyFiveDown" TrendSingleDown = "singleDown" TrendDoubleDown = "doubleDown" TrendNone = "none" TrendNotComputable = "notComputable" TrendRateOutOfRange = "rateOutOfRange" UnitMinutes = "minutes" UnitGrams = "grams" UnitUnits = "units" UnitMgdL = "mg/dL" UnitMmolL = "mmol/L" UnitMgdLMin = "mg/dL/min" UnitMmolLMin = "mmol/L/min" EGVValueMinMgdL = 40 EGVValueMaxMgdL = 400 DeviceIDMultiple = "multiple" DeviceIDUnknown = "unknown" DeviceModelMultiple = "multiple" DeviceSerialNumberMultiple = "multiple" DateTimeFormat = "2006-01-02T15:04:05" NowThreshold = 24 * time.Hour TransmitterIDExpressionString = "^[0-9A-Z]{5,6}$" )
Variables ¶
This section is empty.
Functions ¶
func AlertNames ¶ added in v1.28.0
func AlertNames() []string
func AlertSettingFallSnoozes ¶ added in v1.28.0
func AlertSettingFallSnoozes() []int
func AlertSettingFallUnits ¶ added in v1.28.0
func AlertSettingFallUnits() []string
func AlertSettingFallValuesForUnits ¶ added in v1.28.0
func AlertSettingFixedLowSnoozes ¶ added in v1.28.0
func AlertSettingFixedLowSnoozes() []int
func AlertSettingFixedLowUnits ¶ added in v1.28.0
func AlertSettingFixedLowUnits() []string
func AlertSettingFixedLowValuesForUnits ¶ added in v1.28.0
func AlertSettingHighSnoozes ¶ added in v1.28.0
func AlertSettingHighSnoozes() []int
func AlertSettingHighUnits ¶ added in v1.28.0
func AlertSettingHighUnits() []string
func AlertSettingHighValuesForUnits ¶ added in v1.28.0
func AlertSettingLowSnoozes ¶ added in v1.28.0
func AlertSettingLowSnoozes() []int
func AlertSettingLowUnits ¶ added in v1.28.0
func AlertSettingLowUnits() []string
func AlertSettingLowValuesForUnits ¶ added in v1.28.0
func AlertSettingOutOfRangeSnoozes ¶ added in v1.28.0
func AlertSettingOutOfRangeSnoozes() []int
func AlertSettingOutOfRangeUnits ¶ added in v1.28.0
func AlertSettingOutOfRangeUnits() []string
func AlertSettingOutOfRangeValuesForUnits ¶ added in v1.28.0
func AlertSettingRiseSnoozes ¶ added in v1.28.0
func AlertSettingRiseSnoozes() []int
func AlertSettingRiseUnits ¶ added in v1.28.0
func AlertSettingRiseUnits() []string
func AlertSettingRiseValuesForUnits ¶ added in v1.28.0
Types ¶
type AlertSetting ¶
type AlertSetting struct { SystemTime time.Time `json:"systemTime,omitempty"` DisplayTime time.Time `json:"displayTime,omitempty"` AlertName string `json:"alertName,omitempty"` Unit string `json:"unit,omitempty"` Value float64 `json:"value,omitempty"` Delay int `json:"delay,omitempty"` Snooze int `json:"snooze,omitempty"` Enabled bool `json:"enabled,omitempty"` }
func NewAlertSetting ¶
func NewAlertSetting() *AlertSetting
func (*AlertSetting) IsNewerMatchThan ¶ added in v1.28.0
func (a *AlertSetting) IsNewerMatchThan(alertSetting *AlertSetting) bool
func (*AlertSetting) Parse ¶
func (a *AlertSetting) Parse(parser structure.ObjectParser)
func (*AlertSetting) Validate ¶
func (a *AlertSetting) Validate(validator structure.Validator)
type AlertSettings ¶ added in v1.28.0
type AlertSettings []*AlertSetting
func (AlertSettings) ContainsNewerMatch ¶ added in v1.28.0
func (a AlertSettings) ContainsNewerMatch(alertSetting *AlertSetting) bool
func (AlertSettings) Deduplicate ¶ added in v1.28.0
func (a AlertSettings) Deduplicate() AlertSettings
type Calibration ¶
type Calibration struct { SystemTime time.Time `json:"systemTime,omitempty"` DisplayTime time.Time `json:"displayTime,omitempty"` Unit string `json:"unit,omitempty"` Value float64 `json:"value,omitempty"` TransmitterID *string `json:"transmitterId,omitempty"` }
func NewCalibration ¶
func NewCalibration() *Calibration
func (*Calibration) Parse ¶
func (c *Calibration) Parse(parser structure.ObjectParser)
func (*Calibration) Validate ¶
func (c *Calibration) Validate(validator structure.Validator)
type CalibrationsResponse ¶
type CalibrationsResponse struct {
Calibrations []*Calibration `json:"calibrations,omitempty"`
}
func NewCalibrationsResponse ¶
func NewCalibrationsResponse() *CalibrationsResponse
func (*CalibrationsResponse) Parse ¶
func (c *CalibrationsResponse) Parse(parser structure.ObjectParser)
func (*CalibrationsResponse) Validate ¶
func (c *CalibrationsResponse) Validate(validator structure.Validator)
type Client ¶
type Client interface { GetCalibrations(ctx context.Context, startTime time.Time, endTime time.Time, tokenSource oauth.TokenSource) (*CalibrationsResponse, error) GetDevices(ctx context.Context, startTime time.Time, endTime time.Time, tokenSource oauth.TokenSource) (*DevicesResponse, error) GetEGVs(ctx context.Context, startTime time.Time, endTime time.Time, tokenSource oauth.TokenSource) (*EGVsResponse, error) GetEvents(ctx context.Context, startTime time.Time, endTime time.Time, tokenSource oauth.TokenSource) (*EventsResponse, error) }
type Device ¶
type Device struct { Model string `json:"model,omitempty"` LastUploadDate time.Time `json:"lastUploadDate,omitempty"` AlertSettings AlertSettings `json:"alertSettings,omitempty"` UDI *string `json:"udi,omitempty"` SerialNumber *string `json:"serialNumber,omitempty"` TransmitterID *string `json:"transmitterId,omitempty"` SoftwareVersion *string `json:"softwareVersion,omitempty"` SoftwareNumber *string `json:"softwareNumber,omitempty"` Language *string `json:"language,omitempty"` IsMmolDisplayMode *bool `json:"isMmolDisplayMode,omitempty"` IsBlindedMode *bool `json:"isBlindedMode,omitempty"` Is24HourMode *bool `json:"is24HourMode,omitempty"` DisplayTimeOffset *int `json:"displayTimeOffset,omitempty"` SystemTimeOffset *int `json:"systemTimeOffset,omitempty"` }
func (*Device) Parse ¶
func (d *Device) Parse(parser structure.ObjectParser)
type DevicesResponse ¶
type DevicesResponse struct {
Devices []*Device `json:"devices,omitempty"`
}
func NewDevicesResponse ¶
func NewDevicesResponse() *DevicesResponse
func (*DevicesResponse) Parse ¶
func (d *DevicesResponse) Parse(parser structure.ObjectParser)
func (*DevicesResponse) Validate ¶
func (d *DevicesResponse) Validate(validator structure.Validator)
type EGV ¶
type EGV struct { SystemTime time.Time `json:"systemTime,omitempty"` DisplayTime time.Time `json:"displayTime,omitempty"` Unit string `json:"unit,omitempty"` Value float64 `json:"value,omitempty"` Status *string `json:"status,omitempty"` Trend *string `json:"trend,omitempty"` TrendRate *float64 `json:"trendRate,omitempty"` TransmitterID *string `json:"transmitterId,omitempty"` TransmitterTicks *int `json:"transmitterTicks,omitempty"` }
func (*EGV) Parse ¶
func (e *EGV) Parse(parser structure.ObjectParser)
type EGVsResponse ¶
type EGVsResponse struct { Unit string `json:"unit,omitempty"` RateUnit string `json:"rateUnit,omitempty"` EGVs []*EGV `json:"egvs,omitempty"` }
func NewEGVsResponse ¶
func NewEGVsResponse() *EGVsResponse
func (*EGVsResponse) Parse ¶
func (e *EGVsResponse) Parse(parser structure.ObjectParser)
func (*EGVsResponse) Validate ¶
func (e *EGVsResponse) Validate(validator structure.Validator)
type Event ¶
type Event struct { SystemTime time.Time `json:"systemTime,omitempty"` DisplayTime time.Time `json:"displayTime,omitempty"` EventType string `json:"eventType,omitempty"` EventSubType *string `json:"eventSubType,omitempty"` Unit *string `json:"unit,omitempty"` Value *float64 `json:"value,omitempty"` }
func (*Event) Parse ¶
func (e *Event) Parse(parser structure.ObjectParser)
type EventsResponse ¶
type EventsResponse struct {
Events []*Event `json:"events,omitempty"`
}
func NewEventsResponse ¶
func NewEventsResponse() *EventsResponse
func (*EventsResponse) Parse ¶
func (e *EventsResponse) Parse(parser structure.ObjectParser)
func (*EventsResponse) Validate ¶
func (e *EventsResponse) Validate(validator structure.Validator)
Click to show internal directories.
Click to hide internal directories.