mrun

package
v0.0.0-...-52c4d39 Latest Latest
Warning

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

Go to latest
Published: May 4, 2016 License: Apache-2.0 Imports: 5 Imported by: 1

Documentation

Overview

its very interesting and simple for go main file to run all kinds funcs and runable struct. The struct should provide a Run() function.

Index

Constants

This section is empty.

Variables

View Source
var MethodMap = make(map[string]reflect.Value)

Functions

func AddFunc

func AddFunc(fn func(), args ...string)

AddFunc

func AddRunner

func AddRunner(v Runner, args ...string)

AddRunner

func AddStruct

func AddStruct(v interface{})

AddStruct

func LoopRun

func LoopRun(v Runner, args ...interface{})

run runner until C-C stop apps.

func LoopRunFunc

func LoopRunFunc(fn func())

func Main

func Main()

func Run

func Run(v Runner, args ...interface{})

Run a runner

func RunAll

func RunAll()

run all runners and funcs

func RunAllFuncs

func RunAllFuncs()

func RunAllMethods

func RunAllMethods()

func RunAllRunners

func RunAllRunners()

func RunFunc

func RunFunc(fn func())

func RunFuncWithKey

func RunFuncWithKey(key string)

func RunKey

func RunKey(key string)

func RunMethod

func RunMethod(name string)

func ShowHelp

func ShowHelp()

func ShowMenu

func ShowMenu()

func ShowRunFuncs

func ShowRunFuncs()

func ShowRunMethods

func ShowRunMethods()

func ShowRunners

func ShowRunners()

func TimesRun

func TimesRun(v Runner, times int, args ...interface{})

run runer for specific times

func TimesRunFunc

func TimesRunFunc(fn func(), times int)

Types

type Runner

type Runner interface {
	Run()
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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