Documentation ¶
Index ¶
- Constants
- func AspectsEndpoints(config config.Config, control Controller, router *httprouter.Router)
- func CharacteristicsEndpoints(config config.Config, control Controller, router *httprouter.Router)
- func ConceptsEndpoints(config config.Config, control Controller, router *httprouter.Router)
- func DeviceClassesEndpoints(config config.Config, control Controller, router *httprouter.Router)
- func DeviceGroupsEndpoints(config config.Config, control Controller, router *httprouter.Router)
- func DeviceTypesEndpoints(config config.Config, control Controller, router *httprouter.Router)
- func DevicesEndpoints(config config.Config, control Controller, router *httprouter.Router)
- func FunctionsEndpoints(config config.Config, control Controller, router *httprouter.Router)
- func HubsEndpoints(config config.Config, control Controller, router *httprouter.Router)
- func LocalDevicesEndpoints(config config.Config, control Controller, router *httprouter.Router)
- func LocationsEndpoints(config config.Config, control Controller, router *httprouter.Router)
- func ProtocolsEndpoints(config config.Config, control Controller, router *httprouter.Router)
- func Start(config config.Config, control Controller) (srv *http.Server, err error)
- type Controller
Constants ¶
View Source
const UpdateOnlySameOriginAttributesKey = "update-only-same-origin-attributes"
Variables ¶
This section is empty.
Functions ¶
func AspectsEndpoints ¶
func AspectsEndpoints(config config.Config, control Controller, router *httprouter.Router)
func CharacteristicsEndpoints ¶
func CharacteristicsEndpoints(config config.Config, control Controller, router *httprouter.Router)
func ConceptsEndpoints ¶
func ConceptsEndpoints(config config.Config, control Controller, router *httprouter.Router)
func DeviceClassesEndpoints ¶
func DeviceClassesEndpoints(config config.Config, control Controller, router *httprouter.Router)
func DeviceGroupsEndpoints ¶
func DeviceGroupsEndpoints(config config.Config, control Controller, router *httprouter.Router)
func DeviceTypesEndpoints ¶
func DeviceTypesEndpoints(config config.Config, control Controller, router *httprouter.Router)
func DevicesEndpoints ¶
func DevicesEndpoints(config config.Config, control Controller, router *httprouter.Router)
func FunctionsEndpoints ¶
func FunctionsEndpoints(config config.Config, control Controller, router *httprouter.Router)
func HubsEndpoints ¶
func HubsEndpoints(config config.Config, control Controller, router *httprouter.Router)
func LocalDevicesEndpoints ¶
func LocalDevicesEndpoints(config config.Config, control Controller, router *httprouter.Router)
func LocationsEndpoints ¶
func LocationsEndpoints(config config.Config, control Controller, router *httprouter.Router)
func ProtocolsEndpoints ¶
func ProtocolsEndpoints(config config.Config, control Controller, router *httprouter.Router)
Types ¶
type Controller ¶
type Controller interface { ReadDeviceGroup(token auth.Token, id string) (device models.DeviceGroup, err error, code int) PublishDeviceGroupCreate(token auth.Token, dt models.DeviceGroup) (result models.DeviceGroup, err error, code int) PublishDeviceGroupUpdate(token auth.Token, id string, device models.DeviceGroup) (result models.DeviceGroup, err error, code int) PublishDeviceGroupDelete(token auth.Token, id string) (err error, code int) ReadDeviceType(token auth.Token, id string) (device models.DeviceType, err error, code int) PublishDeviceTypeCreate(token auth.Token, dt models.DeviceType) (result models.DeviceType, err error, code int) PublishDeviceTypeUpdate(token auth.Token, id string, device models.DeviceType) (result models.DeviceType, err error, code int) PublishDeviceTypeDelete(token auth.Token, id string) (err error, code int) ReadDevice(token auth.Token, id string) (device models.Device, err error, code int) PublishDeviceCreate(token auth.Token, dt models.Device) (result models.Device, err error, code int) PublishDeviceUpdate(token auth.Token, id string, device models.Device, options model.DeviceUpdateOptions) (result models.Device, err error, code int) PublishDeviceDelete(token auth.Token, id string) (err error, code int) ReadHub(token auth.Token, id string) (hub models.Hub, err error, code int) PublishHubCreate(token auth.Token, dt models.HubEdit) (result models.Hub, err error, code int) PublishHubUpdate(token auth.Token, id string, userId string, hub models.HubEdit) (result models.Hub, err error, code int) PublishHubDelete(token auth.Token, id string) (err error, code int) ReadProtocol(token auth.Token, id string) (device models.Protocol, err error, code int) PublishProtocolCreate(token auth.Token, dt models.Protocol) (result models.Protocol, err error, code int) PublishProtocolUpdate(token auth.Token, id string, device models.Protocol) (result models.Protocol, err error, code int) PublishProtocolDelete(token auth.Token, id string) (err error, code int) ReadConcept(token auth.Token, id string) (device models.Concept, err error, code int) PublishConceptCreate(token auth.Token, concept models.Concept) (result models.Concept, err error, code int) PublishConceptUpdate(token auth.Token, id string, concept models.Concept) (result models.Concept, err error, code int) PublishConceptDelete(token auth.Token, id string) (err error, code int) PublishCharacteristicCreate(token auth.Token, characteristic models.Characteristic) (result models.Characteristic, err error, code int) PublishCharacteristicUpdate(token auth.Token, characteristicId string, characteristic models.Characteristic) (result models.Characteristic, err error, code int) PublishCharacteristicDelete(token auth.Token, id string) (err error, code int) ReadCharacteristic(token auth.Token, id string) (result models.Characteristic, err error, code int) DeviceLocalIdToId(token auth.Token, localId string) (id string, err error, errCode int) ReadAspect(token auth.Token, id string) (device models.Aspect, err error, code int) PublishAspectCreate(token auth.Token, dt models.Aspect) (result models.Aspect, err error, code int) PublishAspectUpdate(token auth.Token, id string, device models.Aspect) (result models.Aspect, err error, code int) PublishAspectDelete(token auth.Token, id string) (err error, code int) ReadFunction(token auth.Token, id string) (device models.Function, err error, code int) PublishFunctionCreate(token auth.Token, dt models.Function) (result models.Function, err error, code int) PublishFunctionUpdate(token auth.Token, id string, device models.Function) (result models.Function, err error, code int) PublishFunctionDelete(token auth.Token, id string) (err error, code int) ReadDeviceClass(token auth.Token, id string) (device models.DeviceClass, err error, code int) PublishDeviceClassCreate(token auth.Token, dt models.DeviceClass) (result models.DeviceClass, err error, code int) PublishDeviceClassUpdate(token auth.Token, id string, device models.DeviceClass) (result models.DeviceClass, err error, code int) PublishDeviceClassDelete(token auth.Token, id string) (err error, code int) ReadLocation(token auth.Token, id string) (device models.Location, err error, code int) PublishLocationCreate(token auth.Token, dt models.Location) (result models.Location, err error, code int) PublishLocationUpdate(token auth.Token, id string, device models.Location) (result models.Location, err error, code int) PublishLocationDelete(token auth.Token, id string) (err error, code int) ValidateDistinctDeviceTypeAttributes(token auth.Token, devicetype models.DeviceType, attributeKeys []string) error }
Source Files ¶
Click to show internal directories.
Click to hide internal directories.