Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var EMPTY_TUPLE = errors.New("EMPTY_TUPLE")
Functions ¶
Types ¶
type L2SWAccessConfig ¶ added in v0.4.0
func NewL2SWAccessConfig ¶ added in v0.4.0
func NewL2SWAccessConfig(eth, vid uint) *L2SWAccessConfig
func ParseL2SWAccessConfig ¶ added in v0.4.0
func ParseL2SWAccessConfig(s string) (*L2SWAccessConfig, error)
func (*L2SWAccessConfig) String ¶ added in v0.4.0
func (c *L2SWAccessConfig) String() string
type L2SWConfig ¶ added in v0.4.0
type L2SWTrunkConfig ¶ added in v0.4.0
func NewL2SWTrunkConfig ¶ added in v0.4.0
func NewL2SWTrunkConfig(eth uint, vids []uint) *L2SWTrunkConfig
func ParseL2SWTrunkConfig ¶ added in v0.4.0
func ParseL2SWTrunkConfig(s string) (*L2SWTrunkConfig, error)
func (*L2SWTrunkConfig) String ¶ added in v0.4.0
func (c *L2SWTrunkConfig) String() string
type PortConfig ¶
type PortConfig struct { Eth []uint `yaml:"eth"` Vlan []string `yaml:"vlan"` L2sw *L2SWConfig `yaml:"l2sw"` }
func NewPortConfig ¶
func NewPortConfig() *PortConfig
func (*PortConfig) Devices ¶
func (c *PortConfig) Devices() []*VlanConfig
func (*PortConfig) L2SWAccessPorts ¶ added in v0.4.0
func (c *PortConfig) L2SWAccessPorts() []*L2SWAccessConfig
func (*PortConfig) L2SWTrunkPorts ¶ added in v0.4.0
func (c *PortConfig) L2SWTrunkPorts() []*L2SWTrunkConfig
func (*PortConfig) Vlans ¶
func (c *PortConfig) Vlans() []*VlanConfig
type PortsConfig ¶
type PortsConfig struct {
Ports map[string]*PortConfig `yaml:"ports"`
}
func NewPortsConfig ¶
func NewPortsConfig() *PortsConfig
func ReadConfig ¶
func ReadConfig(path string) *PortsConfig
func (*PortsConfig) PortConfig ¶
func (c *PortsConfig) PortConfig(name string) (*PortConfig, bool)
type VlanConfig ¶
func NewVlanConfig ¶
func NewVlanConfig(eth, vid uint) *VlanConfig
func ParseVlanConfig ¶
func ParseVlanConfig(s string) (*VlanConfig, error)
func (*VlanConfig) String ¶
func (c *VlanConfig) String() string
Click to show internal directories.
Click to hide internal directories.