Documentation
¶
Index ¶
- func ParseCodes(fields []string) ([]string, int)
- func ParseMetric(s string) (int, int)
- func RawCall(url string, cmds []string, format string) []byte
- type EosNode
- func (e *EosNode) Call(cmds []string) (JsonRpcResponse, error)
- func (e *EosNode) CapiUrl() string
- func (e *EosNode) ShowInterfaces(intf string) (ShowInterfacesResponse, error)
- func (e *EosNode) ShowLldpNeighbors() (ShowLldpNeighbors, error)
- func (e *EosNode) ShowVlan(intf string) (ShowVlanResponse, error)
- type EthInterfaceCounters
- type Flow
- type Interface
- type InterfaceAddress
- type InterfaceNames
- type InterfaceStatistics
- type IpAddress
- type JsonRpcResponse
- type JsonRpcResponseInterface
- type LldpNeighbor
- type NextHop
- type OpenstackNetworks
- type OpenstackRegion
- type Parameters
- type PhysicalInputErrors
- type PhysicalOutputErrors
- type RawJsonRpcResponse
- type Request
- type Route
- type ShowDirectFlowFlows
- type ShowInterfaces
- type ShowInterfacesResponse
- type ShowLldpNeighbors
- type ShowLldpNeighborsResponse
- type ShowVersion
- type ShowVlan
- type ShowVlanResponse
- type VlanInfo
- type VlanProperty
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ParseCodes ¶
func ParseMetric ¶
Types ¶
type EosNode ¶
func (*EosNode) ShowInterfaces ¶
func (e *EosNode) ShowInterfaces(intf string) (ShowInterfacesResponse, error)
func (*EosNode) ShowLldpNeighbors ¶
func (e *EosNode) ShowLldpNeighbors() (ShowLldpNeighbors, error)
type EthInterfaceCounters ¶
type EthInterfaceCounters struct {
CounterRefreshTime float64
InBroadcastPkts int
InDiscards int
InMulticastPkts int
InOctets int
InUcastPkts int
InputErrorsDetail PhysicalInputErrors
LastClear float64
LinkStatusChanges int
OutBroadcastPkts int
OutDiscards int
OutMulticastPkts int
OutOctets int
OutUcastPkts int
OutErrorsDetail PhysicalOutputErrors
TotalInErrors int
TotalOutErrors int
}
type Interface ¶
type Interface struct {
Bandwidth int
BurnedInAddress string
Description string //`json:"description"`
ForwardingModel string
Hardware string
InterfaceAddress []InterfaceAddress
InterfaceCounters EthInterfaceCounters
InterfaceMembership string
InterfaceStatistics InterfaceStatistics
InterfaceStatus string
L2Mtu int
LastStatusChangeTimestamp float64
LineProtocolStatus string
Mtu int
Name string
PhysicalAddress string
}
todo: account for different interface types, this is specific to Eth
type InterfaceAddress ¶
type InterfaceNames ¶
type InterfaceNames struct {
NameVlan map[string]VlanProperty
}
type InterfaceStatistics ¶
type JsonRpcResponse ¶
type LldpNeighbor ¶
type NextHop ¶
func ParseNextHop ¶
type OpenstackNetworks ¶
type OpenstackNetworks struct {
Regions map[string]OpenstackRegion
Neighbors interface{}
Hosts interface{}
}
type OpenstackRegion ¶
type OpenstackRegion struct {
Tenants interface{}
ServiceEndPoints interface{}
RegionName string
}
type Parameters ¶
type PhysicalInputErrors ¶
type PhysicalOutputErrors ¶
type RawJsonRpcResponse ¶
type RawJsonRpcResponse struct {
Jsonrpc string `json:"jsonrpc"`
Result []json.RawMessage `json:"result"`
Error map[string]interface{} `json:"error"`
Id string `json:"id"`
}
type Request ¶
type Request struct {
Jsonrpc string `json:"jsonrpc"`
Method string `json:"method"`
Params Parameters `json:"params"`
Id string `json:"id"`
}
type ShowDirectFlowFlows ¶
type ShowDirectFlowFlows struct {
Flows []Flow
}
type ShowInterfaces ¶
TODO: May need to replace Interface with a generic interface
type ShowInterfacesResponse ¶
type ShowInterfacesResponse struct {
Jsonrpc string
Result []ShowInterfaces
Error map[string]interface{}
Id string
}
func CallShowInterfaces ¶
func CallShowInterfaces(url, intf string) ShowInterfacesResponse
type ShowLldpNeighbors ¶
type ShowLldpNeighbors struct {
TablesDeletes int `json:"tablesDeletes"`
TablesAgeOuts int `json:"tablesAgeOuts"`
TablesDrops int `json:"tablesDrops"`
TablesInserts int `json:"tablesInserts"`
TablesLastChangeTime float64 `json:"tablesLastChangeTime"`
LldpNeighbors []LldpNeighbor `json:"lldpNeighbors"`
}
func CallShowLldpNeighbors ¶
func CallShowLldpNeighbors(url string) ShowLldpNeighbors
type ShowLldpNeighborsResponse ¶
type ShowLldpNeighborsResponse struct {
Jsonrpc string
Result []ShowLldpNeighbors
Error map[string]interface{}
Id string
}
type ShowVersion ¶
type ShowVersion struct {
ModelName string `json:"modelName"`
InternalVersion string `json:"internalVersion"`
SystemMacAddress string `json:"systemMacAddress"`
SerialNumber string `json:"serialNumber"`
MemTotal float64 `json:"memTotal"`
BootupTimestap float64 `json:"bootupTimestamp"`
MemFree float64 `json:"memFree"`
Version string `json:"version"`
Architecture string `json:"architecture"`
InternalBuildId string `json:"internalBuildId"`
HardwareRevision string `json:"hardwareRevision"`
}
type ShowVlanResponse ¶
type ShowVlanResponse struct {
Jsonrpc string
Result []ShowVlan
Error map[string]interface{}
Id string
}
func CallShowVlan ¶
func CallShowVlan(url, intf string) ShowVlanResponse
type VlanInfo ¶
type VlanInfo struct {
Status string `json:"status"`
Name string `json:"name"`
Interfaces map[string]InterfaceNames `json:"interfaces"`
Dynamic bool `json:"dynamic"`
}
type VlanProperty ¶
Click to show internal directories.
Click to hide internal directories.