Documentation ¶
Index ¶
- Constants
- Variables
- func AddFileCmd(dir, key string)
- func AddRender(key string, render func(*Message, string, ...interface{}) string)
- func Display(file string, arg ...string) map[string]string
- func DisplayBase(file string, arg ...string) map[string]string
- func DisplayLocal(file string, arg ...string) map[string]string
- func DisplayRequire(n int, file string, arg ...string) map[string]string
- func DisplayStory(file string, arg ...string) map[string]string
- func FileCmd(dir string) string
- func FileRequire(n int) string
- func FileURI(dir string) string
- func GetFileCmd(dir string) string
- func MergeAction(list ...interface{}) map[string]*Action
- func Render(m *Message, cmd string, args ...interface{}) string
- func Run(arg ...string) string
- func SelectAction(list map[string]*Action, fields ...string) map[string]*Action
- type Action
- type ActionHandler
- type Cache
- type Command
- type CommandHandler
- type Config
- type Context
- func (c *Context) Begin(m *Message, arg ...string) *Context
- func (c *Context) Cap(key string, arg ...interface{}) string
- func (c *Context) Close(m *Message, arg ...string) bool
- func (c *Context) Cmd(m *Message, key string, arg ...string) *Message
- func (c *Context) ID() int32
- func (c *Context) Merge(s *Context) *Context
- func (c *Context) Register(s *Context, x Server, n ...string) *Context
- func (c *Context) Server() Server
- func (c *Context) Spawn(m *Message, name string, help string, arg ...string) *Context
- func (c *Context) Start(m *Message, arg ...string) bool
- type Frame
- type MakeInfo
- type Message
- func (m *Message) Action(arg ...interface{}) *Message
- func (m *Message) ActionKey() string
- func (m *Message) Add(key string, arg ...string) *Message
- func (m *Message) Append(key string, arg ...interface{}) string
- func (m *Message) AppendSimple(key ...string) (res []string)
- func (m *Message) AppendTrans(cb func(value string, key string, index int) string) *Message
- func (m *Message) Appendv(key string, arg ...interface{}) []string
- func (m *Message) Assert(expr interface{}) bool
- func (m *Message) Back(res *Message) *Message
- func (m *Message) CSV(text string, head ...string) *Message
- func (m *Message) Call(sync bool, cb func(*Message) *Message) *Message
- func (m *Message) Cap(arg ...interface{}) string
- func (m *Message) Capi(key string, val ...interface{}) int
- func (m *Message) Capv(arg ...interface{}) interface{}
- func (m *Message) Cmd(arg ...interface{}) *Message
- func (m *Message) Cmds(arg ...interface{}) *Message
- func (m *Message) Cmdx(arg ...interface{}) string
- func (m *Message) Cmdy(arg ...interface{}) *Message
- func (m *Message) CommandKey() string
- func (m *Message) Conf(arg ...interface{}) string
- func (m *Message) Confi(key string, sub string) int
- func (m *Message) Config(key string, arg ...interface{}) string
- func (m *Message) ConfigOption(key ...string)
- func (m *Message) ConfigSimple(key ...string) (list []string)
- func (m *Message) Configm(key string, arg ...interface{}) map[string]interface{}
- func (m *Message) Configv(key string, arg ...interface{}) interface{}
- func (m *Message) Confm(key string, sub interface{}, cbs ...interface{}) map[string]interface{}
- func (m *Message) Confv(arg ...interface{}) (val interface{})
- func (m *Message) Copy(msg *Message, arg ...string) *Message
- func (m *Message) Cost(arg ...interface{}) *Message
- func (m *Message) Cut(fields ...string) *Message
- func (m *Message) Debug(str string, arg ...interface{})
- func (m *Message) Detail(arg ...interface{}) string
- func (m *Message) Detailv(arg ...interface{}) []string
- func (m *Message) Display(file string, arg ...interface{}) *Message
- func (m *Message) DisplayBase(file string, arg ...interface{}) *Message
- func (m *Message) DisplayLocal(file string, arg ...interface{}) *Message
- func (m *Message) DisplayStory(file string, arg ...interface{}) *Message
- func (m *Message) DisplayStoryJSON(arg ...interface{}) *Message
- func (m *Message) Done(ok bool) bool
- func (m *Message) Echo(str string, arg ...interface{}) *Message
- func (m *Message) EchoAnchor(arg ...interface{}) *Message
- func (m *Message) EchoButton(arg ...interface{}) *Message
- func (m *Message) EchoDownload(arg ...interface{}) *Message
- func (m *Message) EchoIFrame(src string, arg ...string) *Message
- func (m *Message) EchoImages(src string, arg ...string) *Message
- func (m *Message) EchoQRCode(src string, arg ...string) *Message
- func (m *Message) EchoScript(arg ...string) *Message
- func (m *Message) EchoVideos(src string, arg ...string) *Message
- func (m *Message) Error(err bool, str string, arg ...interface{}) bool
- func (m *Message) Event(key string, arg ...string) *Message
- func (m *Message) Fields(length int, fields ...string) string
- func (m *Message) FieldsIsDetail() bool
- func (m *Message) FormatChain() string
- func (m *Message) FormatCost() string
- func (m *Message) FormatMeta() string
- func (m *Message) FormatPrefix() string
- func (m *Message) FormatShip() string
- func (m *Message) FormatSize() string
- func (m *Message) FormatStack() string
- func (m *Message) FormatTime() string
- func (m *Message) FormatsMeta() string
- func (m *Message) Go(cb interface{}) *Message
- func (m *Message) GoToast(title string, cb func(toast func(string, int, int)))
- func (m *Message) Grow(prefix string, chain interface{}, data interface{}) int
- func (m *Message) Grows(prefix string, chain interface{}, match string, value string, cb interface{}) map[string]interface{}
- func (m *Message) Hold(n int) *Message
- func (m *Message) Info(str string, arg ...interface{}) *Message
- func (m *Message) IsCliUA() bool
- func (m *Message) IsErr(arg ...string) bool
- func (m *Message) IsErrNotFound() bool
- func (m *Message) Length() (max int)
- func (m *Message) Load(arg ...string) *Message
- func (m *Message) Log(level string, str string, arg ...interface{}) *Message
- func (m *Message) Log_AUTH(arg ...interface{}) *Message
- func (m *Message) Log_CREATE(arg ...interface{}) *Message
- func (m *Message) Log_DELETE(arg ...interface{}) *Message
- func (m *Message) Log_EXPORT(arg ...interface{}) *Message
- func (m *Message) Log_IMPORT(arg ...interface{}) *Message
- func (m *Message) Log_INSERT(arg ...interface{}) *Message
- func (m *Message) Log_MODIFY(arg ...interface{}) *Message
- func (m *Message) Log_REMOVE(arg ...interface{}) *Message
- func (m *Message) Log_SELECT(arg ...interface{}) *Message
- func (m *Message) Log_SEND(arg ...interface{}) *Message
- func (m *Message) Logs(level string, arg ...interface{}) *Message
- func (m *Message) MergeCmd(cmd string, arg ...interface{}) string
- func (m *Message) MergeLink(url string, arg ...interface{}) string
- func (m *Message) MergePod(pod string, arg ...interface{}) string
- func (m *Message) MergePodURL(url string, arg ...interface{}) string
- func (m *Message) MergeURL2(url string, arg ...interface{}) string
- func (m *Message) MergeWebsite(web string, arg ...interface{}) string
- func (m *Message) Option(key string, arg ...interface{}) string
- func (m *Message) OptionCB(key string, cb ...interface{}) interface{}
- func (m *Message) OptionDefault(key, value string) string
- func (m *Message) OptionFields(arg ...string) string
- func (m *Message) OptionLoad(file string) *Message
- func (m *Message) OptionPage(arg ...string) int
- func (m *Message) OptionPages(arg ...string) (page int, size int)
- func (m *Message) OptionSimple(key ...string) (res []string)
- func (m *Message) OptionSplit(key ...string) (res []string)
- func (m *Message) OptionTemplate() string
- func (m *Message) OptionUserWeb() *url.URL
- func (m *Message) Optionv(key string, arg ...interface{}) interface{}
- func (m *Message) PodCmd(arg ...interface{}) bool
- func (m *Message) Prefix(arg ...string) string
- func (m *Message) PrefixKey(arg ...string) string
- func (m *Message) Process(action string, arg ...interface{})
- func (m *Message) ProcessAgain()
- func (m *Message) ProcessBack()
- func (m *Message) ProcessCommand(cmd string, val []string, arg ...string)
- func (m *Message) ProcessCommandOpt(arg []string, args ...string)
- func (m *Message) ProcessDisplay(arg ...interface{})
- func (m *Message) ProcessField(arg ...interface{})
- func (m *Message) ProcessHistory(arg ...interface{})
- func (m *Message) ProcessHold()
- func (m *Message) ProcessInner()
- func (m *Message) ProcessLocation(arg ...interface{})
- func (m *Message) ProcessOpen(url string)
- func (m *Message) ProcessRefresh(delay string)
- func (m *Message) ProcessRefresh300ms()
- func (m *Message) ProcessRefresh30ms()
- func (m *Message) ProcessRefresh3ms()
- func (m *Message) ProcessRefresh3s()
- func (m *Message) ProcessReplace(arg ...interface{})
- func (m *Message) ProcessRewrite(arg ...interface{})
- func (m *Message) Push(key string, value interface{}, arg ...interface{}) *Message
- func (m *Message) PushAction(list ...interface{}) *Message
- func (m *Message) PushAnchor(arg ...interface{})
- func (m *Message) PushButton(arg ...interface{})
- func (m *Message) PushDetail(value interface{}, arg ...string) *Message
- func (m *Message) PushDownload(key string, arg ...interface{})
- func (m *Message) PushIFrame(key, src string, arg ...string)
- func (m *Message) PushImages(key, src string, arg ...string)
- func (m *Message) PushNotice(arg ...interface{})
- func (m *Message) PushNoticeGrow(arg ...interface{})
- func (m *Message) PushNoticeToast(arg ...interface{})
- func (m *Message) PushPodCmd(cmd string, arg ...string)
- func (m *Message) PushQRCode(key string, src string, arg ...string)
- func (m *Message) PushRecord(value interface{}, arg ...string) *Message
- func (m *Message) PushRefresh(arg ...interface{})
- func (m *Message) PushScript(arg ...string)
- func (m *Message) PushSearch(args ...interface{})
- func (m *Message) PushVideos(key, src string, arg ...string)
- func (m *Message) RenameAppend(arg ...string) *Message
- func (m *Message) Render(cmd string, args ...interface{}) *Message
- func (m *Message) RenderCmd(index string, args ...interface{})
- func (m *Message) RenderDownload(args ...interface{}) *Message
- func (m *Message) RenderIndex(serve, repos string, file ...string) *Message
- func (m *Message) RenderRedirect(args ...interface{}) *Message
- func (m *Message) RenderResult(args ...interface{}) *Message
- func (m *Message) RenderTemplate(args ...interface{}) *Message
- func (m *Message) RenderWebsite(pod string, dir string, arg ...string) *Message
- func (m *Message) Result(arg ...interface{}) string
- func (m *Message) Resultv(arg ...interface{}) []string
- func (m *Message) Rich(prefix string, chain interface{}, data interface{}) string
- func (m *Message) Richs(prefix string, chain interface{}, raw interface{}, cb interface{}) (res map[string]interface{})
- func (m *Message) Right(arg ...interface{}) bool
- func (m *Message) Save(arg ...string) *Message
- func (m *Message) Search(key string, cb interface{}) *Message
- func (m *Message) Set(key string, arg ...string) *Message
- func (m *Message) SetAppend(arg ...string) *Message
- func (m *Message) SetResult(arg ...string) *Message
- func (m *Message) Sleep(d string, arg ...interface{}) *Message
- func (m *Message) Sleep300ms(arg ...interface{}) *Message
- func (m *Message) Sleep30ms(arg ...interface{}) *Message
- func (m *Message) Sleep30s(arg ...interface{}) *Message
- func (m *Message) Sleep3s(arg ...interface{}) *Message
- func (m *Message) Sort(key string, arg ...string) *Message
- func (m *Message) SortInt(key string)
- func (m *Message) SortIntR(key string)
- func (m *Message) SortStr(key string)
- func (m *Message) SortStrR(key string)
- func (m *Message) SortTime(key string)
- func (m *Message) SortTimeR(key string)
- func (m *Message) Source() *Context
- func (m *Message) Space(arg interface{}) []string
- func (m *Message) Spawn(arg ...interface{}) *Message
- func (m *Message) Split(str string, arg ...string) *Message
- func (m *Message) SplitIndex(str string, arg ...string) *Message
- func (m *Message) Start(key string, arg ...string) *Message
- func (m *Message) Status(arg ...interface{})
- func (m *Message) StatusTime(arg ...interface{})
- func (m *Message) StatusTimeCount(arg ...interface{})
- func (m *Message) StatusTimeCountTotal(arg ...interface{})
- func (m *Message) Table(cbs ...func(index int, value map[string]string, head []string)) *Message
- func (m *Message) Tables(cbs ...func(value map[string]string)) *Message
- func (m *Message) Target() *Context
- func (m *Message) Time(args ...interface{}) string
- func (m *Message) ToLowerAppend(arg ...string) *Message
- func (m *Message) Toast(text string, arg ...interface{})
- func (m *Message) Toast30s(text string, arg ...interface{})
- func (m *Message) Toast3s(text string, arg ...interface{})
- func (m *Message) ToastFailure(arg ...interface{})
- func (m *Message) ToastProcess(arg ...interface{}) func()
- func (m *Message) ToastRestart(arg ...interface{})
- func (m *Message) ToastSuccess(arg ...interface{})
- func (m *Message) Travel(cb interface{}) *Message
- func (m *Message) TryCatch(msg *Message, silent bool, hand ...func(msg *Message)) *Message
- func (m *Message) Upload(dir string)
- func (m *Message) Warn(err interface{}, arg ...interface{}) bool
- func (m *Message) Watch(key string, arg ...string) *Message
- type Option
- type Server
Constants ¶
View Source
const ( TB = "\t" SP = " " DF = ":" PS = "/" PT = "." FS = "," NL = "\n" OK = "ok" TRUE = "true" FALSE = "false" SUCCESS = "success" FAILURE = "failure" PROCESS = "process" RESTART = "restart" OF = " of " INIT = "init" EXIT = "exit" SAVE = "save" LOAD = "load" AUTO = "auto" LIST = "list" BACK = "back" EXEC = "exec" SHOW = "show" PLAY = "play" HELP = "help" HTTP = "http" BASE = "base" CORE = "core" MISC = "misc" SHY = "shy" DEV = "dev" OPS = "ops" ICE = "ice" ENV = "env" RUN = "run" ERR = "err" POD = "pod" CTX = "ctx" CMD = "cmd" ARG = "arg" RES = "res" )
View Source
const ( MOD_DIR = 0750 MOD_FILE = 0640 MOD_CHAN = 16 MOD_TICK = "1s" MOD_BUFS = 4096 MOD_DATE = "2006-01-02" MOD_TIME = "2006-01-02 15:04:05" )
View Source
const ( VOLCANOS = "volcanos" LEARNING = "learning" ICEBERGS = "icebergs" TOOLKITS = "toolkits" INTSHELL = "intshell" CONTEXTS = "contexts" INSTALL = "install" RELEASE = "release" PUBLISH = "publish" REQUIRE = "require" DISPLAY = "display" )
View Source
const ( SRC = "src" ETC = "etc" BIN = "bin" VAR = "var" USR = "usr" HTML = "html" CSS = "css" JS = "js" GO = "go" SH = "sh" CSV = "csv" JSON = "json" USR_VOLCANOS = "usr/volcanos" USR_LEARNING = "usr/learning" USR_ICEBERGS = "usr/icebergs" USR_TOOLKITS = "usr/toolkits" USR_INTSHELL = "usr/intshell" USR_INSTALL = "usr/install" USR_RELEASE = "usr/release" USR_PUBLISH = "usr/publish" PLUGIN_INPUT = "/plugin/input" PLUGIN_STORY = "/plugin/story" PLUGIN_LOCAL = "/plugin/local" FAVICON = "favicon.ico" PROTO_JS = "proto.js" FRAME_JS = "frame.js" INDEX_JS = "index.js" ORDER_JS = "order.js" ORDER_SH = "order.sh" INDEX_SH = "index.sh" USR_LOCAL = "usr/local" USR_LOCAL_GO = "usr/local/go" USR_LOCAL_GO_BIN = "usr/local/go/bin" USR_LOCAL_BIN = "usr/local/bin" USR_LOCAL_LIB = "usr/local/lib" USR_LOCAL_WORK = "usr/local/work" USR_LOCAL_IMAGE = "usr/local/image" USR_LOCAL_RIVER = "usr/local/river" USR_LOCAL_DAEMON = "usr/local/daemon" USR_LOCAL_EXPORT = "usr/local/export" VAR_RUN = "var/run" VAR_TMP = "var/tmp" VAR_LOG = "var/log" VAR_CONF = "var/conf" VAR_DATA = "var/data" VAR_FILE = "var/file" VAR_PROXY = "var/proxy" VAR_TRASH = "var/trash" BIN_ICE_SH = "bin/ice.sh" BIN_ICE_BIN = "bin/ice.bin" BIN_BOOT_LOG = "bin/boot.log" ETC_INIT_SHY = "etc/init.shy" ETC_LOCAL_SHY = "etc/local.shy" ETC_EXIT_SHY = "etc/exit.shy" ETC_MISS_SH = "etc/miss.sh" ETC_PATH = "etc/path" SRC_HELP = "src/help" SRC_DEBUG = "src/debug" SRC_RELEASE = "src/release" SRC_MAIN_GO = "src/main.go" SRC_MAIN_SHY = "src/main.shy" SRC_MAIN_SVG = "src/main.svg" SRC_VERSION_GO = "src/version.go" SRC_BINPACK_GO = "src/binpack.go" SRC_RELAY_GO = "src/relay.go" README_MD = "README.md" MAKEFILE = "Makefile" ICE_BIN = "ice.bin" GO_SUM = "go.sum" GO_MOD = "go.mod" )
View Source
const ( MSG_DETAIL = "detail" MSG_OPTION = "option" MSG_APPEND = "append" MSG_RESULT = "result" MSG_CMDS = "cmds" MSG_FIELDS = "fields" MSG_SESSID = "sessid" MSG_DOMAIN = "domain" MSG_OPTS = "_option" MSG_ALIAS = "_alias" MSG_SCRIPT = "_script" MSG_SOURCE = "_source" MSG_TARGET = "_target" MSG_HANDLE = "_handle" MSG_OUTPUT = "_output" MSG_ARGS = "_args" MSG_UPLOAD = "_upload" MSG_DAEMON = "_daemon" MSG_ACTION = "_action" MSG_STATUS = "_status" MSG_DISPLAY = "_display" MSG_PROCESS = "_process" MSG_USERIP = "user.ip" MSG_USERUA = "user.ua" MSG_USERWEB = "user.web" MSG_USERPOD = "user.pod" MSG_USERADDR = "user.addr" MSG_USERDATA = "user.data" MSG_USERROLE = "user.role" MSG_USERNAME = "user.name" MSG_USERNICK = "user.nick" MSG_USERZONE = "user.zone" MSG_LANGUAGE = "user.lang" MSG_TITLE = "sess.title" MSG_TOPIC = "sess.topic" MSG_RIVER = "sess.river" MSG_STORM = "sess.storm" MSG_TOAST = "sess.toast" MSG_LOCAL = "sess.local" )
View Source
const ( RENDER_RAW = "_raw" RENDER_VOID = "_void" RENDER_RESULT = "_result" RENDER_ANCHOR = "_anchor" RENDER_BUTTON = "_button" RENDER_SCRIPT = "_script" RENDER_QRCODE = "_qrcode" RENDER_IMAGES = "_images" RENDER_VIDEOS = "_videos" RENDER_IFRAME = "_iframe" RENDER_TEMPLATE = "_template" RENDER_REDIRECT = "_redirect" RENDER_DOWNLOAD = "_download" )
View Source
const ( PROCESS_LOCATION = "_location" PROCESS_REPLACE = "_replace" PROCESS_HISTORY = "_history" PROCESS_REFRESH = "_refresh" PROCESS_REWRITE = "_rewrite" PROCESS_DISPLAY = "_display" PROCESS_FIELD = "_field" PROCESS_INNER = "_inner" PROCESS_AGAIN = "_again" PROCESS_OPEN = "_open" PROCESS_HOLD = "_hold" PROCESS_BACK = "_back" PROCESS_GROW = "_grow" FIELD_PREFIX = "_prefix" )
View Source
const ( CACHE_LIMIT = "cache.limit" CACHE_BEGIN = "cache.begin" CACHE_COUNT = "cache.count" CACHE_OFFEND = "cache.offend" CACHE_FILTER = "cache.filter" CACHE_VALUE = "cache.value" CACHE_FIELD = "cache.field" CACHE_DETAIL = "detail" )
View Source
const ( CTX_FOLLOW = "follow" CTX_STATUS = "status" CTX_STREAM = "stream" CTX_BEGIN = "begin" CTX_START = "start" CTX_SERVE = "serve" CTX_CLOSE = "close" CTX_INIT = "_init" CTX_EXIT = "_exit" )
View Source
const ( // 通用 LOG_INFO = "info" LOG_COST = "cost" LOG_WARN = "warn" LOG_ERROR = "error" LOG_DEBUG = "debug" // 命令 LOG_AUTH = "auth" LOG_CMDS = "cmds" LOG_SEND = "send" LOG_RECV = "recv" // 状态 LOG_BEGIN = "begin" LOG_START = "start" LOG_SERVE = "serve" LOG_CLOSE = "close" // 数据 LOG_CREATE = "create" LOG_REMOVE = "remove" LOG_INSERT = "insert" LOG_DELETE = "delete" LOG_MODIFY = "modify" LOG_SELECT = "select" LOG_EXPORT = "export" LOG_IMPORT = "import" )
View Source
const ( ErrWarn = "warn: " ErrPanic = "panic: " ErrExists = "exists: " ErrExpire = "expire: " ErrTimeout = "timeout: " ErrFailure = "failure: " ErrNotLogin = "not login: " ErrNotFound = "not found: " ErrNotRight = "not right: " ErrNotStart = "not start: " ErrNotImplement = "not implement: " )
View Source
const ( // CTX = "ctx" CLI = "cli" WEB = "web" AAA = "aaa" LEX = "lex" YAC = "yac" GDB = "gdb" LOG = "log" TCP = "tcp" NFS = "nfs" SSH = "ssh" MDB = "mdb" )
View Source
const ( COMMAND = "command" ACTION = "action" CONFIG = "config" STYLE = "style" INDEX = "index" ARGS = "args" INPUTS = "inputs" FEATURE = "feature" )
View Source
const ( SERVE = "serve" SPACE = "space" SPIDE = "spide" CACHE = "cache" )
View Source
const ( KEY = "key" VALUE = "value" SCRIPT = "script" LINK = "link" META = "meta" HASH = "hash" TIME = "time" TYPE = "type" NAME = "name" TEXT = "text" )
Variables ¶
View Source
var Index = &Context{Name: "ice", Help: "冰山模块", Configs: map[string]*Config{ HELP: {Value: kit.Data("index", Info.Help)}, }, Commands: map[string]*Command{ CTX_INIT: {Hand: func(m *Message, c *Context, cmd string, arg ...string) { defer m.Cost(CTX_INIT) m.root.Travel(func(p *Context, c *Context) { if cmd, ok := c.Commands[CTX_INIT]; ok && p != nil { c.cmd(m.Spawn(c), cmd, CTX_INIT, arg...) } }) }}, INIT: {Name: "init", Help: "启动", Hand: func(m *Message, c *Context, cmd string, arg ...string) { m.root.Cmd(CTX_INIT) m.Cmd("source", ETC_INIT_SHY) }}, HELP: {Name: "help", Help: "帮助", Hand: func(m *Message, c *Context, cmd string, arg ...string) { m.Echo(m.Config("index")) }}, EXIT: {Name: "exit", Help: "结束", Hand: func(m *Message, c *Context, cmd string, arg ...string) { m.root.Option(EXIT, kit.Select("0", arg, 0)) defer c.Close(m.root.Spawn(), arg...) m.Cmd("source", ETC_EXIT_SHY) m.root.Cmd(CTX_EXIT) }}, CTX_EXIT: {Hand: func(m *Message, c *Context, cmd string, arg ...string) { defer m.Cost(CTX_EXIT) m.Option("cmd_dir", "") m.Option("dir_root", "") m.root.Travel(func(p *Context, c *Context) { if cmd, ok := c.Commands[CTX_EXIT]; ok && p != nil { m.TryCatch(m.Spawn(c), true, func(msg *Message) { c.cmd(msg, cmd, CTX_EXIT, arg...) }) } }) }}, }, server: &Frame{}, wg: &sync.WaitGroup{}}
View Source
var Info = struct { Make MakeInfo HostName string PathName string UserName string PassWord string Colors bool Domain string NodeType string NodeName string CtxShare string CtxRiver string Help string Route map[string]string // 路由命令 File map[string]string // 文件命令 Pack map[string][]byte // 打包文件 Dump func(w io.Writer, name string, cb func(string)) bool Log func(m *Message, p, l, s string) render map[string]func(*Message, string, ...interface{}) string names map[string]interface{} }{ Help: ` ^_^ 欢迎使用冰山框架 ^_^ ^_^ Welcome to Icebergs World ^_^ report: shylinuxc@gmail.com server: https://shylinux.com source: https://shylinux.com/x/icebergs `, Route: map[string]string{}, File: map[string]string{}, Pack: map[string][]byte{}, Dump: func(w io.Writer, name string, cb func(string)) bool { return false }, Log: func(m *Message, p, l, s string) {}, // contains filtered or unexported fields }
Functions ¶
func DisplayRequire ¶ added in v0.7.9
Types ¶
type Action ¶
type Action struct { Name string Help string Hand ActionHandler List []interface{} }
type Command ¶
type CommandHandler ¶ added in v1.1.7
type Context ¶
type Context struct { Name string Help string Caches map[string]*Cache Configs map[string]*Config Commands map[string]*Command Contexts map[string]*Context // contains filtered or unexported fields }
func (*Context) Spawn ¶
type Frame ¶
type Frame struct{}
type MakeInfo ¶ added in v0.9.8
type Message ¶
type Message struct { Hand bool W http.ResponseWriter R *http.Request O io.Writer I io.Reader // contains filtered or unexported fields }
func (*Message) AppendTrans ¶ added in v0.4.7
func (*Message) Config ¶ added in v0.4.9
func (*Message) ConfigSimple ¶ added in v0.5.0
func (*Message) Configm ¶ added in v0.7.8
func (*Message) Configv ¶ added in v0.6.3
func (*Message) Confm ¶
func (*Message) Display ¶ added in v0.7.0
func (*Message) DisplayBase ¶ added in v0.7.9
func (*Message) DisplayLocal ¶ added in v0.7.0
func (*Message) DisplayStory ¶ added in v0.7.9
func (*Message) DisplayStoryJSON ¶ added in v1.0.7
func (*Message) EchoIFrame ¶ added in v0.7.7
func (*Message) EchoVideos ¶ added in v0.5.3
func (*Message) GoToast ¶
func (*Message) Grow ¶
func (*Message) Grows ¶
func (*Message) MergeCmd ¶ added in v1.1.7
func (*Message) MergeLink ¶ added in v0.9.0
func (*Message) MergePod ¶ added in v1.1.7
func (*Message) MergePodURL ¶ added in v1.2.0
func (*Message) MergeURL2 ¶ added in v0.7.4
func (*Message) MergeWebsite ¶ added in v1.1.7
func (*Message) OptionCB ¶ added in v0.6.4
func (*Message) OptionDefault ¶ added in v1.1.8
func (*Message) OptionPages ¶ added in v1.2.0
func (*Message) ProcessCommand ¶
func (*Message) ProcessCommandOpt ¶
func (*Message) ProcessHistory ¶ added in v1.2.0
func (m *Message) ProcessHistory(arg ...interface{})
func (*Message) ProcessReplace ¶ added in v1.2.0
func (m *Message) ProcessReplace(arg ...interface{})
func (*Message) Push ¶
func (*Message) PushDetail ¶ added in v1.1.3
func (*Message) PushIFrame ¶ added in v0.7.7
func (*Message) PushNoticeGrow ¶ added in v0.7.2
func (m *Message) PushNoticeGrow(arg ...interface{})
func (*Message) PushNoticeToast ¶ added in v0.7.2
func (m *Message) PushNoticeToast(arg ...interface{})
func (*Message) PushRecord ¶ added in v1.1.8
func (*Message) RenderCmd ¶ added in v0.6.3
func (*Message) RenderIndex ¶
func (*Message) RenderWebsite ¶ added in v1.1.2
func (*Message) Rich ¶
func (*Message) Richs ¶
func (*Message) Sleep300ms ¶ added in v0.6.4
func (*Message) Sleep30ms ¶ added in v0.6.4
func (*Message) SplitIndex ¶ added in v0.7.8
func (*Message) Table ¶
func (*Message) Tables ¶ added in v0.9.9
func (*Message) ToLowerAppend ¶ added in v1.1.2
func (*Message) Toast30s ¶ added in v0.6.4
func (*Message) Toast3s ¶ added in v0.6.4
func (*Message) ToastProcess ¶ added in v0.9.0
func (m *Message) ToastProcess(arg ...interface{}) func()
func (*Message) TryCatch ¶
Source Files ¶
Click to show internal directories.
Click to hide internal directories.