dev.azure.com/aidainnovazione0090/DeviceManager/_git/go-mod-core-contracts@v1.0.2/models/device.go (about)

     1  //
     2  // Copyright (C) 2020-2023 IOTech Ltd
     3  //
     4  // SPDX-License-Identifier: Apache-2.0
     5  
     6  package models
     7  
     8  type Device struct {
     9  	DBTimestamp
    10  	Id             string
    11  	Name           string
    12  	Description    string
    13  	AdminState     AdminState
    14  	OperatingState OperatingState
    15  	Protocols      map[string]ProtocolProperties
    16  	Labels         []string
    17  	Location       interface{}
    18  	ServiceName    string
    19  	Serial         string
    20  	ProfileName    string
    21  	AutoEvents     []AutoEvent
    22  	Manufacturer   string
    23  	Model          string
    24  	Tags           map[string]any
    25  	Properties     map[string]any
    26  }
    27  
    28  // ProtocolProperties contains the device connection information in key/value pair
    29  type ProtocolProperties map[string]any
    30  
    31  // AdminState controls the range of values which constitute valid administrative states for a device
    32  type AdminState string
    33  
    34  // OperatingState is an indication of the operations of the device.
    35  type OperatingState string