Documentation
¶
Index ¶
- func Chop(l uint) func(str string) []string
- func Contains(substr string) func(string) bool
- func EqLen(l uint) func(str string) bool
- func HasPrefix(prefix string) func(str string) bool
- func HasSuffix(suffix string) func(str string) bool
- func InSet(set []string) func(str string) bool
- func Len(str string) int
- func Longer(l uint) func(str string) bool
- func Match(re string) func(str string) bool
- func NotContains(substr string) func(string) bool
- func NotHasPrefix(prefix string) func(str string) bool
- func NotHasSuffix(suffix string) func(str string) bool
- func NotInSet(set []string) func(str string) bool
- func Prefix(prefix string) func(str string) string
- func Replace(oldStr, newStr string, n int) func(str string) string
- func ReplaceTable(replaceTable map[string]string) func(str string) string
- func Shorter(l uint) func(str string) bool
- func Split(delim string, n int) func(str string) []string
- func StrictLess(a, b string) bool
- func Suffix(suffix string) func(str string) string
- func TrimPrefix(prefix string) func(str string) string
- func TrimSuffix(suffix string) func(str string) string
- type CountItems
- func (items CountItems) Copy() CountItems
- func (items CountItems) Counter() Counter
- func (items CountItems) Filter(pred func(item CounterItem) bool) CountItems
- func (items CountItems) Find(pred func(item CounterItem) bool) (CounterItem, bool)
- func (items CountItems) Len() int
- func (items CountItems) New() CountItems
- func (items CountItems) Sort() CountItems
- func (items CountItems) SortIncr() CountItems
- func (items CountItems) Top(n uint) CountItems
- func (items CountItems) ValuesVec() Vector
- type Counter
- func (counter Counter) Add(strs ...string) Counter
- func (counter Counter) Copy() Counter
- func (counter Counter) Counts() []uint
- func (counter Counter) Exclude(strs ...string) Counter
- func (counter Counter) Filter(pred func(item CounterItem) bool) Counter
- func (counter Counter) Merge(c Counter) Counter
- func (counter Counter) MutAdd(strs ...string) Counter
- func (counter Counter) MutFilter(pred func(item CounterItem) bool) Counter
- func (counter Counter) MutMerge(c Counter) Counter
- func (counter Counter) New() Counter
- func (counter Counter) TopOne() CounterItem
- func (counter Counter) Values() Vector
- type CounterItem
- type Vector
- func (vector Vector) Append(strs ...string) Vector
- func (vector Vector) Classify(key func(str string) string) map[string][]string
- func (vector Vector) Contains(str string) bool
- func (vector Vector) Copy() Vector
- func (vector Vector) Count() map[string]uint
- func (vector Vector) Delete(i int) Vector
- func (vector Vector) Eq(v Vector) bool
- func (vector Vector) Filter(pred func(str string) bool) Vector
- func (vector Vector) FirstFiltered(pred func(str string) bool) (string, bool)
- func (vector Vector) FirstNonEmpty() string
- func (vector Vector) Fold(start string, op func(acc, str string) string) string
- func (vector Vector) Get(i int) string
- func (vector Vector) GetDefault(i int, defaultStr string) string
- func (vector Vector) Head(n uint) Vector
- func (vector Vector) Inverse() Vector
- func (vector Vector) Join(delim string) string
- func (vector Vector) Len() int
- func (vector Vector) Map(op func(str string) string) Vector
- func (vector Vector) New() Vector
- func (vector Vector) NonEmpty() Vector
- func (vector Vector) Populate(op func(str string) []string) Vector
- func (vector Vector) Sample(n uint) Vector
- func (vector Vector) Shuffle() Vector
- func (vector Vector) Slice() []string
- func (vector Vector) SortByKey(key func(str string) int) Vector
- func (vector Vector) SortByLess(less func(a, b string) bool) Vector
- func (vector Vector) Tail(n uint) Vector
- func (vector Vector) ToErrs() []error
- func (vector Vector) Top(n uint) Vector
- func (vector Vector) Unique() Vector
- func (vector Vector) WriteToChan(ch chan<- string)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NotContains ¶ added in v0.2.2
func NotHasPrefix ¶ added in v0.2.4
func NotHasSuffix ¶ added in v0.2.4
func ReplaceTable ¶ added in v0.3.1
func StrictLess ¶ added in v0.2.2
func TrimPrefix ¶ added in v0.2.2
func TrimSuffix ¶ added in v0.2.2
Types ¶
type CountItems ¶ added in v0.3.0
type CountItems []CounterItem
func (CountItems) Copy ¶ added in v0.3.0
func (items CountItems) Copy() CountItems
func (CountItems) Counter ¶ added in v0.3.0
func (items CountItems) Counter() Counter
func (CountItems) Filter ¶ added in v0.3.0
func (items CountItems) Filter(pred func(item CounterItem) bool) CountItems
func (CountItems) Find ¶ added in v0.3.0
func (items CountItems) Find(pred func(item CounterItem) bool) (CounterItem, bool)
func (CountItems) Len ¶ added in v0.3.0
func (items CountItems) Len() int
func (CountItems) New ¶ added in v0.3.0
func (items CountItems) New() CountItems
func (CountItems) Sort ¶ added in v0.3.0
func (items CountItems) Sort() CountItems
func (CountItems) SortIncr ¶ added in v0.3.0
func (items CountItems) SortIncr() CountItems
func (CountItems) Top ¶ added in v0.3.0
func (items CountItems) Top(n uint) CountItems
func (CountItems) ValuesVec ¶ added in v0.3.0
func (items CountItems) ValuesVec() Vector
type Counter ¶ added in v0.3.0
func NewCounter ¶ added in v0.3.0
func (Counter) Filter ¶ added in v0.3.0
func (counter Counter) Filter(pred func(item CounterItem) bool) Counter
func (Counter) MutFilter ¶ added in v0.3.0
func (counter Counter) MutFilter(pred func(item CounterItem) bool) Counter
func (Counter) TopOne ¶ added in v0.3.0
func (counter Counter) TopOne() CounterItem
type CounterItem ¶ added in v0.3.0
type Vector ¶
type Vector []string
func (Vector) FirstFiltered ¶ added in v0.2.2
func (Vector) FirstNonEmpty ¶
func (Vector) GetDefault ¶ added in v0.3.3
func (Vector) SortByLess ¶ added in v0.2.2
func (Vector) WriteToChan ¶
Click to show internal directories.
Click to hide internal directories.