models

package
v0.0.0-...-682ebcb Latest Latest
Warning

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

Go to latest
Published: Jul 3, 2023 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DHCPOptions

type DHCPOptions struct {
	// contains filtered or unexported fields
}

func NewDHCPOptions

func NewDHCPOptions(uuid string, db ovn.DB) *DHCPOptions

func (*DHCPOptions) CIDR

func (d *DHCPOptions) CIDR() *netip.Prefix

func (*DHCPOptions) DnsServers

func (d *DHCPOptions) DnsServers() []netip.Addr

func (*DHCPOptions) Invalidate

func (d *DHCPOptions) Invalidate()

func (*DHCPOptions) LeaseTime

func (d *DHCPOptions) LeaseTime() uint

func (*DHCPOptions) Mtu

func (d *DHCPOptions) Mtu() uint

func (*DHCPOptions) Router

func (d *DHCPOptions) Router() *netip.Addr

func (*DHCPOptions) Routes

func (d *DHCPOptions) Routes() []Route

func (*DHCPOptions) ServerIP

func (d *DHCPOptions) ServerIP() *netip.Addr

func (*DHCPOptions) ServerMac

func (d *DHCPOptions) ServerMac() *net.HardwareAddr

type DHCPZone

type DHCPZone struct {
	Opts  *DHCPOptions
	Addrs []*PortAddress
}

type PortAddress

type PortAddress struct {
	Mac net.HardwareAddr
	Ip  netip.Addr
}

func ParsePortAddress

func ParsePortAddress(blob string) (*PortAddress, error)

type PortType

type PortType int
const (
	VIF PortType = iota
	ROUTER
	LOCALNET
	LOCALPORT
	L2GATEWAY
	VTEP
	EXTERNAL
	VIRTUAL
	REMOTE
)

func ParsePortType

func ParsePortType(s string) (PortType, error)

func (PortType) String

func (t PortType) String() string

type Route

type Route struct {
	Prefix  netip.Prefix
	NextHop netip.Addr
}

func ParseRoute

func ParseRoute(blob string) (Route, error)

func (*Route) String

func (r *Route) String() string

type Switch

type Switch struct {
	// contains filtered or unexported fields
}

func NewSwitch

func NewSwitch(uuid string, db ovn.DB) *Switch

func (*Switch) Invalidate

func (sw *Switch) Invalidate()

func (*Switch) MTU

func (sw *Switch) MTU() uint

func (*Switch) McastSnoop

func (sw *Switch) McastSnoop() bool

func (*Switch) Name

func (sw *Switch) Name() string

func (*Switch) Ports

func (sw *Switch) Ports() []*SwitchPort

func (*Switch) VlanPassthru

func (sw *Switch) VlanPassthru() bool

type SwitchPort

type SwitchPort struct {
	// contains filtered or unexported fields
}

func NewSwitchPort

func NewSwitchPort(uuid string, db ovn.DB) *SwitchPort

func (*SwitchPort) Addresses

func (p *SwitchPort) Addresses() []*PortAddress

func (*SwitchPort) DHCPOptions

func (p *SwitchPort) DHCPOptions() []*DHCPOptions

func (*SwitchPort) Invalidate

func (p *SwitchPort) Invalidate()

func (*SwitchPort) Name

func (p *SwitchPort) Name() string

func (*SwitchPort) NetworkName

func (p *SwitchPort) NetworkName() string

func (*SwitchPort) Tag

func (p *SwitchPort) Tag() uint

func (*SwitchPort) Type

func (p *SwitchPort) Type() PortType

Jump to

Keyboard shortcuts

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