Documentation ¶
Index ¶
- func AddQueryParamLink(URL string, queryParam map[string]string) (string, error)
- func Concat(str ...string) string
- func DecodeBase64(s string) string
- func DecodeURL(s string) string
- func EncodeBase64(b []byte) string
- func EncodeURL(s string) string
- func FormatInt(i int) string
- func FormatInt64(i int64) string
- func FormatSliceInt(arr []int) []string
- func FormatSliceInt64(arr []int64) []string
- func GetFileFromPaths(filePaths []string) ([]byte, error)
- func GetLocalIP() string
- func HighestInt(arr ...int) int
- func InSliceInt64(target int64, arr []int64) bool
- func InSliceString(target string, arr []string) bool
- func LowestInt(arr ...int) int
- func Marshal(intf interface{}) ([]byte, error)
- func Max(a, b int64) int64
- func Min(a, b int64) int64
- func NewDecoder(body io.ReadCloser, intf interface{}) (err error)
- func ParseInt(s string) int
- func ParseInt64(s string) int64
- func ParseSliceInt(arr []string) []int
- func ParseSliceInt64(arr []string) []int64
- func Rand(min, max int) int
- func RandPermLimit(min, max int) []int
- func RemoveBracers(s string) string
- func RemoveBrackets(s string) string
- func RemoveParentheses(s string) string
- func RemoveSpaces(s string) string
- func SplitByCombineBy(s, splitBy, combineBy string) string
- func Unmarshal(data []byte, intf interface{}) (err error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AddQueryParamLink ¶
AddQueryParamLink will add queryParam from given link. It still return original URL if any err occurred.
func DecodeBase64 ¶
DecodeBase64 do decoding base64 w/o return err
func FormatInt64 ¶
FormatInt64 will format from int64 to string.
Alternatively can use strconv.FormatInt(i, 10)
func FormatSliceInt ¶
FormatSliceInt will format from slice int to slice string.
func FormatSliceInt64 ¶
FormatSliceInt64 will format from slice int64 to slice string.
func GetFileFromPaths ¶
GetFileFromPaths will find file from given paths. It will return error if not found.
func GetLocalIP ¶
func GetLocalIP() string
GetLocalIP returns the non loopback local IP of the host. Will return empty if not found / err.
func HighestInt ¶
HighestInt will return highest int from slice of int.
func InSliceInt64 ¶
InSliceInt64 check if the target(int64) exist inside given slice(int64).
func InSliceString ¶
InSliceString check if the target(string) exist inside given slice(string).
func NewDecoder ¶
func NewDecoder(body io.ReadCloser, intf interface{}) (err error)
NewDecoder decode given interface.
func ParseInt64 ¶
ParseInt64 will parse from string to int64 w/o return err.
func ParseSliceInt ¶
ParseSliceInt will parse from slice string to slice int.
func ParseSliceInt64 ¶
ParseSliceInt64 will parse from slice string to slice int64.
func RandPermLimit ¶
RandPermLimit give perm of random value from min-max.
func RemoveParentheses ¶
RemoveParentheses will remove "(" and ")".
func SplitByCombineBy ¶
SplitByCombineBy provides splitting then combining from given string.
Types ¶
This section is empty.