Documentation ¶
Index ¶
- func CliStart() string
- func GetFirstCliParam() string
- type Command
- func (c *Command) Execute() bool
- func (c *Command) ExecuteCommand(name string, args []string, asyncCount int, relativeCount int) bool
- func (c *Command) ListenForFinish(callback func())
- func (c *Command) ListenForInit(callback func(count int))
- func (c *Command) ListenForProgress(callback func())
- func (c *Command) SetManualCallback(callback func(command string))
- type Task
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CliStart ¶ added in v0.0.2
func CliStart() string
*
- Returns string from cli to start
- asink *
- @return String config file name
func GetFirstCliParam ¶ added in v0.0.2
func GetFirstCliParam() string
*
- Gets params and flags from cli
- and calls appropriate func *
- @return String
Types ¶
type Command ¶
type Command struct { Name string AsyncCount float64 RelativeCount float64 Args []string Dir string Manual bool // contains filtered or unexported fields }
*
- @var string name of the command
- @var float64 number of async iterations
- @var float64 number of sync iterations
- @var []string command arguments
func New ¶
func New() *Command
*
- Acting as a constructor to
- return a new instance of
- Command *
- @return *Command
func (*Command) Execute ¶
*
- Creates the command channel and sets
- up everything ready for execution *
- @return bool
func (*Command) ExecuteCommand ¶
func (c *Command) ExecuteCommand(name string, args []string, asyncCount int, relativeCount int) bool
*
- An alias function that nicely
- interfaces the Execute function
- to make it easier to use in external Go
- programs *
- @param string the command name
- @param []string command arguments
- @param int number of async iterations
- @param int number of sync iterations *
- @return bool
func (*Command) ListenForFinish ¶
func (c *Command) ListenForFinish(callback func())
*
- An optional callback public function
- that gets called when all jobs have
- been finished *
- @param func() callback function *
- @return nil
func (*Command) ListenForInit ¶
*
- An optional callback public function
- that gets called on job creation *
- @param func(count int) callback function *
- @return nil
func (*Command) ListenForProgress ¶
func (c *Command) ListenForProgress(callback func())
*
- An optional callback public function
- that gets called everytime a job
- has finished *
- @param func() callback function *
- @return nil
func (*Command) SetManualCallback ¶ added in v0.0.2
type Task ¶ added in v0.0.2
*
- @var String task name
- @var *Command initial command
- @var String required task name
- @var String task group name
func NewTask ¶ added in v0.0.2
func NewTask() *Task
*
- Creates a new instance of the Task
- struct *
- @return *Task a new task
func (*Task) AddTask ¶ added in v0.0.2
*
- Adds a new tasks to the map *
- @param String name of task
- @param *Command the initial command
- @param String the required task to run
- @param String the group of tasks to be ran *
- @return nil
Click to show internal directories.
Click to hide internal directories.