Documentation ¶
Index ¶
- func DotPathToSlashPath(p string) string
- func GetElement(value interface{}) reflect.Value
- func GetKind(value interface{}) reflect.Kind
- func GetType(value interface{}) reflect.Type
- func GetTypeName(myvar interface{}) string
- func IsArrayLike(value interface{}) bool
- func IsObjectID(obj interface{}) bool
- func IsString(value interface{}) bool
- func ToInterface(src interface{}, dest interface{}) error
- func ToSnakeCase(str string) string
- func ValidatorAlphaNumeric(value interface{}, fieldName string, doc bson.M) error
- func VirtualGetObjectIDAsHexString(fieldName string) func(doc bson.M) (interface{}, error)
- func VirtualGetWithDefault(fieldName string, defaultValue interface{}) func(doc bson.M) (interface{}, error)
- func VirtualSetNoop(value interface{}, doc bson.M) error
- func VirtualSetObjectID(fieldName string) func(value interface{}, doc bson.M) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DotPathToSlashPath ¶
DotPathToSlashPath converts a dot path to a dir path
func ToInterface ¶
func ToInterface(src interface{}, dest interface{}) error
ToInterface converts one interface to another using json
func ToSnakeCase ¶
ToSnakeCase converts to snake case https://gist.github.com/stoewer/fbe273b711e6a06315d19552dd4d33e6
func ValidatorAlphaNumeric ¶
ValidatorAlphaNumeric performs an alpha-numeric validation on a value
func VirtualGetObjectIDAsHexString ¶
VirtualGetObjectIDAsHexString returns the specified field containing an ObjectID as a hex string
func VirtualGetWithDefault ¶
func VirtualGetWithDefault(fieldName string, defaultValue interface{}) func(doc bson.M) (interface{}, error)
VirtualGetWithDefault gets the specified field or returns default if set
func VirtualSetNoop ¶
VirtualSetNoop does nothing, you're welcome
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.