package
0.1.5
Repository: https://github.com/goexts/generic.git
Documentation: pkg.go.dev

# Functions

Append appends the element v to the end of Array[S] s.
Contains reports whether substr is within s.
ContainsArray reports whether any Unicode code points in chars are within s.
ContainsRune reports whether the Unicode code point r is within s.
No description provided by the author
Count counts the number of non-overlapping instances of substr in s.
CountArray counts the number of non-overlapping instances of c in s.
Cut slices s around the first instance of sep, returning the text before and after sep.
Equal reports whether a and b are the same length and contain the same runes.
EqualFoldRune reports whether s and t, interpreted as UTF-8 []runes, are equal under simple Unicode case-folding, which is a more general form of case-insensitivity.
Fields splits the Array s around each instance of one or more consecutive white space characters, as defined by unicode.IsSpace, returning a slice of subArrays of s or an empty slice if s contains only white space.
FieldsFunc splits the Array s at each run of Unicode code points c satisfying f(c) and returns an array of slices of s.
HasPrefix tests whether the Array[S] s begins with prefix.
HasSuffix tests whether the Array[S] s ends with suffix.
Index returns the index of the first instance of substr in s, or -1 if substr is not present in s.
IndexArray returns the index of the first instance of the runes point r, or -1 if rune is not present in s.
IndexByteRune returns the index of the first instance of c in s, or -1 if c is not present in s.
IndexRune returns the index of the first instance of the runes point r, or -1 if rune is not present in s.
InsertWith inserts v into s at the first index where fn(a, b) is true.
No description provided by the author
Join concatenates the elements of its first argument to create a single Array[S].
LastIndex returns the index of the last instance of substr in s, or -1 if substr is not present in s.
LastIndexArray returns the index of the last instance of c in s, or -1 if c is not present in s.
No description provided by the author
Read returns a slice of the Array[S] s beginning at offset and length limit.
RemoveWith removes the first index where fn(a, b) is true.
Repeat returns a new Array[S] consisting of count copies of the Array[S] s.
No description provided by the author
No description provided by the author
ToLowerRune returns s with all Unicode letters mapped to their lower case.
ToUpperRune returns s with all Unicode letters mapped to their upper case.

# Variables

ErrTooLarge is an error when number is too large than length.
ErrTooSmall is an error when number is too small than length.
ErrWrongIndex is an error when index is out of range.

# Type aliases

No description provided by the author
E is comparable type of slice element.
No description provided by the author