Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AlreadyInitCheck ¶
func RegisterPlugin ¶
func RegisterPlugin(plg IptbPlugin, force bool) (bool, error)
RegisterPlugin registers a plugin, the `force` flag can be passed to override any plugin registered under the same IptbPlugin.PluginName
func WriteNodeSpecs ¶
Types ¶
type BasicTestbed ¶
type BasicTestbed struct {
// contains filtered or unexported fields
}
func NewTestbed ¶
func NewTestbed(dir string) BasicTestbed
func (*BasicTestbed) Dir ¶
func (tb *BasicTestbed) Dir() string
func (BasicTestbed) Name ¶
func (tb BasicTestbed) Name() string
func (*BasicTestbed) Specs ¶
func (tb *BasicTestbed) Specs() ([]*NodeSpec, error)
type IptbPlugin ¶
type IptbPlugin struct { From string NewNode testbedi.NewNodeFunc GetAttrList testbedi.GetAttrListFunc GetAttrDesc testbedi.GetAttrDescFunc PluginName string BuiltIn bool }
IptbPlugin contains exported symbols from loaded plugins
func GetPlugin ¶
func GetPlugin(name string) (IptbPlugin, bool)
GetPlugin returns a plugin registered with RegisterPlugin
func LoadPlugin ¶
func LoadPlugin(path string) (*IptbPlugin, error)
LoadPlugin loads a plugin from `path`
type NodeSpec ¶
NodeSpec represents a node's specification
func BuildSpecs ¶
func ReadNodeSpecs ¶
type Testbed ¶
type Testbed interface { Name() string // Spec returns a spec for node n Spec(n int) (*NodeSpec, error) // Specs returns all specs Specs() ([]*NodeSpec, error) // Node returns node n, specified by spec n Node(n int) (testbedi.Core, error) // Node returns all nodes, specified by all specs Nodes() ([]testbedi.Core, error) }
Click to show internal directories.
Click to hide internal directories.