Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var Handler = vpp.RegisterHandler(vpp.HandlerDesc{ Name: "core", HandlerAPI: (*VppCoreAPI)(nil), NewFunc: (*NewHandlerFunc)(nil), })
Functions ¶
func AddVersion ¶
func AddVersion(version vpp.Version, msgs []govppapi.Message, h NewHandlerFunc)
AddVersion registers vppcalls Handler for the given version.
Types ¶
type NewHandlerFunc ¶
type NewHandlerFunc func(vpp.Client) VppCoreAPI
type PluginInfo ¶
PluginInfo contains info about loaded VPP plugin.
func (PluginInfo) String ¶
func (p PluginInfo) String() string
type SessionInfo ¶
SessionInfo contains info about VPP session.
type ThreadInfo ¶ added in v3.2.0
type ThreadInfo struct { Name string ID uint32 Type string PID uint32 CPUID uint32 Core uint32 CPUSocket uint32 }
ThreadInfo wraps all thread data counters.
type VersionInfo ¶
VersionInfo contains VPP version info.
func (VersionInfo) Release ¶
func (v VersionInfo) Release() string
Release returns version in shortened format YY.MM that describes release.
type VppCoreAPI ¶
type VppCoreAPI interface { // Ping sends control ping to VPP. Ping(context.Context) error // RunCli sends CLI command to VPP. RunCli(ctx context.Context, cmd string) (string, error) // GetVersion retrieves info about VPP version. GetVersion(context.Context) (*VersionInfo, error) // GetSession retrieves info about active session. GetSession(context.Context) (*SessionInfo, error) // GetModules retrieves info about VPP API modules. GetModules(context.Context) ([]APIModule, error) // GetPlugins retrieves info about loaded VPP plugins. GetPlugins(context.Context) ([]PluginInfo, error) // GetThreads retrieves info about VPP threads. GetThreads(ctx context.Context) ([]ThreadInfo, error) }
VppCoreAPI provides methods for core VPP functionality.
func CompatibleHandler ¶
func CompatibleHandler(c vpp.Client) VppCoreAPI
CompatibleHandler is helper for returning compatible Handler.
func NewHandler ¶
func NewHandler(c vpp.Client) (VppCoreAPI, error)
Click to show internal directories.
Click to hide internal directories.