set

package
v1.0.2 Latest Latest
Warning

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

Go to latest
Published: May 19, 2022 License: CC0-1.0 Imports: 3 Imported by: 3

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type SafeSet added in v1.0.1

type SafeSet[K comparable] struct {
	// contains filtered or unexported fields
}

func FromListSafe added in v1.0.1

func FromListSafe[K comparable](list []K) *SafeSet[K]

func NewSafe added in v1.0.1

func NewSafe[K comparable]() *SafeSet[K]

func (*SafeSet[K]) Add added in v1.0.1

func (s *SafeSet[K]) Add(value K)

func (*SafeSet[K]) Copy added in v1.0.1

func (s *SafeSet[K]) Copy() *SafeSet[K]

func (*SafeSet[K]) Delete added in v1.0.1

func (s *SafeSet[K]) Delete(value K)

func (*SafeSet[K]) Difference added in v1.0.1

func (s *SafeSet[K]) Difference(other *SafeSet[K]) *SafeSet[K]

func (*SafeSet[K]) Eq added in v1.0.2

func (s *SafeSet[K]) Eq(other *SafeSet[K]) bool

func (*SafeSet[K]) Has added in v1.0.1

func (s *SafeSet[K]) Has(value K) bool

func (*SafeSet[K]) Intersection added in v1.0.1

func (s *SafeSet[K]) Intersection(other *SafeSet[K]) *SafeSet[K]

func (*SafeSet[K]) Iter added in v1.0.1

func (s *SafeSet[K]) Iter(callback func(value K))

func (*SafeSet[K]) IterIndex added in v1.0.1

func (s *SafeSet[K]) IterIndex(callback func(value K, i int))

func (*SafeSet[K]) List added in v1.0.1

func (s *SafeSet[K]) List() []K

func (*SafeSet[K]) Size added in v1.0.1

func (s *SafeSet[K]) Size() int

func (*SafeSet[K]) String added in v1.0.2

func (s *SafeSet[K]) String() string

func (*SafeSet[K]) Subtract added in v1.0.1

func (s *SafeSet[K]) Subtract(other *SafeSet[K]) *SafeSet[K]

func (*SafeSet[K]) Union added in v1.0.1

func (s *SafeSet[K]) Union(other *SafeSet[K]) *SafeSet[K]

type Set

type Set[K comparable] struct {
	// contains filtered or unexported fields
}

func FromList

func FromList[K comparable](list []K) *Set[K]

func New

func New[K comparable]() *Set[K]

func (*Set[K]) Add

func (s *Set[K]) Add(value K)

func (*Set[K]) Copy

func (s *Set[K]) Copy() *Set[K]

func (*Set[K]) Delete

func (s *Set[K]) Delete(value K)

func (*Set[K]) Difference

func (s *Set[K]) Difference(other *Set[K]) *Set[K]

func (*Set[K]) Eq added in v1.0.2

func (s *Set[K]) Eq(other *Set[K]) bool

func (*Set[K]) Has

func (s *Set[K]) Has(value K) bool

func (*Set[K]) Intersection

func (s *Set[K]) Intersection(other *Set[K]) *Set[K]

func (*Set[K]) Iter

func (s *Set[K]) Iter(callback func(value K))

func (*Set[K]) IterIndex

func (s *Set[K]) IterIndex(callback func(value K, i int))

func (*Set[K]) List

func (s *Set[K]) List() []K

func (*Set[K]) Size

func (s *Set[K]) Size() int

func (*Set[K]) String added in v1.0.2

func (s *Set[K]) String() string

func (*Set[K]) Subtract

func (s *Set[K]) Subtract(other *Set[K]) *Set[K]

func (*Set[K]) Union

func (s *Set[K]) Union(other *Set[K]) *Set[K]

Jump to

Keyboard shortcuts

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