split

package
v0.9.10 Latest Latest
Warning

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

Go to latest
Published: May 24, 2021 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

View Source
const (
	MaxResults = 10
)

Variables

View Source
var DebugFlag bool = false
View Source
var (
	Version string
)

Functions

func Debug

func Debug(v ...interface{})

func Debugf

func Debugf(format string, v ...interface{})

func Debugln

func Debugln(v ...interface{})

func NewSplit

func NewSplit() split

func PrintTitle

func PrintTitle(title string)

Types

type Bool

type Bool int
const (
	Nil Bool = iota - 1
	False
	True
)

type IfNet

type IfNet struct {
	Name              string
	Status            string
	Multicast         bool
	Broadcast         bool
	Promisc           bool
	PointToPoint      bool
	Running           bool
	Simplex           bool
	Inet              string
	Inet6             string
	HasDefaultGateway bool
	GatewayAddress    string
}

type Isp

type Isp struct {
	Query         string  `json:"query"`
	Status        string  `json:"status"`
	Continent     string  `json:"continent"`
	ContinentCode string  `json:"continentCode"`
	Country       string  `json:"country"`
	CountryCode   string  `json:"countryCode"`
	Region        string  `json:"region"`
	RegionName    string  `json:"regionName"`
	City          string  `json:"city"`
	District      string  `json:"district"`
	Zip           string  `json:"zip"`
	Lat           float64 `json:"lat"`
	Lon           float64 `json:"lon"`
	Timezone      string  `json:"timezone"`
	Offset        int     `json:"offset"`
	Currency      string  `json:"currency"`
	Isp           string  `json:"isp"`
	Org           string  `json:"org"`
	As            string  `json:"as"`
	Asname        string  `json:"asname"`
	Mobile        bool    `json:"mobile"`
	Proxy         bool    `json:"proxy"`
	Hosting       bool    `json:"hosting"`
}

type Response

type Response struct {
	SplitNow      bool
	Diagnose      bool
	AutomaticMode Bool
}

type Route

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

type State

type State int
const (
	NoConnected State = iota
	InternetConnected
	VpnConnected
	Connected
)

type Zone

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

func (*Zone) ActiveSince

func (z *Zone) ActiveSince() time.Time

func (*Zone) Average

func (z *Zone) Average() (time.Duration, bool)

func (*Zone) Gateway

func (z *Zone) Gateway() string

func (*Zone) Host

func (z *Zone) Host() string

func (*Zone) HttpRequest

func (z *Zone) HttpRequest() bool

func (*Zone) InterfaceName

func (z *Zone) InterfaceName() string

func (*Zone) IsDefault

func (z *Zone) IsDefault() bool

func (*Zone) Ping

func (z *Zone) Ping() error

func (*Zone) Ping2

func (z *Zone) Ping2() error

func (*Zone) Route

func (z *Zone) Route() string

func (*Zone) Time

func (z *Zone) Time() []time.Duration

Jump to

Keyboard shortcuts

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