Documentation
¶
Index ¶
- Constants
- Variables
- func AddUniq(list []string, arg ...string) []string
- func ArgDef(arg []string, args ...string) []string
- func BeginEnd(begin, end func()) func()
- func Capital(str string) string
- func Chdir(p string)
- func Contains(str string, arg ...string) bool
- func Cut(str string, size int) string
- func DayBegin(t string) time.Time
- func Default(list []string, arg ...string) []string
- func Dir(arg ...string) string
- func Duration(val Any) time.Duration
- func Env(key string, def ...string) string
- func EnvList(arg ...string) []string
- func EnvSimple(arg ...string) (res []string)
- func Ext(str string) string
- func ExtChange(file, ext string) string
- func ExtIsImage(str string) bool
- func ExtIsVideo(str string) bool
- func ExtReg(ext ...string) string
- func Fields(arg ...Any) string
- func FileLine(p Any, n int) string
- func FileLines(p Any) string
- func FileName(p Any) string
- func Filters(list []string, arg ...string) (res []string)
- func Float(val Any) float64
- func FmtDuration(t time.Duration) string
- func FmtSize(v ...Any) (res string)
- func Format(val Any, arg ...Any) string
- func FormatKV(data Map, args ...string) string
- func FormatShow(arg ...Any) string
- func Formats(val Any) string
- func FuncName(p Any) string
- func GetValid(cb ...func() string) (res string)
- func HasPrefix(str string, arg ...string) bool
- func HasPrefixList(args []string, arg ...string) bool
- func HasSuffix(str string, arg ...string) bool
- func Hash(arg ...Any) (string, []string)
- func Hashs(arg ...Any) string
- func HashsPath(arg ...Any) string
- func HashsUniq(arg ...Any) string
- func HomePath(str string, rest ...string) string
- func If(exp Any, cb ...Any)
- func IfNoKey(list Map, p string, cb func(string))
- func IndexOf(str []string, sub string) int
- func Int(val Any) int
- func Int64(val Any) int64
- func IsAbs(p string) bool
- func IsDir(p string) bool
- func IsIn(str string, arg ...string) bool
- func IsUpper(str string) bool
- func IsUrl(p string) bool
- func Join(str []string, arg ...string) string
- func JoinCSS(arg ...string) string
- func JoinCmdArgs(arg ...string) string
- func JoinCmds(arg ...string) string
- func JoinKV(inner, outer string, arg ...string) string
- func JoinLine(arg ...string) string
- func JoinProperty(arg ...string) string
- func JoinQuery(arg ...string) string
- func JoinWord(arg ...string) string
- func KeyBase(key string) string
- func KeyExtra(arg ...Any) string
- func KeyHash(arg ...Any) string
- func Keycb(arg ...Any) string
- func Keym(arg ...Any) string
- func Keys(arg ...Any) string
- func Length(val Any) int
- func LowerCapital(str string) string
- func Max(arg ...int) (max int)
- func MergeURL(str string, arg ...Any) string
- func MergeURL2(str string, uri string, arg ...Any) string
- func Min(arg ...int) (min int)
- func ModName(p Any) string
- func ParseQuery(str string) url.Values
- func ParseURL(str string) *url.URL
- func ParseURLMap(str string) map[string]string
- func Path(str string, rest ...string) string
- func PathJoin(dir, file string, arg ...string) string
- func PathName(p Any) string
- func Paths(str string, rest ...string) string
- func Pwd() string
- func QueryUnescape(value string) string
- func Reflect(obj Any, cb func(name string, value Any)) (reflect.Type, reflect.Value)
- func Render(str string, arg Any) (b []byte, e error)
- func Renders(str string, arg Any) string
- func Replace(str string, arg ...string) string
- func ReplaceAll(str string, arg ...string) string
- func Reverse(str []string) []string
- func Select(def string, arg ...Any) string
- func Setenv(key string, val string)
- func ShortKey(list Map, min int, arg ...Any) string
- func Simple(arg ...Any) (res []string)
- func SimpleKV(key string, arg ...Any) (res []string)
- func Slice(list []string, index ...int) []string
- func SliceRemove(list []string, key string) ([]string, int)
- func Sort(list []string) []string
- func SortedKey(obj Any) (res []string)
- func SortedValue(obj Any) (res []string)
- func Split(str string, arg ...string) (res []string)
- func SplitKV(inner, outer string, text string, cb func(text string, ls []string))
- func SplitLine(text string) []string
- func SplitQuery(str string) []string
- func SplitWord(text string) []string
- func Time(arg ...string) int64
- func TimeUnix(stamp Any) string
- func TransArg(arg []string, key string, trans Any) []string
- func TransArgKey(arg []string, trans map[string]string) []string
- func TrimArg(arg ...string) []string
- func TrimExt(str string, ext ...string) string
- func TrimPath(p string) string
- func TrimPrefix(str string, arg ...string) string
- func UserName() string
- func Width(str string, mul int) int
- type Any
- func Fetch(val Any, cb Any) Any
- func For(val Any, cb Any) Any
- func Ignore(arg ...Any) Any
- func Lasterr(arg ...Any) Any
- func List(arg ...Any) []Any
- func Parse(value Any, key string, val ...string) Any
- func Switch(exp Any, arg ...Any) Any
- func UnMarshal(buf Any) (res Any)
- func Value(root Any, args ...Any) Any
- type Map
- type Maps
Constants ¶
View Source
const ( MOD_DATE = "2006-01-02" MOD_TIME = "2006-01-02 15:04:05.000" MOD_TIMES = "2006-01-02 15:04:05.000000" // 结构 MDB_DICT = "dict" MDB_META = "meta" MDB_HASH = "hash" MDB_LIST = "list" MDB_UNIQ = "uniq" MDB_RAND = "rand" MDB_FOREACH = "*" MDB_RANDOMS = "%" // 存储 MDB_SHORT = "short" MDB_FIELD = "field" MDB_TOTAL = "total" MDB_COUNT = "count" MDB_LIMIT = "limit" MDB_LEAST = "least" MDB_STORE = "store" MDB_FSIZE = "fsize" // 索引 MDB_INDEX = "index" MDB_VALUE = "value" MDB_EXTRA = "extra" MDB_ALIAS = "alias" MDB_EXPIRE = "expire" MDB_STATUS = "status" MDB_STREAM = "stream" // 文件 MDB_PATH = "path" MDB_FILE = "file" MDB_LINE = "line" MDB_SIZE = "size" MDB_LINK = "link" MDB_SCAN = "scan" MDB_SHOW = "show" MDB_COST = "cost" MDB_HELP = "help" MDB_ICON = "icon" // 数据 MDB_VIEW = "view" MDB_DATA = "data" MDB_TEXT = "text" MDB_NAME = "name" MDB_TYPE = "type" MDB_ZONE = "zone" MDB_TIME = "time" MDB_KEY = "key" MDB_ID = "id" )
View Source
const ( DF = ":" PS = "/" PT = "." FS = "," PNG = "png" JPG = "JPG" JPEG = "JPEG" HTTP = "http" )
Variables ¶
View Source
var HashSeed = []string{}
Functions ¶
func BeginEnd ¶ added in v0.7.1
func BeginEnd(begin, end func()) func()
func Reflect ¶ added in v0.5.7
func SplitKV ¶ added in v0.7.1
func TransArgKey ¶ added in v0.7.12
Types ¶
type Any ¶ added in v0.6.4
type Any = interface{}
type Map ¶ added in v0.6.4
Click to show internal directories.
Click to hide internal directories.