Documentation
¶
Index ¶
- Constants
- type AdminState
- type AutoEvent
- type BaseReading
- type BinaryReading
- type Category
- type Channel
- type ChannelType
- type Command
- type Device
- type DeviceCommand
- type DeviceProfile
- type DeviceResource
- type DeviceService
- type Event
- type Interval
- type OperatingState
- type PropertyValue
- type ProtocolProperties
- type ProvisionWatcher
- type Reading
- type ResourceOperation
- type SimpleReading
- type Subscription
- type Timestamps
Constants ¶
const ( // Locked : device is locked // Unlocked : device is unlocked Locked = "LOCKED" Unlocked = "UNLOCKED" )
const ( Security = "SECURITY" SoftwareHealth = "SW_HEALTH" HardwareHealth = "HW_HEALTH" )
const ( Rest = "REST" Email = "EMAIL" )
const ( Up = "UP" Down = "DOWN" Unknown = "UNKNOWN" )
Up : UP Down : DOWN Unknown : UNKNOWN
const ( // Base64Encoding : the float value is represented in Base64 encoding Base64Encoding = "Base64" // ENotation : the float value is represented in eNotation ENotation = "eNotation" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AdminState ¶
type AdminState string
AdminState controls the range of values which constitute valid administrative states for a device
type AutoEvent ¶
AutoEvent and its properties are defined in the APIv2 specification: https://app.swaggerhub.com/apis-docs/EdgeXFoundry1/core-metadata/2.x#/AutoEvent Model fields are same as the DTOs documented by this swagger. Exceptions, if any, are noted below.
type BaseReading ¶
type BaseReading struct {
Id string
Created int64
Origin int64
DeviceName string
ResourceName string
ProfileName string
ValueType string
}
BaseReading and its properties are defined in the APIv2 specification: https://app.swaggerhub.com/apis-docs/EdgeXFoundry1/core-data/2.x#/BaseReading Model fields are same as the DTOs documented by this swagger. Exceptions, if any, are noted below.
type BinaryReading ¶
type BinaryReading struct {
BaseReading `json:",inline"`
BinaryValue []byte
MediaType string
}
BinaryReading and its properties are defined in the APIv2 specification: https://app.swaggerhub.com/apis-docs/EdgeXFoundry1/core-data/2.x#/BinaryReading Model fields are same as the DTOs documented by this swagger. Exceptions, if any, are noted below.
func (BinaryReading) GetBaseReading ¶
func (b BinaryReading) GetBaseReading() BaseReading
Implement GetBaseReading() method in order for BinaryReading and SimpleReading structs to implement the abstract Reading interface and then be used as a Reading. Also, the Reading interface can access the BaseReading fields. This is Golang's way to implement inheritance.
type Category ¶
type Category string
ChannelType controls the range of values which constitute valid delivery types for channels
type Channel ¶
type Channel struct {
Type ChannelType
EmailAddresses []string
Url string
}
Channel and its properties are defined in the APIv2 specification: https://app.swaggerhub.com/apis-docs/EdgeXFoundry1/support-notifications/2.x#/Channel
type ChannelType ¶
type ChannelType string
ChannelType controls the range of values which constitute valid delivery types for channels
type Command ¶
Command and its properties are defined in the APIv2 specification: https://app.swaggerhub.com/apis-docs/EdgeXFoundry1/core-metadata/2.x#/Command Model fields are same as the DTOs documented by this swagger. Exceptions, if any, are noted below.
type Device ¶
type Device struct {
Timestamps
Id string
Name string
Description string
AdminState AdminState
OperatingState OperatingState
Protocols map[string]ProtocolProperties
LastConnected int64
LastReported int64
Labels []string
Location interface{}
ServiceName string
ProfileName string
AutoEvents []AutoEvent
Notify bool
}
Device and its properties are defined in the APIv2 specification: https://app.swaggerhub.com/apis-docs/EdgeXFoundry1/core-metadata/2.x#/Device Model fields are same as the DTOs documented by this swagger. Exceptions, if any, are noted below.
type DeviceCommand ¶
type DeviceCommand struct {
Name string
Get []ResourceOperation
Set []ResourceOperation
}
DeviceCommand and its properties are defined in the APIv2 specification: https://app.swaggerhub.com/apis-docs/EdgeXFoundry1/core-metadata/2.x#/DeviceCommand Model fields are same as the DTOs documented by this swagger. Exceptions, if any, are noted below.
type DeviceProfile ¶
type DeviceProfile struct {
Timestamps
Description string
Id string
Name string
Manufacturer string
Model string
Labels []string
DeviceResources []DeviceResource
DeviceCommands []DeviceCommand
CoreCommands []Command
}
DeviceProfile and its properties are defined in the APIv2 specification: https://app.swaggerhub.com/apis-docs/EdgeXFoundry1/core-metadata/2.x#/DeviceProfile Model fields are same as the DTOs documented by this swagger. Exceptions, if any, are noted below.
type DeviceResource ¶
type DeviceResource struct {
Description string
Name string
Tag string
Properties PropertyValue
Attributes map[string]string
}
DeviceResource and its properties are defined in the APIv2 specification: https://app.swaggerhub.com/apis-docs/EdgeXFoundry1/core-metadata/2.x#/DeviceResource Model fields are same as the DTOs documented by this swagger. Exceptions, if any, are noted below.
type DeviceService ¶
type DeviceService struct {
Timestamps
Id string
Name string
Description string
LastConnected int64
LastReported int64
Labels []string
BaseAddress string
AdminState AdminState
}
DeviceService and its properties are defined in the APIv2 specification: https://app.swaggerhub.com/apis-docs/EdgeXFoundry1/core-metadata/2.x#/DeviceService Model fields are same as the DTOs documented by this swagger. Exceptions, if any, are noted below.
type Event ¶
type Event struct {
Id string
DeviceName string
ProfileName string
Created int64
Origin int64
Readings []Reading
Tags map[string]string
}
Event and its properties are defined in the APIv2 specification: https://app.swaggerhub.com/apis-docs/EdgeXFoundry1/core-data/2.x#/Event Model fields are same as the DTOs documented by this swagger. Exceptions, if any, are noted below.
type Interval ¶
type Interval struct {
Timestamps
Id string
Name string
Start string
End string
Frequency string
RunOnce bool
}
Interval and its properties are defined in the APIv2 specification: https://app.swaggerhub.com/apis-docs/EdgeXFoundry1/support-scheduler/2.x#/Interval Model fields are same as the DTOs documented by this swagger. Exceptions, if any, are noted below.
type PropertyValue ¶
type PropertyValue struct {
Type string
ReadWrite string
Units string
Minimum string
Maximum string
DefaultValue string
Mask string
Shift string
Scale string
Offset string
Base string
Assertion string
MediaType string
}
PropertyValue and its properties care defined in the APIv2 specification: https://app.swaggerhub.com/apis-docs/EdgeXFoundry1/core-metadata/2.x#/PropertyValue Model fields are same as the DTOs documented by this swagger. Exceptions, if any, are noted below.
type ProtocolProperties ¶
ProtocolProperties contains the device connection information in key/value pair
type ProvisionWatcher ¶
type ProvisionWatcher struct {
Timestamps
Id string
Name string
Labels []string
Identifiers map[string]string
BlockingIdentifiers map[string][]string
ProfileName string
ServiceName string
AdminState AdminState
AutoEvents []AutoEvent
}
ProvisionWatcher and its properties are defined in the APIv2 specification: https://app.swaggerhub.com/apis-docs/EdgeXFoundry1/core-metadata/2.x#/ProvisionWatcher Model fields are same as the DTOs documented by this swagger. Exceptions, if any, are noted below.
type Reading ¶
type Reading interface {
GetBaseReading() BaseReading
}
Reading is an abstract interface to be implemented by BinaryReading/SimpleReading
type ResourceOperation ¶
ResourceOperation and its properties are defined in the APIv2 specification: https://app.swaggerhub.com/apis-docs/EdgeXFoundry1/core-metadata/2.x#/ResourceOperation Model fields are same as the DTOs documented by this swagger. Exceptions, if any, are noted below.
type SimpleReading ¶
type SimpleReading struct {
BaseReading `json:",inline"`
Value string
}
SimpleReading and its properties are defined in the APIv2 specification: https://app.swaggerhub.com/apis-docs/EdgeXFoundry1/core-data/2.x#/SimpleReading Model fields are same as the DTOs documented by this swagger. Exceptions, if any, are noted below.
func (SimpleReading) GetBaseReading ¶
func (s SimpleReading) GetBaseReading() BaseReading
type Subscription ¶
type Subscription struct {
Timestamps
Categories []Category
Labels []string
Channels []Channel
Created int64
Modified int64
Description string
Id string
Receiver string
Name string
ResendLimit int64
ResendInterval string
}
Subscription and its properties are defined in the APIv2 specification: https://app.swaggerhub.com/apis-docs/EdgeXFoundry1/support-notifications/2.x#/Subscription Model fields are same as the DTOs documented by this swagger. Exceptions, if any, are noted below.