Documentation ¶
Index ¶
- type RandASCII
- type StringsExtended
- func (s *StringsExtended) GetStringArrayFromJSON(jsonFile io.Reader, arrayName ...string) ([]string, error)
- func (s *StringsExtended) GetStringArrayFromJSONBytes(jsonBytes []byte, arrayName ...string) ([]string, error)
- func (s *StringsExtended) MakeSpongeBobCase(str string, startLower ...bool) string
- type UniqueID
- type YTPlayer
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type RandASCII ¶
type RandASCII struct {
// contains filtered or unexported fields
}
RandASCII generates a random string or char
func (*RandASCII) GetRandomAlphanumChar ¶
GetRandomAlphanumChar returns a random alphanumeric ASCII character
func (*RandASCII) GetRandomAlphanumString ¶
GetRandomString returns a random alphanumeric ASCII string of a given length
func (*RandASCII) GetRandomChar ¶
GetRandomChar returns a random (alphanumeric and special) ASCII character
func (*RandASCII) GetRandomString ¶
GetRandomString returns a random ASCII string of a given length
type StringsExtended ¶
type StringsExtended struct{}
StringsExtended has string operations that are not in the "strings" module
func NewExtendedStrings ¶
func NewExtendedStrings() *StringsExtended
NewExtendedStrings returns a new StringsExtended instance
func (*StringsExtended) GetStringArrayFromJSON ¶
func (s *StringsExtended) GetStringArrayFromJSON(jsonFile io.Reader, arrayName ...string) ([]string, error)
GetStringArrayFromJSON returns a string array with a specific name from a json file if an array name is provided it returns that specific array, otherwise the whole json is an array :)
func (*StringsExtended) GetStringArrayFromJSONBytes ¶
func (s *StringsExtended) GetStringArrayFromJSONBytes(jsonBytes []byte, arrayName ...string) ([]string, error)
GetStringArrayFromJSONBytes is same as GetStringArrayFromJSON but it receives a byte array that has the JSON data instead
func (*StringsExtended) MakeSpongeBobCase ¶
func (s *StringsExtended) MakeSpongeBobCase(str string, startLower ...bool) string
MakeSpongeBobCase returns the given in SpOnGeBoBcAsE also it receives an optional flag to start string with lower case, default value = false
type UniqueID ¶
type UniqueID struct {
// contains filtered or unexported fields
}
UniqueID is a wrapping for a somehow unique id generator
func NewUniqueID ¶
NewUniqueID returns a new UniqueID instance
func (*UniqueID) GetUniqueString ¶
GetUniqueString returns a unique string generated from the current timestamp mixed with some random characters and adds an additional random chars to it if needed :)
type YTPlayer ¶
type YTPlayer struct {
// contains filtered or unexported fields
}
YTPlayer plays youtube songs using the system's default browser
func NewYTPlayer ¶
NewYTPlayer returns a new YTPlayer instance
func (*YTPlayer) PlayRandomSong ¶
PlayRandomSong plays a random song from the given music source