Documentation ¶
Index ¶
- Constants
- func ByteToInt16(buf []byte) (ret int16)
- func ByteToInt16LD(buf []byte) (ret int16)
- func ByteToInt32(buf []byte) (ret int32)
- func ByteToInt32LD(buf []byte) (ret int32)
- func ByteToInt64(buf []byte) (ret int64)
- func CheckError(err error)
- func ConvertInterface2Bool(v interface{}) (bool, error)
- func ConvertInterface2Int(v interface{}) (int, error)
- func ConvertInterface2Int16(v interface{}) (int16, error)
- func ConvertInterface2Int32(v interface{}) (int32, error)
- func ConvertInterface2Int32Array(v interface{}) ([]int32, error)
- func ConvertInterface2Int64(v interface{}) (int64, error)
- func ConvertInterface2Int8(v interface{}) (int8, error)
- func ConvertInterface2String(v interface{}) (string, error)
- func ConvertString2Int(value string) (iValue int, err error)
- func ConvertString2Int16(value string) (iValue int16, err error)
- func ConvertString2Int32(value string) (iValue int32, err error)
- func ConvertString2Int64(value string) (iValue int64, err error)
- func ConvertString2Int8(value string) (iValue int8, err error)
- func ConvertTime2Int64(value string) (iValue int64, err error)
- func Int16ToByte(v int16) (buf []byte)
- func Int16ToByteLD(v int16) (buf []byte)
- func Int32ToByte(v int32) (buf []byte)
- func Int32ToByteLD(v int32) (buf []byte)
- func Int64ToByte(v int64) (buf []byte)
- func ParseIP(r *http.Request) string
- func Stack(skip int) []byte
- func UUID() string
- type Attr
- func (attr *Attr) Copy(srcAttr IAttr)
- func (attr *Attr) CopyFromMap(newAttr map[string]interface{})
- func (attr *Attr) CopyToMap() map[string]interface{}
- func (attr *Attr) Get(key string) (value interface{})
- func (attr *Attr) GetBool(key string) bool
- func (attr *Attr) GetInt(key string) int
- func (attr *Attr) GetInt16(key string) int16
- func (attr *Attr) GetInt32(key string) int32
- func (attr *Attr) GetInt64(key string) int64
- func (attr *Attr) GetInt8(key string) int8
- func (attr *Attr) GetString(key string) string
- func (attr *Attr) Set(key string, value interface{})
- type IAttr
Constants ¶
View Source
const ( INT8_SIZE int32 = 1 INT16_SIZE int32 = 2 INT32_SIZE int32 = 4 INT64_SIZE int32 = 8 STRING_PREFIX int32 = 2 BYTES_PREFIX int32 = 2 )
View Source
const (
VipDateFormat string = "2006-01-02 15:04:05"
)
Variables ¶
This section is empty.
Functions ¶
func ByteToInt16 ¶
func ByteToInt16LD ¶ added in v1.0.11
func ByteToInt32 ¶
func ByteToInt32LD ¶ added in v1.0.11
func ByteToInt64 ¶
func CheckError ¶
func CheckError(err error)
func ConvertInterface2Bool ¶
func ConvertInterface2Int ¶
func ConvertInterface2Int16 ¶
func ConvertInterface2Int32 ¶
func ConvertInterface2Int64 ¶
func ConvertInterface2Int8 ¶
func ConvertInterface2String ¶
func ConvertString2Int ¶
func ConvertString2Int16 ¶
func ConvertString2Int32 ¶
func ConvertString2Int64 ¶
func ConvertString2Int8 ¶
func ConvertTime2Int64 ¶
func Int16ToByte ¶
func Int16ToByteLD ¶ added in v1.0.11
func Int32ToByte ¶
func Int32ToByteLD ¶ added in v1.0.11
func Int64ToByte ¶
Types ¶
type Attr ¶
type Attr struct {
// contains filtered or unexported fields
}
func (*Attr) CopyFromMap ¶
type IAttr ¶
type IAttr interface { Get(key string) (value interface{}) GetBool(key string) bool GetInt8(key string) (value int8) GetInt16(key string) (value int16) GetInt32(key string) (value int32) GetInt64(key string) (value int64) GetInt(key string) (value int) GetString(key string) (value string) Set(key string, value interface{}) CopyToMap() map[string]interface{} CopyFromMap(newAttr map[string]interface{}) Copy(newAttr IAttr) }
Source Files ¶
Click to show internal directories.
Click to hide internal directories.