Move deps from _workspace/ to vendor/
godep restore pushd $GOPATH/src/github.com/appc/spec git co master popd go get go4.org/errorutil rm -rf Godeps godep save ./... git add vendor git add -f $(git ls-files --other vendor/) git co -- Godeps/LICENSES Godeps/.license_file_state Godeps/OWNERS
This commit is contained in:
35
vendor/github.com/vishvananda/netlink/route.go
generated
vendored
Normal file
35
vendor/github.com/vishvananda/netlink/route.go
generated
vendored
Normal file
@@ -0,0 +1,35 @@
|
||||
package netlink
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"net"
|
||||
"syscall"
|
||||
)
|
||||
|
||||
// Scope is an enum representing a route scope.
|
||||
type Scope uint8
|
||||
|
||||
const (
|
||||
SCOPE_UNIVERSE Scope = syscall.RT_SCOPE_UNIVERSE
|
||||
SCOPE_SITE Scope = syscall.RT_SCOPE_SITE
|
||||
SCOPE_LINK Scope = syscall.RT_SCOPE_LINK
|
||||
SCOPE_HOST Scope = syscall.RT_SCOPE_HOST
|
||||
SCOPE_NOWHERE Scope = syscall.RT_SCOPE_NOWHERE
|
||||
)
|
||||
|
||||
// Route represents a netlink route. A route is associated with a link,
|
||||
// has a destination network, an optional source ip, and optional
|
||||
// gateway. Advanced route parameters and non-main routing tables are
|
||||
// currently not supported.
|
||||
type Route struct {
|
||||
LinkIndex int
|
||||
Scope Scope
|
||||
Dst *net.IPNet
|
||||
Src net.IP
|
||||
Gw net.IP
|
||||
}
|
||||
|
||||
func (r Route) String() string {
|
||||
return fmt.Sprintf("{Ifindex: %d Dst: %s Src: %s Gw: %s}", r.LinkIndex, r.Dst,
|
||||
r.Src, r.Gw)
|
||||
}
|
Reference in New Issue
Block a user