Documentation ¶
Index ¶
- Variables
- func ArrayToMap(slice []string) map[string]struct{}
- func CheckPalindrome(str string) bool
- func ContainsMultiple(lower bool, s string, substring ...string) bool
- func CountLines(str string) int
- func CreateJSON(values []string) string
- func DiceCoefficient(string1, string2 string) float64
- func ExtractString(data, first, last string) string
- func GetFirstRune(data string) rune
- func HasPrefixes(prefixs []string, target string) bool
- func Indexes(s, chs string) []int
- func IsASCII(s string) bool
- func IsASCIIRune(r rune) bool
- func IsAlpha(str string) bool
- func IsBlank(str string) bool
- func IsLower(s string) bool
- func IsUpper(s string) bool
- func JaroDistance(str1, str2 string) float64
- func Join(strs ...string) string
- func LevenshteinDistance(str1, str2 string) int
- func Pad(word, v string, n int) string
- func RemoveFromString(data string, i int) string
- func RemoveNonASCII(str string) string
- func ReplaceAtIndex(str, replacement string, index int) string
- func ReverseString(str string) string
- func Split(data io.Reader) []string
- func ToByte(slice []string, separator string) []byte
- func Trim(str string) string
- func TrimStrings(vs []string) []string
Constants ¶
This section is empty.
Variables ¶
var BOMS = [][]byte{
{0xef, 0xbb, 0xbf},
{0xfe, 0xff},
{0xff, 0xfe},
{0x00, 0x00, 0xfe, 0xff},
{0xff, 0xfe, 0x00, 0x00},
}
var CUTSET = " \n\r\t"
Functions ¶
func ArrayToMap ¶ added in v0.0.74
func CheckPalindrome ¶ added in v0.0.19
CheckPalindrome is delegated to verify if the given string is palindrome
func ContainsMultiple ¶ added in v0.0.28
ContainsMultiple is delegated to verify if the given string 's' contains all the 'substring' present
func CountLines ¶
CountLines return the number of lines in the given string
func CreateJSON ¶
CreateJSON is delegated to create a simple json object for the key pair in input
func DiceCoefficient ¶ added in v0.0.22
DiceCoefficient is bigram position dependent implementation of the Dice coefficient
func ExtractString ¶
ExtractString is delegated to filter the content of the given data delimited by 'first' and 'last' string
func GetFirstRune ¶ added in v0.0.41
func HasPrefixes ¶ added in v0.0.102
func IsASCIIRune ¶ added in v0.0.4
IsASCIIRune is delegated to verify if the given character is ASCII compliant
func IsBlank ¶ added in v0.0.6
IsBlank is delegated to verify that the string does not contain only empty char
func JaroDistance ¶ added in v0.0.22
JaroDistance is delegated to calculate the Jaro distance from the two given string
func LevenshteinDistance ¶ added in v0.0.22
LevenshteinDistance is an optimized version for calculate the Levenshtein distance
func RemoveFromString ¶
RemoveFromString Remove a given character in position i from the input string
func RemoveNonASCII ¶ added in v0.0.5
RemoveNonASCII is delegated to clean the text from the NON ASCII character
func ReplaceAtIndex ¶ added in v0.0.3
ReplaceAtIndex is delegated to replace the character related to the index with the input rune
func ReverseString ¶ added in v0.0.19
ReverseString is delegated to return the reverse of the input string
func Trim ¶ added in v0.0.6
Trim is delegated to remove the initial, final whitespace and the double whitespace present in the data
func TrimStrings ¶ added in v0.0.101
Types ¶
This section is empty.