Documentation ¶
Index ¶
- func Initials(src string) string
- func Lower(src string) string
- func Trim(src, sep string) string
- func Upper(src string) string
- func UpperID(src string) string
- type UOS
- func (d *UOS) Add(path string) *UOS
- func (d *UOS) Cat() string
- func (d *UOS) Copy(dst string) error
- func (d *UOS) Create() bool
- func (d *UOS) Dir() string
- func (d *UOS) DirExist() bool
- func (d *UOS) Exist(path ...string) bool
- func (d *UOS) File() string
- func (d *UOS) FileName(pattern ...string) string
- func (d *UOS) Find(pattern ...string) ([]string, error)
- func (d *UOS) InDir() string
- func (d *UOS) IsDir(path ...string) bool
- func (d *UOS) IsFile() bool
- func (d *UOS) Ls(pattern ...string) ([]string, error)
- func (d *UOS) MkDir() error
- func (d *UOS) Path() string
- func (d *UOS) Read() (string, bool)
- func (d *UOS) Rm(name ...string) error
- func (d *UOS) Suffix() string
- func (d *UOS) Write(src []byte, add ...bool) bool
- func (d *UOS) WriteCharset(src, cs string) bool
- type UText
- func (t *UText) Add(text string) *UText
- func (t *UText) ChineseNumber(mode bool) string
- func (t *UText) Enter() *UText
- func (t *UText) Find(dst string) bool
- func (t *UText) Get() string
- func (t *UText) Initials() string
- func (t *UText) IsHan(text string) bool
- func (t *UText) Lower() string
- func (t *UText) Parse(data interface{}) string
- func (t *UText) Replace(src, dst string) string
- func (t *UText) Space() *UText
- func (t *UText) Split(sep string) []string
- func (t *UText) SplitPlace(sep []int) []string
- func (t *UText) Trim(sep string) string
- func (t *UText) Upper() string
- func (t *UText) UpperID() string
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type UOS ¶
type UOS struct {
// contains filtered or unexported fields
}
UOS 工具类型...
func (*UOS) WriteCharset ¶
WriteCharset 非UTF8格式自动转换为UTF8.
type UText ¶
type UText struct {
// contains filtered or unexported fields
}
UText 工具类型...
func (*UText) ChineseNumber ¶
ChineseNumber 英文数字转为中文数字
func (*UText) Parse ¶
Parse 根据模版解析文本... t.text : Hell{{.d}} Wor{{.o}} data : map[string]string{ "d": "o", "o":"d" } t.text : Hello {{.}} data : Word t.text : {{.H}} {{.W}} &data{H: "Hello", W: "Word"} -> Hello Word
func (*UText) SplitPlace ¶
SplitPlace 根据字符串的位置进行分割 Text("abcdefg").SpltPlace([]int{1,3,4}) Out: []string{"a", "bc", "d", "efg"}
Source Files ¶
Click to show internal directories.
Click to hide internal directories.