Documentation
¶
Index ¶
- Variables
- func CloseFile(file io.ReadCloser)
- func Glob(pattern string) ([]string, error)
- func ReadStream(fileName string) (io.ReadCloser, error)
- func ToArrayInterface(in interface{}) ([]interface{}, error)
- func ToArrayString(in interface{}) ([]string, error)
- func ToMapStringInterface(in interface{}) (map[string]interface{}, error)
- func ToString(in interface{}) (string, error)
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrConvertArrayInterface = errors.New("unable to convert to []interface{}") ErrConvertArrayString = errors.New("unable to convert to []string") ErrConvertMapStringInterface = errors.New("unable to convert to map[string]interface{}") ErrConvertString = errors.New("unable to convert to string") )
Functions ¶
func Glob ¶
Glob adds double-star support to the core path/filepath Glob function. It's useful when your globs might have double-stars, but you're not sure.
func ReadStream ¶
func ReadStream(fileName string) (io.ReadCloser, error)
func ToArrayInterface ¶
func ToArrayInterface(in interface{}) ([]interface{}, error)
ToArrayInterface attempts a conversion from an interface to an underlying array of interface type. Returns an error if the conversion is not possible.
func ToArrayString ¶
ToArrayString attempts a conversion from an interface to an underlying array of string type. Returns an error if the conversion is not possible.
func ToMapStringInterface ¶
ToMapStringInterface attempts a conversion from an interface to an underlying map string interface type. Returns an error if the conversion is not possible.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.