Debian Codegraph @

kasa/system.go

raw symbols SCIP
1 package kasascip-go gomod github.com/fffonion/tplink-plug-exporter . `github.com/fffonion/tplink-plug-exporter/kasa`/
2
3 import "stringsscip-go gomod github.com/golang/go/src go1.18 strings/"
4
5 type KasaClientSystemServicescip-go gomod github.com/fffonion/tplink-plug-exporter . `github.com/fffonion/tplink-plug-exporter/kasa`/KasaClientSystemService# struct {
6 cscip-go gomod github.com/fffonion/tplink-plug-exporter . `github.com/fffonion/tplink-plug-exporter/kasa`/KasaClientSystemService#c. *KasaClientscip-go gomod github.com/fffonion/tplink-plug-exporter . `github.com/fffonion/tplink-plug-exporter/kasa`/KasaClient#
7 ctxscip-go gomod github.com/fffonion/tplink-plug-exporter . `github.com/fffonion/tplink-plug-exporter/kasa`/KasaClientSystemService#ctx. *KasaRequestContextscip-go gomod github.com/fffonion/tplink-plug-exporter . `github.com/fffonion/tplink-plug-exporter/kasa`/KasaRequestContext#
8 }
9
10 type GetSysInfoRequestscip-go gomod github.com/fffonion/tplink-plug-exporter . `github.com/fffonion/tplink-plug-exporter/kasa`/GetSysInfoRequest# struct {
11 }
12
13 type SysInfoChildrenscip-go gomod github.com/fffonion/tplink-plug-exporter . `github.com/fffonion/tplink-plug-exporter/kasa`/SysInfoChildren# struct {
14 IDscip-go gomod github.com/fffonion/tplink-plug-exporter . `github.com/fffonion/tplink-plug-exporter/kasa`/SysInfoChildren#ID. string `mapstructure:"id"`
15 Statescip-go gomod github.com/fffonion/tplink-plug-exporter . `github.com/fffonion/tplink-plug-exporter/kasa`/SysInfoChildren#State. int `mapstructure:"state"`
16 Aliasscip-go gomod github.com/fffonion/tplink-plug-exporter . `github.com/fffonion/tplink-plug-exporter/kasa`/SysInfoChildren#Alias. string `mapstructure:"alias"`
17 OnTimescip-go gomod github.com/fffonion/tplink-plug-exporter . `github.com/fffonion/tplink-plug-exporter/kasa`/SysInfoChildren#OnTime. int `mapstructure:"on_time"`
18 }
19
20 type GetSysInfoResponsescip-go gomod github.com/fffonion/tplink-plug-exporter . `github.com/fffonion/tplink-plug-exporter/kasa`/GetSysInfoResponse# struct {
21 MACscip-go gomod github.com/fffonion/tplink-plug-exporter . `github.com/fffonion/tplink-plug-exporter/kasa`/GetSysInfoResponse#MAC. string `mapstructure:"mac"`
22 Modelscip-go gomod github.com/fffonion/tplink-plug-exporter . `github.com/fffonion/tplink-plug-exporter/kasa`/GetSysInfoResponse#Model. string `mapstructure:"model"`
23 Aliasscip-go gomod github.com/fffonion/tplink-plug-exporter . `github.com/fffonion/tplink-plug-exporter/kasa`/GetSysInfoResponse#Alias. string `mapstructure:"alias"`
24 Featurescip-go gomod github.com/fffonion/tplink-plug-exporter . `github.com/fffonion/tplink-plug-exporter/kasa`/GetSysInfoResponse#Feature. string `mapstructure:"feature"`
25 RelayStatescip-go gomod github.com/fffonion/tplink-plug-exporter . `github.com/fffonion/tplink-plug-exporter/kasa`/GetSysInfoResponse#RelayState. int `mapstructure:"relay_state"`
26 RSSIscip-go gomod github.com/fffonion/tplink-plug-exporter . `github.com/fffonion/tplink-plug-exporter/kasa`/GetSysInfoResponse#RSSI. int `mapstructure:"rssi"`
27 LEDOffscip-go gomod github.com/fffonion/tplink-plug-exporter . `github.com/fffonion/tplink-plug-exporter/kasa`/GetSysInfoResponse#LEDOff. int `mapstructure:"led_off"`
28 OnTimescip-go gomod github.com/fffonion/tplink-plug-exporter . `github.com/fffonion/tplink-plug-exporter/kasa`/GetSysInfoResponse#OnTime. int `mapstructure:"on_time"`
29 DeviceIDscip-go gomod github.com/fffonion/tplink-plug-exporter . `github.com/fffonion/tplink-plug-exporter/kasa`/GetSysInfoResponse#DeviceID. string `mapstructure:"deviceId"`
30 SoftwareVersionscip-go gomod github.com/fffonion/tplink-plug-exporter . `github.com/fffonion/tplink-plug-exporter/kasa`/GetSysInfoResponse#SoftwareVersion. string `mapstructure:"sw_ver"`
31 HardwareVersionscip-go gomod github.com/fffonion/tplink-plug-exporter . `github.com/fffonion/tplink-plug-exporter/kasa`/GetSysInfoResponse#HardwareVersion. string `mapstructure:"hw_ver"`
32 Childrenscip-go gomod github.com/fffonion/tplink-plug-exporter . `github.com/fffonion/tplink-plug-exporter/kasa`/GetSysInfoResponse#Children. []SysInfoChildrenscip-go gomod github.com/fffonion/tplink-plug-exporter . `github.com/fffonion/tplink-plug-exporter/kasa`/SysInfoChildren# `mapstructure:"children"`
33 }
34
35 func (s *KasaClientSystemServicescip-go gomod github.com/fffonion/tplink-plug-exporter . `github.com/fffonion/tplink-plug-exporter/kasa`/KasaClientSystemService#) GetSysInfoscip-go gomod github.com/fffonion/tplink-plug-exporter . `github.com/fffonion/tplink-plug-exporter/kasa`/KasaClientSystemService#GetSysInfo().() (*GetSysInfoResponsescip-go gomod github.com/fffonion/tplink-plug-exporter . `github.com/fffonion/tplink-plug-exporter/kasa`/GetSysInfoResponse#, error) {
36 var response GetSysInfoResponsescip-go gomod github.com/fffonion/tplink-plug-exporter . `github.com/fffonion/tplink-plug-exporter/kasa`/GetSysInfoResponse#
37 err := s.cscip-go gomod github.com/fffonion/tplink-plug-exporter . `github.com/fffonion/tplink-plug-exporter/kasa`/KasaClientSystemService#c..RPCscip-go gomod github.com/fffonion/tplink-plug-exporter . `github.com/fffonion/tplink-plug-exporter/kasa`/KasaClient#RPC().("system", "get_sysinfo", s.ctxscip-go gomod github.com/fffonion/tplink-plug-exporter . `github.com/fffonion/tplink-plug-exporter/kasa`/KasaClientSystemService#ctx., GetSysInfoRequestscip-go gomod github.com/fffonion/tplink-plug-exporter . `github.com/fffonion/tplink-plug-exporter/kasa`/GetSysInfoRequest#{}, &response)
38
39 return &response, err
40 }
41
42 func (s *KasaClientSystemServicescip-go gomod github.com/fffonion/tplink-plug-exporter . `github.com/fffonion/tplink-plug-exporter/kasa`/KasaClientSystemService#) EmeterSupportedscip-go gomod github.com/fffonion/tplink-plug-exporter . `github.com/fffonion/tplink-plug-exporter/kasa`/KasaClientSystemService#EmeterSupported().(r *GetSysInfoResponsescip-go gomod github.com/fffonion/tplink-plug-exporter . `github.com/fffonion/tplink-plug-exporter/kasa`/GetSysInfoResponse#) bool {
43 return stringsscip-go gomod github.com/golang/go/src go1.18 strings/.Containsscip-go gomod github.com/golang/go/src go1.18 strings/Contains().(r.Featurescip-go gomod github.com/fffonion/tplink-plug-exporter . `github.com/fffonion/tplink-plug-exporter/kasa`/GetSysInfoResponse#Feature., "ENE")
44 }