Documentation ¶
Index ¶
- type CLI
- type Pf9Cmd
- func (c *Pf9Cmd) RunCommand(ctx context.Context, env map[string]string, timeout int, cwd, path string, ...) (int, error)
- func (c *Pf9Cmd) RunCommandWithStdErr(ctx context.Context, env map[string]string, timeout int, cwd, path string, ...) (int, []string, error)
- func (c *Pf9Cmd) RunCommandWithStdOut(ctx context.Context, env map[string]string, timeout int, cwd, path string, ...) (int, []string, error)
- func (c *Pf9Cmd) RunCommandWithStdOutStdErr(ctx context.Context, env map[string]string, timeout int, cwd, path string, ...) (int, []string, []string, error)
- type ServiceUtil
- type ServiceUtility
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CLI ¶
type CLI interface { RunCommand(context.Context, map[string]string, int, string, string, ...string) (int, error) RunCommandWithStdOut(context.Context, map[string]string, int, string, string, ...string) (int, []string, error) RunCommandWithStdErr(context.Context, map[string]string, int, string, string, ...string) (int, []string, error) RunCommandWithStdOutStdErr(context.Context, map[string]string, int, string, string, ...string) (int, []string, []string, error) }
CLI interface contains the ways in which one can trigger commands from command line
type Pf9Cmd ¶
type Pf9Cmd struct{}
Pf9Cmd represents an encapsulated command object with bells and whistles
func (*Pf9Cmd) RunCommand ¶
func (c *Pf9Cmd) RunCommand(ctx context.Context, env map[string]string, timeout int, cwd, path string, args ...string) (int, error)
RunCommand runs a command
func (*Pf9Cmd) RunCommandWithStdErr ¶
func (c *Pf9Cmd) RunCommandWithStdErr(ctx context.Context, env map[string]string, timeout int, cwd, path string, args ...string) (int, []string, error)
RunCommandWithStdErr runs a command and prints all the contents from STDERR
func (*Pf9Cmd) RunCommandWithStdOut ¶
func (c *Pf9Cmd) RunCommandWithStdOut(ctx context.Context, env map[string]string, timeout int, cwd, path string, args ...string) (int, []string, error)
RunCommandWithStdOut runs a command and prints all the contents from STDOUT
func (*Pf9Cmd) RunCommandWithStdOutStdErr ¶
func (c *Pf9Cmd) RunCommandWithStdOutStdErr(ctx context.Context, env map[string]string, timeout int, cwd, path string, args ...string) (int, []string, []string, error)
RunCommandWithStdOutStdErr runs a command and prints all the contents from STDOUT and STDERR together
type ServiceUtil ¶
func NewServiceUtil ¶
func NewServiceUtil(name string) ServiceUtil
Click to show internal directories.
Click to hide internal directories.