cccontrolclient

package
v0.0.0-...-1f51d05 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 21, 2024 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NatsReceive

func NatsReceive(m *nats.Msg) []lp.CCMetric

Types

type CCControlClient

type CCControlClient interface {
	Init(server_ip string, server_port int, input_subject, output_subject string) error
	GetControls(hostname string) (CCControlList, error)
	GetTopology(hostname string) (CCControlTopology, error)
	GetControlValue(hostname, control string, device string, deviceID string) (string, error)
	SetControlValue(hostname, control string, device string, deviceID string, value string) error
	Close()
}

func NewCCControlClient

func NewCCControlClient(server_ip string, server_port int, input_subject, output_subject string) (CCControlClient, error)

type CCControlList

type CCControlList struct {
	Controls []CCControlListEntry `json:"controls"`
}

type CCControlListEntry

type CCControlListEntry struct {
	Category    string `json:"category"`
	Name        string `json:"name"`
	DeviceType  string `json:"device_type"`
	Description string `json:"description"`
	Methods     string `json:"methods"`
}

type CCControlTopology

type CCControlTopology struct {
	HWthreads []topo.HwthreadEntry `json:"hwthreads"`
	CpuInfo   topo.CpuInformation  `json:"cpu_info"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL