Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Api ¶
type Api interface { PortsStats() ([]PortStats, error) PortsSettings() ([]PortSettings, error) CreateBackup() ([]byte, error) Login() }
Defines the api operations
type Client ¶
type Client struct { Api Host string Username string Password string // contains filtered or unexported fields }
func (*Client) CreateBackup ¶
creates a backup of the connected device
func (*Client) PortsSettings ¶
func (t *Client) PortsSettings() ([]PortSettings, error)
get port settings and info
func (*Client) SystemInfo ¶
func (t *Client) SystemInfo() (*SystemInfo, error)
retrieve switch system information
type LinkStatus ¶
type LinkStatus int64
const ( LinkDown LinkStatus = 0 Auto LinkStatus = 1 At10MH LinkStatus = 2 At10MF LinkStatus = 3 At100MH LinkStatus = 4 At100MF LinkStatus = 5 At1000MF LinkStatus = 6 )
func (LinkStatus) String ¶
func (s LinkStatus) String() string
type PortSettings ¶
type PortSettings struct { Name string State PortStatus TrunkInfo int SpeedCfg LinkStatus SpeedAct LinkStatus FlowCtrlCfg OnOff FlowCtrlAct OnOff }
Ports Settings
type PortStats ¶
type PortStats struct { Name string State PortStatus LinkStatus LinkStatus TxGoodPkt int TxBadPkt int RxGoodPkt int RxBadPkt int }
type PortStatus ¶
type PortStatus int64
const ( PortDisabled PortStatus = 0 PortEnabled PortStatus = 1 )
func (PortStatus) String ¶
func (s PortStatus) String() string
Source Files
¶
Click to show internal directories.
Click to hide internal directories.