Documentation ¶
Index ¶
- func Base64(params string) string
- func Base64Bytes(bytes []byte) string
- func Base64MD5(params string) string
- func BoolAddr(b bool) *bool
- func C2Camel(str string) string
- func Camel2C(str string) string
- func Capitalize(str string) string
- func ConditionString(condition bool, f1 interface{}, f2 interface{}) string
- func Contains(container interface{}, obj interface{}) (bool, error)
- func ContainsAll(container interface{}, objs []interface{}) (bool, error)
- func ContainsAny(container interface{}, objs []interface{}) (bool, error)
- func CopyFields(dest interface{}, src interface{}, fields ...string) (err error)
- func CopyFieldsExcept(dest interface{}, src interface{}, fields ...string) (err error)
- func CreateSqlResFormatFactory() *sqlResFormatTree
- func DbFieldName(s string) string
- func DbFields(kv map[string]interface{}) map[string]interface{}
- func DefaultString(s string, defaultValue string) string
- func DeleteElement(src []string, elem string) []string
- func DeleteElements(src []string, elems []string) []string
- func FillFields(dest interface{}, src interface{}, fields ...string) (err error)
- func Filter(container interface{}, objs []interface{}) (interface{}, error)
- func First[T any](items []T, filter func(T) bool) T
- func FormatParamterContent(content string, params map[string]string) string
- func GenerateRandomNumeric(length int) string
- func GenerateRandomString(length int) string
- func GetRecordField(record interface{}, path string) (interface{}, bool)
- func GetRecordFieldValue[T any](record interface{}, path string, v T) T
- func Int32Addr(i int32) *int32
- func Int64Addr(i int64) *int64
- func IntAddr(i int) *int
- func MD5(params string) string
- func MapStruct(src map[string]interface{}, dest interface{})
- func MergeFields(dest interface{}, src interface{}, fields ...string) (err error)
- func NewInternationalTelephoneValidator(field string) validation.Validator
- func NotNullString(s *string) string
- func Nullable(s *string) *string
- func RemoveRepByMap(slc []string) []string
- func SHA1(data string) string
- func StringAddr(s string) *string
- func StringValue(s *string) string
- func Struct2Map(src interface{}) map[string]interface{}
- func SubString(str string, begin, length int) string
- func TimeAddr(t time.Time) *time.Time
- func TimeValue(t *time.Time) time.Time
- func UUID() string
- func Unzip(zipFile string, destDir string) ([]string, error)
- func VariableName(str string) string
- func ZipFiles(filename string, files []string, oldForm, newForm string) error
- type InternationalTelephone
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ConditionString ¶
func ContainsAll ¶
func ContainsAny ¶
func CopyFields ¶
按名字和类型复制(&a,b)b->a
func CopyFieldsExcept ¶
按名字和类型复制(&a,b)b->a
func CreateSqlResFormatFactory ¶
func CreateSqlResFormatFactory() *sqlResFormatTree
func DbFieldName ¶ added in v0.0.3
func DefaultString ¶
func DeleteElement ¶
func DeleteElements ¶
func FillFields ¶ added in v0.0.3
按名字和类型复制(&a,b)b->a: a.field为空的取a.field
func FormatParamterContent ¶ added in v0.0.8
func GenerateRandomNumeric ¶ added in v0.0.14
func GenerateRandomString ¶
func GetRecordField ¶ added in v0.0.15
func GetRecordFieldValue ¶ added in v0.0.15
func MergeFields ¶ added in v0.0.3
按名字和类型合并(&a,b)b->a: field值取不为空的
func NewInternationalTelephoneValidator ¶ added in v0.0.30
func NewInternationalTelephoneValidator(field string) validation.Validator
func NotNullString ¶
func RemoveRepByMap ¶
func StringAddr ¶
func StringValue ¶
func Struct2Map ¶ added in v0.0.15
func Struct2Map(src interface{}) map[string]interface{}
func VariableName ¶ added in v0.0.3
Types ¶
type InternationalTelephone ¶ added in v0.0.30
type InternationalTelephone struct { validation.Match Key string }
Tel check telephone struct
Source Files ¶
Click to show internal directories.
Click to hide internal directories.