sets

package
v1.3.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 29, 2021 License: Apache-2.0 Imports: 0 Imported by: 5

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type IntSet

type IntSet struct {
	// contains filtered or unexported fields
}

func NewIntSet

func NewIntSet() *IntSet

func (*IntSet) Add

func (set *IntSet) Add(s int) bool

func (*IntSet) Contains

func (set *IntSet) Contains(s int) bool

func (*IntSet) Remove

func (set *IntSet) Remove(s int)

func (*IntSet) Size

func (set *IntSet) Size() int

type StringSet

type StringSet struct {
	Set map[string]bool
}

func NewStringSet

func NewStringSet() *StringSet

func (*StringSet) Add

func (set *StringSet) Add(s string) bool

func (*StringSet) Contains

func (set *StringSet) Contains(s string) bool

func (*StringSet) Difference

func (set *StringSet) Difference(set1 *StringSet) *StringSet

func (*StringSet) FromSlice

func (set *StringSet) FromSlice(slice []string)

func (*StringSet) Intersection

func (set *StringSet) Intersection(set1 *StringSet) *StringSet

func (*StringSet) Len

func (set *StringSet) Len() int

func (*StringSet) Remove

func (set *StringSet) Remove(s string)

func (*StringSet) ToSlice

func (set *StringSet) ToSlice() (slice []string)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL