Documentation
¶
Index ¶
- func CompareMcVersion(mainVersion, compareVersion string) int
- func CompressFile(source, destination string) error
- func CompressFiles(sources []string, destination string) error
- func CopyDir(src, dest string) error
- func CreatDir(dirPath string) error
- func CreateFile(path string) (*os.File, error)
- func Ellipsis(str string, l int) string
- func ExistsResource(path string) bool
- func FormateTable(header []string, data [][]string) string
- func GBK2UTF8(data []byte) ([]byte, error)
- func GetCommandArr(memory int64, runPath string) []string
- func GetCurrentPath() (string, error)
- func GetFilesFromDir(dirPath string) []string
- func GetFreePort(port int64) (int64, error)
- func IntToint32(i int) int32
- func IsDir(path string) bool
- func IsFile(path string) bool
- func IsUTF8(data []byte) bool
- func Md5(str string) string
- func NewConfParam(confKey, ConfVal, description string, level int64, IsAlterable bool) *models.ConfParam
- func OpenBrowser(url string)
- func PanicError(msg string, err error)
- func ParseCharacter(data []byte) ([]byte, error)
- func ParsePluginCommand(msg string) (command string, params []string)
- func RemoveRepeatedElement(arr []string) []string
- func UTF82GBK(data []byte) ([]byte, error)
- func Uint64Tofloat64(ui uint64) float64
- func UnCompressDir(source, destination string) error
- type Item
- type List
- func (l *List) DelByCallback(cb func(int, interface{}) bool)
- func (l *List) DelWithIndex(i int)
- func (l *List) GetLen() int
- func (l *List) InsertWithIndex(i int, value interface{})
- func (l *List) InsertWithIndexAndTypeName(i int, value interface{}, typeName string)
- func (l *List) LPush(value interface{})
- func (l *List) LPushWithTypeName(value interface{}, typeName string)
- func (l *List) RPush(value interface{})
- func (l *List) RPushWithTypeName(value interface{}, typeName string)
- func (l *List) ToArray() []interface{}
- func (l *List) ToJson() (string, error)
- type TellrowMessage
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CompareMcVersion ¶
比较mc版本 1表示大于,0表示等于,-1表示小于
func GetFreePort ¶
GetFreePort 获取系统空闲端口 如果port为0,则表示随机获取一个空闲端口,不为0则为指定端口
func NewConfParam ¶
func NewConfParam(confKey, ConfVal, description string, level int64, IsAlterable bool) *models.ConfParam
创建confParam实例
func ParseCharacter ¶
判断字符编码是否不是UTF8, 如果不是,尝试转成UTF8
func ParsePluginCommand ¶
解析mc玩家发言插件命令
Types ¶
type List ¶ added in v1.1.0
type List struct {
// contains filtered or unexported fields
}
链表
func (*List) DelByCallback ¶ added in v1.1.0
func (*List) DelWithIndex ¶ added in v1.1.0
func (*List) InsertWithIndex ¶ added in v1.1.0
func (*List) InsertWithIndexAndTypeName ¶ added in v1.1.0
func (*List) LPushWithTypeName ¶ added in v1.1.0
func (*List) RPushWithTypeName ¶ added in v1.1.0
type TellrowMessage ¶
func NewTellrowMessage ¶
func NewTellrowMessage() TellrowMessage
func (TellrowMessage) JSON ¶
func (t TellrowMessage) JSON() string
func (TellrowMessage) SetParam ¶
func (t TellrowMessage) SetParam(param, val string) TellrowMessage
func (TellrowMessage) SetText ¶
func (t TellrowMessage) SetText(text string) TellrowMessage
func (TellrowMessage) SetTextColor ¶
func (t TellrowMessage) SetTextColor(text, color string) TellrowMessage
Click to show internal directories.
Click to hide internal directories.