Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
Client is a Siteinfo client.
func New ¶
func New(projectID, version string, httpClient HTTPProvider) *Client
New returns a new Siteinfo client wrapping the provided *http.Client.
func (Client) Machines ¶ added in v0.1.45
Machines fetches the sites/machines.json output format and returns its content as a []Machine.
func (Client) Projects ¶ added in v0.1.45
Projects fetches the sites/projects.json output format and returns its content as a map[<short-node-name>]string.
func (Client) SiteMachines ¶ added in v0.1.49
SiteMachines fetches the sites/site-machines.json output format and returns its content as a map[<short-node-name>][]string.
type HTTPProvider ¶
HTTPProvider is a data provider returning HTTP responses. http.Client satisfies this interface.
type Switch ¶
type Switch struct { AutoNegotiation string `json:"auto_negotation"` FlowControl string `json:"flow_control"` IPv4Prefix string `json:"ipv4_prefix"` RSTP string `json:"rstp"` SwitchMake string `json:"switch_make"` SwitchModel string `json:"switch_model"` UplinkPort string `json:"uplink_port"` UplinkSpeed string `json:"uplink_speed"` }
Switch is an entity in /v1/sites/switches.json.
Click to show internal directories.
Click to hide internal directories.