set

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Nov 15, 2023 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Float32

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

Float32 struct

func NewFloat32

func NewFloat32(nums []float32) *Float32

NewFloat32 creates set struct

func (*Float32) Add

func (s *Float32) Add(num float32) *Float32

Add adds given item

func (*Float32) Clear

func (s *Float32) Clear()

Clear struct

func (*Float32) Contains

func (s *Float32) Contains(num float32) bool

Contains - Checks if item exists in set

func (*Float32) GetList

func (s *Float32) GetList() []float32

GetList - Get items

func (*Float32) Intersection

func (s *Float32) Intersection(s2 *Float32) *Float32

Intersection returns common items in S and S2

func (*Float32) Minus

func (s *Float32) Minus(s2 *Float32) *Float32

Minus - s.Minus(s2) : all of S but not in S2

func (*Float32) Remove

func (s *Float32) Remove(num float32) bool

Remove given item

func (*Float32) Size

func (s *Float32) Size() int

Size - Get size of set

func (*Float32) Subset

func (s *Float32) Subset(s2 *Float32) bool

Subset checks if S is subset of S2

func (*Float32) Superset

func (s *Float32) Superset(s2 *Float32) bool

Superset checks if S is superset of S2

func (*Float32) Union

func (s *Float32) Union(s2 *Float32) *Float32

Union returns all the items that are in S or in S2

type Float32Sync

type Float32Sync struct {
	sync.RWMutex
	// contains filtered or unexported fields
}

Float32Sync - struct

func NewFloat32Sync

func NewFloat32Sync(nums []float32) *Float32Sync

NewFloat32Sync creates new set

func (*Float32Sync) Add

func (s *Float32Sync) Add(num float32) *Float32Sync

Add an item

func (*Float32Sync) Clear

func (s *Float32Sync) Clear()

Clear set

func (*Float32Sync) Contains

func (s *Float32Sync) Contains(num float32) bool

Contains - Check if item exists in set

func (*Float32Sync) GetList

func (s *Float32Sync) GetList() []float32

GetList - Get set items

func (*Float32Sync) Intersection

func (s *Float32Sync) Intersection(s2 *Float32Sync) *Float32Sync

Intersection returns common items in S and S2

func (*Float32Sync) Minus

func (s *Float32Sync) Minus(s2 *Float32Sync) *Float32Sync

Minus - s.Minus(s2) : all of S but not in S2

func (*Float32Sync) Remove

func (s *Float32Sync) Remove(num float32) bool

Remove an item

func (*Float32Sync) Size

func (s *Float32Sync) Size() int

Size - Get size of set

func (*Float32Sync) Subset

func (s *Float32Sync) Subset(s2 *Float32Sync) bool

Subset checks if S is subset of S2

func (*Float32Sync) Superset

func (s *Float32Sync) Superset(s2 *Float32Sync) bool

Superset checks if S is superset of S2

func (*Float32Sync) Union

func (s *Float32Sync) Union(s2 *Float32Sync) *Float32Sync

Union returns all the items that are in S or in S2

type Float64

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

Float64 - struct

func NewFloat64

func NewFloat64(nums []float64) *Float64

NewFloat64 creates new set

func (*Float64) Add

func (s *Float64) Add(num float64) *Float64

Add an item

func (*Float64) Clear

func (s *Float64) Clear()

Clear set

func (*Float64) Contains

func (s *Float64) Contains(num float64) bool

Contains - Check if item exists in set

func (*Float64) GetList

func (s *Float64) GetList() []float64

GetList - Get set items

func (*Float64) Intersection

func (s *Float64) Intersection(s2 *Float64) *Float64

Intersection returns common items in S and S2

func (*Float64) Minus

func (s *Float64) Minus(s2 *Float64) *Float64

Minus - s.Minus(s2) : all of S but not in S2

func (*Float64) Remove

func (s *Float64) Remove(num float64) bool

Remove given item

func (*Float64) Size

func (s *Float64) Size() int

Size - Get size of set

func (*Float64) Subset

func (s *Float64) Subset(s2 *Float64) bool

Subset checks if S is subset of S2

func (*Float64) Superset

func (s *Float64) Superset(s2 *Float64) bool

Superset checks if S is superset of S2

func (*Float64) Union

func (s *Float64) Union(s2 *Float64) *Float64

Union returns all the items that are in S or in S2

type Float64Sync

type Float64Sync struct {
	sync.RWMutex
	// contains filtered or unexported fields
}

Float64Sync - struct

func NewFloat64Sync

func NewFloat64Sync(nums []float64) *Float64Sync

NewFloat64Sync creates set

func (*Float64Sync) Add

func (s *Float64Sync) Add(num float64) *Float64Sync

Add an item

func (*Float64Sync) Clear

func (s *Float64Sync) Clear()

Clear set

func (*Float64Sync) Contains

func (s *Float64Sync) Contains(num float64) bool

Contains - Check if item exists in set

func (*Float64Sync) GetList

func (s *Float64Sync) GetList() []float64

GetList - Get set items

func (*Float64Sync) Intersection

func (s *Float64Sync) Intersection(s2 *Float64Sync) *Float64Sync

Intersection get common items in S and S2

func (*Float64Sync) Minus

func (s *Float64Sync) Minus(s2 *Float64Sync) *Float64Sync

Minus - s.Minus(s2) : all of S but not in S2

func (*Float64Sync) Remove

func (s *Float64Sync) Remove(num float64) bool

Remove an item

func (*Float64Sync) Size

func (s *Float64Sync) Size() int

Size - Get size of set

func (*Float64Sync) Subset

func (s *Float64Sync) Subset(s2 *Float64Sync) bool

Subset checks if S is subset of S2

func (*Float64Sync) Superset

func (s *Float64Sync) Superset(s2 *Float64Sync) bool

Superset checks if S is superset of S2

func (*Float64Sync) Union

func (s *Float64Sync) Union(s2 *Float64Sync) *Float64Sync

Union returns all the items that are in S or in S2

type Int

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

Int - struct

func NewInt

func NewInt(nums []int) *Int

NewInt creates set

func (*Int) Add

func (s *Int) Add(num int) *Int

Add an item

func (*Int) Clear

func (s *Int) Clear()

Clear set

func (*Int) Contains

func (s *Int) Contains(num int) bool

Contains - Check if item exists in set

func (*Int) GetList

func (s *Int) GetList() []int

GetList - Get set items

func (*Int) Intersection

func (s *Int) Intersection(s2 *Int) *Int

Intersection - Common items in S and S2

func (*Int) Minus

func (s *Int) Minus(s2 *Int) *Int

Minus - s.Minus(s2) : all of S but not in S2

func (*Int) Remove

func (s *Int) Remove(num int) bool

Remove an item

func (*Int) Size

func (s *Int) Size() int

Size - Get size of set

func (*Int) Subset

func (s *Int) Subset(s2 *Int) bool

Subset checks if S is subset of S2

func (*Int) Superset

func (s *Int) Superset(s2 *Int) bool

Superset checks if S is superset of S2

func (*Int) Union

func (s *Int) Union(s2 *Int) *Int

Union returns all the items that are in S or in S2

type Int16

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

Int16 - struct

func NewInt16

func NewInt16(nums []int16) *Int16

NewInt16 creates

func (*Int16) Add

func (s *Int16) Add(num int16) *Int16

Add an item

func (*Int16) Clear

func (s *Int16) Clear()

Clear set

func (*Int16) Contains

func (s *Int16) Contains(num int16) bool

Contains - check if item exists in set

func (*Int16) GetList

func (s *Int16) GetList() []int16

GetList - Get set items

func (*Int16) Intersection

func (s *Int16) Intersection(s2 *Int16) *Int16

Intersection returns common items in S and S2

func (*Int16) Minus

func (s *Int16) Minus(s2 *Int16) *Int16

Minus - s.Minus(s2) : all of S but not in S2

func (*Int16) Remove

func (s *Int16) Remove(num int16) bool

Remove an item

func (*Int16) Size

func (s *Int16) Size() int

Size - GetList - Get size of set

func (*Int16) Subset

func (s *Int16) Subset(s2 *Int16) bool

Subset if checks if S is subset of S2

func (*Int16) Superset

func (s *Int16) Superset(s2 *Int16) bool

Superset checks if S is superset of S2

func (*Int16) Union

func (s *Int16) Union(s2 *Int16) *Int16

Union returns all the items that are in S or in S2

type Int16Sync

type Int16Sync struct {
	sync.RWMutex
	// contains filtered or unexported fields
}

Int16Sync - struct

func NewInt16Sync

func NewInt16Sync(nums []int16) *Int16Sync

NewInt16Sync creates set

func (*Int16Sync) Add

func (s *Int16Sync) Add(num int16) *Int16Sync

Add an item

func (*Int16Sync) Clear

func (s *Int16Sync) Clear()

Clear set

func (*Int16Sync) Contains

func (s *Int16Sync) Contains(num int16) bool

Contains - Check if item exists in set

func (*Int16Sync) GetList

func (s *Int16Sync) GetList() []int16

GetList - Get set items

func (*Int16Sync) Intersection

func (s *Int16Sync) Intersection(s2 *Int16Sync) *Int16Sync

Intersection returns common items in S and S2

func (*Int16Sync) Minus

func (s *Int16Sync) Minus(s2 *Int16Sync) *Int16Sync

Minus - s.Minus(s2) : all of S but not in S2

func (*Int16Sync) Remove

func (s *Int16Sync) Remove(num int16) bool

Remove an item

func (*Int16Sync) Size

func (s *Int16Sync) Size() int

Size - Get size of set

func (*Int16Sync) Subset

func (s *Int16Sync) Subset(s2 *Int16Sync) bool

Subset checks if S is subset of S2

func (*Int16Sync) Superset

func (s *Int16Sync) Superset(s2 *Int16Sync) bool

Superset checks if S is superset of S2

func (*Int16Sync) Union

func (s *Int16Sync) Union(s2 *Int16Sync) *Int16Sync

Union returns all the items that are in S or in S2

type Int32

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

Int32 - struct

func NewInt32

func NewInt32(nums []int32) *Int32

NewInt32 creates set

func (*Int32) Add

func (s *Int32) Add(num int32) *Int32

Add an item

func (*Int32) Clear

func (s *Int32) Clear()

Clear set

func (*Int32) Contains

func (s *Int32) Contains(num int32) bool

Contains - Check if item exists in set

func (*Int32) GetList

func (s *Int32) GetList() []int32

GetList - Get set items

func (*Int32) Intersection

func (s *Int32) Intersection(s2 *Int32) *Int32

Intersection returns common items in S and S2

func (*Int32) Minus

func (s *Int32) Minus(s2 *Int32) *Int32

Minus - s.Minus(s2) : all of S but not in S2

func (*Int32) Remove

func (s *Int32) Remove(num int32) bool

Remove an item

func (*Int32) Size

func (s *Int32) Size() int

Size - Get size of set

func (*Int32) Subset

func (s *Int32) Subset(s2 *Int32) bool

Subset checks if S is subset of S2

func (*Int32) Superset

func (s *Int32) Superset(s2 *Int32) bool

Superset checks if S is superset of S2

func (*Int32) Union

func (s *Int32) Union(s2 *Int32) *Int32

Union returns all the items that are in S or in S2

type Int32Sync

type Int32Sync struct {
	sync.RWMutex
	// contains filtered or unexported fields
}

Int32Sync - struct

func NewInt32Sync

func NewInt32Sync(nums []int32) *Int32Sync

NewInt32Sync creates set

func (*Int32Sync) Add

func (s *Int32Sync) Add(num int32) *Int32Sync

Add an item

func (*Int32Sync) Clear

func (s *Int32Sync) Clear()

Clear set

func (*Int32Sync) Contains

func (s *Int32Sync) Contains(num int32) bool

Contains - Check if item exists in set

func (*Int32Sync) GetList

func (s *Int32Sync) GetList() []int32

GetList - Get set items

func (*Int32Sync) Intersection

func (s *Int32Sync) Intersection(s2 *Int32Sync) *Int32Sync

Intersection returns common items in S and S2

func (*Int32Sync) Minus

func (s *Int32Sync) Minus(s2 *Int32Sync) *Int32Sync

Minus - s.Minus(s2) : all of S but not in S2

func (*Int32Sync) Remove

func (s *Int32Sync) Remove(num int32) bool

Remove an item

func (*Int32Sync) Size

func (s *Int32Sync) Size() int

Size - Get size of set

func (*Int32Sync) Subset

func (s *Int32Sync) Subset(s2 *Int32Sync) bool

Subset checks if S is subset of S2

func (*Int32Sync) Superset

func (s *Int32Sync) Superset(s2 *Int32Sync) bool

Superset checks if S is superset of S2

func (*Int32Sync) Union

func (s *Int32Sync) Union(s2 *Int32Sync) *Int32Sync

Union returns all the items that are in S or in S2

type Int64

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

Int64 - struct

func NewInt64

func NewInt64(nums []int64) *Int64

NewInt64 creates set

func (*Int64) Add

func (s *Int64) Add(num int64) *Int64

Add an item

func (*Int64) Clear

func (s *Int64) Clear()

Clear set

func (*Int64) Contains

func (s *Int64) Contains(num int64) bool

Contains - Check if item exists in set

func (*Int64) GetList

func (s *Int64) GetList() []int64

GetList - Get set items

func (*Int64) Intersection

func (s *Int64) Intersection(s2 *Int64) *Int64

Intersection returns common items in S and S2

func (*Int64) Minus

func (s *Int64) Minus(s2 *Int64) *Int64

Minus - s.Minus(s2) : all of S but not in S2

func (*Int64) Remove

func (s *Int64) Remove(num int64) bool

Remove an item

func (*Int64) Size

func (s *Int64) Size() int

Size - Get size of set

func (*Int64) Subset

func (s *Int64) Subset(s2 *Int64) bool

Subset checks if S is subset of S2

func (*Int64) Superset

func (s *Int64) Superset(s2 *Int64) bool

Superset checks if S is superset of S2

func (*Int64) Union

func (s *Int64) Union(s2 *Int64) *Int64

Union returns all the items that are in S or in S2

type Int64Sync

type Int64Sync struct {
	sync.RWMutex
	// contains filtered or unexported fields
}

Int64Sync - struct

func NewInt64Sync

func NewInt64Sync(nums []int64) *Int64Sync

NewInt64Sync creates set

func (*Int64Sync) Add

func (s *Int64Sync) Add(num int64) *Int64Sync

Add an item

func (*Int64Sync) Clear

func (s *Int64Sync) Clear()

Clear set

func (*Int64Sync) Contains

func (s *Int64Sync) Contains(num int64) bool

Contains - Check if item exists in set

func (*Int64Sync) GetList

func (s *Int64Sync) GetList() []int64

GetList - Get set items

func (*Int64Sync) Intersection

func (s *Int64Sync) Intersection(s2 *Int64Sync) *Int64Sync

Intersection returns common items in S and S2

func (*Int64Sync) Minus

func (s *Int64Sync) Minus(s2 *Int64Sync) *Int64Sync

Minus - s.Minus(s2) : all of S but not in S2

func (*Int64Sync) Remove

func (s *Int64Sync) Remove(num int64) bool

Remove an item

func (*Int64Sync) Size

func (s *Int64Sync) Size() int

Size - Get size of set

func (*Int64Sync) Subset

func (s *Int64Sync) Subset(s2 *Int64Sync) bool

Subset checks if S is subset of S2

func (*Int64Sync) Superset

func (s *Int64Sync) Superset(s2 *Int64Sync) bool

Superset checks if S is superset of S2

func (*Int64Sync) Union

func (s *Int64Sync) Union(s2 *Int64Sync) *Int64Sync

Union returns all the items that are in S or in S2

type Int8

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

Int8 - struct

func NewInt8

func NewInt8(nums []int8) *Int8

NewInt8 creates set

func (*Int8) Add

func (s *Int8) Add(num int8) *Int8

Add an item

func (*Int8) Clear

func (s *Int8) Clear()

Clear set

func (*Int8) Contains

func (s *Int8) Contains(num int8) bool

Contains - Check if item exists in set

func (*Int8) GetList

func (s *Int8) GetList() []int8

GetList - Get set items

func (*Int8) Intersection

func (s *Int8) Intersection(s2 *Int8) *Int8

Intersection returns common items in S and S2

func (*Int8) Minus

func (s *Int8) Minus(s2 *Int8) *Int8

Minus - s.Minus(s2) : all of S but not in S2

func (*Int8) Remove

func (s *Int8) Remove(num int8) bool

Remove an item

func (*Int8) Size

func (s *Int8) Size() int

Size - Get size of set

func (*Int8) Subset

func (s *Int8) Subset(s2 *Int8) bool

Subset checks if S is subset of S2

func (*Int8) Superset

func (s *Int8) Superset(s2 *Int8) bool

Superset checks if S is superset of S2

func (*Int8) Union

func (s *Int8) Union(s2 *Int8) *Int8

Union returns all the items that are in S or in S2

type Int8Sync

type Int8Sync struct {
	sync.RWMutex
	// contains filtered or unexported fields
}

Int8Sync - struct

func NewInt8Sync

func NewInt8Sync(nums []int8) *Int8Sync

NewInt8Sync creates set

func (*Int8Sync) Add

func (s *Int8Sync) Add(num int8) *Int8Sync

Add an item

func (*Int8Sync) Clear

func (s *Int8Sync) Clear()

Clear set

func (*Int8Sync) Contains

func (s *Int8Sync) Contains(num int8) bool

Contains - Check if item exists in set

func (*Int8Sync) GetList

func (s *Int8Sync) GetList() []int8

GetList - Get set items

func (*Int8Sync) Intersection

func (s *Int8Sync) Intersection(s2 *Int8Sync) *Int8Sync

Intersection returns common items in S and S2

func (*Int8Sync) Minus

func (s *Int8Sync) Minus(s2 *Int8Sync) *Int8Sync

Minus - s.Minus(s2) : all of S but not in S2

func (*Int8Sync) Remove

func (s *Int8Sync) Remove(num int8) bool

Remove an item

func (*Int8Sync) Size

func (s *Int8Sync) Size() int

Size - Get size of set

func (*Int8Sync) Subset

func (s *Int8Sync) Subset(s2 *Int8Sync) bool

Subset checks if S is subset of S2

func (*Int8Sync) Superset

func (s *Int8Sync) Superset(s2 *Int8Sync) bool

Superset checks if S is superset of S2

func (*Int8Sync) Union

func (s *Int8Sync) Union(s2 *Int8Sync) *Int8Sync

Union returns all the items that are in S or in S2

type IntSync

type IntSync struct {
	sync.RWMutex
	// contains filtered or unexported fields
}

IntSync - struct

func NewIntSync

func NewIntSync(nums []int) *IntSync

NewIntSync creates set

func (*IntSync) Add

func (s *IntSync) Add(num int) *IntSync

Add an item

func (*IntSync) Clear

func (s *IntSync) Clear()

Clear set

func (*IntSync) Contains

func (s *IntSync) Contains(num int) bool

Contains - Check if item exists in set

func (*IntSync) Intersection

func (s *IntSync) Intersection(s2 *IntSync) *IntSync

Intersection returns common items in S and S2

func (*IntSync) Minus

func (s *IntSync) Minus(s2 *IntSync) *IntSync

Minus - s.Minus(s2) : all of S but not in S2

func (*IntSync) Remove

func (s *IntSync) Remove(num int) bool

Remove an item

func (*IntSync) Size

func (s *IntSync) Size() int

Size - Get size of set

func (*IntSync) Subset

func (s *IntSync) Subset(s2 *IntSync) bool

Subset checks if S is subset of S2

func (*IntSync) Superset

func (s *IntSync) Superset(s2 *IntSync) bool

Superset checks if S is superset of S2

func (*IntSync) Union

func (s *IntSync) Union(s2 *IntSync) *IntSync

Union returns all the items that are in S or in S2

type Str

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

Str - struct

func NewStr

func NewStr(strList []string) *Str

NewStr creates set

func (*Str) Add

func (s *Str) Add(str string) *Str

Add an item

func (*Str) Clear

func (s *Str) Clear()

Clear set

func (*Str) Contains

func (s *Str) Contains(str string) bool

Contains - Check if item exists in set

func (*Str) GetList

func (s *Str) GetList() []string

GetList - Get set items

func (*Str) Intersection

func (s *Str) Intersection(s2 *Str) *Str

Intersection returns common items in S and S2

func (*Str) Minus

func (s *Str) Minus(s2 *Str) *Str

Minus - s.Minus(s2) : all of S but not in S2

func (*Str) Remove

func (s *Str) Remove(str string) bool

Remove an item

func (*Str) Size

func (s *Str) Size() int

Size - Get size of set

func (*Str) Subset

func (s *Str) Subset(s2 *Str) bool

Subset checks if S is subset of S2

func (*Str) Superset

func (s *Str) Superset(s2 *Str) bool

Superset checks if S is superset of S2

func (*Str) Union

func (s *Str) Union(s2 *Str) *Str

Union returns all the items that are in S or in S2

type StrSync

type StrSync struct {
	sync.RWMutex
	// contains filtered or unexported fields
}

StrSync - struct

func NewStrSync

func NewStrSync(strList []string) *StrSync

NewStrSync creates set

func (*StrSync) Add

func (s *StrSync) Add(str string) *StrSync

Add an item

func (*StrSync) Clear

func (s *StrSync) Clear()

Clear set

func (*StrSync) Contains

func (s *StrSync) Contains(str string) bool

Contains - Check if item exists in set

func (*StrSync) GetList

func (s *StrSync) GetList() []string

GetList - Get set items

func (*StrSync) Intersection

func (s *StrSync) Intersection(s2 *StrSync) *StrSync

Intersection returns common items in S and S2

func (*StrSync) Minus

func (s *StrSync) Minus(s2 *StrSync) *StrSync

Minus - s.Minus(s2) : all of S but not in S2

func (*StrSync) Remove

func (s *StrSync) Remove(str string) bool

Remove an item

func (*StrSync) Size

func (s *StrSync) Size() int

Size - Get size of set

func (*StrSync) Subset

func (s *StrSync) Subset(s2 *StrSync) bool

Subset checks if S is subset of S2

func (*StrSync) Superset

func (s *StrSync) Superset(s2 *StrSync) bool

Superset checks if S is superset of S2

func (*StrSync) Union

func (s *StrSync) Union(s2 *StrSync) *StrSync

Union returns all the items that are in S or in S2

type Uint

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

Uint - struct

func NewUint

func NewUint(nums []uint) *Uint

NewUint creates set

func (*Uint) Add

func (s *Uint) Add(num uint) *Uint

Add an item

func (*Uint) Clear

func (s *Uint) Clear()

Clear set

func (*Uint) Contains

func (s *Uint) Contains(num uint) bool

Contains - Check if item exists in set

func (*Uint) GetList

func (s *Uint) GetList() []uint

GetList - Get set items

func (*Uint) Intersection

func (s *Uint) Intersection(s2 *Uint) *Uint

Intersection returns common items in S and S2

func (*Uint) Minus

func (s *Uint) Minus(s2 *Uint) *Uint

Minus - s.Minus(s2) : all of S but not in S2

func (*Uint) Remove

func (s *Uint) Remove(num uint) bool

Remove an item

func (*Uint) Size

func (s *Uint) Size() int

Size - Get size of set

func (*Uint) Subset

func (s *Uint) Subset(s2 *Uint) bool

Subset checks if S is subset of S2

func (*Uint) Superset

func (s *Uint) Superset(s2 *Uint) bool

Superset checks if S is superset of S2

func (*Uint) Union

func (s *Uint) Union(s2 *Uint) *Uint

Union returns all the items that are in S or in S2

type Uint16

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

Uint16 - struct

func NewUint16

func NewUint16(nums []uint16) *Uint16

NewUint16 creates set

func (*Uint16) Add

func (s *Uint16) Add(num uint16) *Uint16

Add an item

func (*Uint16) Clear

func (s *Uint16) Clear()

Clear set

func (*Uint16) Contains

func (s *Uint16) Contains(num uint16) bool

Contains - Check if item exists in set

func (*Uint16) GetList

func (s *Uint16) GetList() []uint16

GetList - Get set items

func (*Uint16) Intersection

func (s *Uint16) Intersection(s2 *Uint16) *Uint16

Intersection returns common items in S and S2

func (*Uint16) Minus

func (s *Uint16) Minus(s2 *Uint16) *Uint16

Minus - s.Minus(s2) : all of S but not in S2

func (*Uint16) Remove

func (s *Uint16) Remove(num uint16) bool

Remove an item

func (*Uint16) Size

func (s *Uint16) Size() int

Size - Get size of set

func (*Uint16) Subset

func (s *Uint16) Subset(s2 *Uint16) bool

Subset checks if S is subset of S2

func (*Uint16) Superset

func (s *Uint16) Superset(s2 *Uint16) bool

Superset checks if S is superset of S2

func (*Uint16) Union

func (s *Uint16) Union(s2 *Uint16) *Uint16

Union returns all the items that are in S or in S2

type Uint16Sync

type Uint16Sync struct {
	sync.RWMutex
	// contains filtered or unexported fields
}

Uint16Sync - struct

func NewUint16Sync

func NewUint16Sync(nums []uint16) *Uint16Sync

NewUint16Sync creates set

func (*Uint16Sync) Add

func (s *Uint16Sync) Add(num uint16) *Uint16Sync

Add an item

func (*Uint16Sync) Clear

func (s *Uint16Sync) Clear()

Clear set

func (*Uint16Sync) Contains

func (s *Uint16Sync) Contains(num uint16) bool

Contains - Check if item exists in set

func (*Uint16Sync) GetList

func (s *Uint16Sync) GetList() []uint16

GetList - Get set items

func (*Uint16Sync) Intersection

func (s *Uint16Sync) Intersection(s2 *Uint16Sync) *Uint16Sync

Intersection returns common items in S and S2

func (*Uint16Sync) Minus

func (s *Uint16Sync) Minus(s2 *Uint16Sync) *Uint16Sync

Minus - s.Minus(s2) : all of S but not in S2

func (*Uint16Sync) Remove

func (s *Uint16Sync) Remove(num uint16) bool

Remove an item

func (*Uint16Sync) Size

func (s *Uint16Sync) Size() int

Size - Get size of set

func (*Uint16Sync) Subset

func (s *Uint16Sync) Subset(s2 *Uint16Sync) bool

Subset checks if S is subset of S2

func (*Uint16Sync) Superset

func (s *Uint16Sync) Superset(s2 *Uint16Sync) bool

Superset checks if S is superset of S2

func (*Uint16Sync) Union

func (s *Uint16Sync) Union(s2 *Uint16Sync) *Uint16Sync

Union returns all the items that are in S or in S2

type Uint32

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

Uint32 - struct

func NewUint32

func NewUint32(nums []uint32) *Uint32

NewUint32 creates set

func (*Uint32) Add

func (s *Uint32) Add(num uint32) *Uint32

Add an item

func (*Uint32) Clear

func (s *Uint32) Clear()

Clear set

func (*Uint32) Contains

func (s *Uint32) Contains(num uint32) bool

Contains - Check if item exists in set

func (*Uint32) GetList

func (s *Uint32) GetList() []uint32

GetList - Get set items

func (*Uint32) Intersection

func (s *Uint32) Intersection(s2 *Uint32) *Uint32

Intersection returns common items in S and S2

func (*Uint32) Minus

func (s *Uint32) Minus(s2 *Uint32) *Uint32

Minus - s.Minus(s2) : all of S but not in S2

func (*Uint32) Remove

func (s *Uint32) Remove(num uint32) bool

Remove an item

func (*Uint32) Size

func (s *Uint32) Size() int

Size - Get size of set

func (*Uint32) Subset

func (s *Uint32) Subset(s2 *Uint32) bool

Subset checks if S is subset of S2

func (*Uint32) Superset

func (s *Uint32) Superset(s2 *Uint32) bool

Superset checks if S is superset of S2

func (*Uint32) Union

func (s *Uint32) Union(s2 *Uint32) *Uint32

Union returns all the items that are in S or in S2

type Uint32Sync

type Uint32Sync struct {
	sync.RWMutex
	// contains filtered or unexported fields
}

Uint32Sync - struct

func NewUint32Sync

func NewUint32Sync(nums []uint32) *Uint32Sync

NewUint32Sync create set

func (*Uint32Sync) Add

func (s *Uint32Sync) Add(num uint32) *Uint32Sync

Add an item

func (*Uint32Sync) Clear

func (s *Uint32Sync) Clear()

Clear set

func (*Uint32Sync) Contains

func (s *Uint32Sync) Contains(num uint32) bool

Contains - Check if item exists in set

func (*Uint32Sync) GetList

func (s *Uint32Sync) GetList() []uint32

GetList - Get set items

func (*Uint32Sync) Intersection

func (s *Uint32Sync) Intersection(s2 *Uint32Sync) *Uint32Sync

Intersection returns common items in S and S2

func (*Uint32Sync) Minus

func (s *Uint32Sync) Minus(s2 *Uint32Sync) *Uint32Sync

Minus - s.Minus(s2) : all of S but not in S2

func (*Uint32Sync) Remove

func (s *Uint32Sync) Remove(num uint32) bool

Remove an item

func (*Uint32Sync) Size

func (s *Uint32Sync) Size() int

Size - Get size of set

func (*Uint32Sync) Subset

func (s *Uint32Sync) Subset(s2 *Uint32Sync) bool

Subset checks if S is subset of S2

func (*Uint32Sync) Superset

func (s *Uint32Sync) Superset(s2 *Uint32Sync) bool

Superset checks if S is superset of S2

func (*Uint32Sync) Union

func (s *Uint32Sync) Union(s2 *Uint32Sync) *Uint32Sync

Union returns all the items that are in S or in S2

type Uint64

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

Uint64 - struct

func NewUint64

func NewUint64(nums []uint64) *Uint64

NewUint64 creates set

func (*Uint64) Add

func (s *Uint64) Add(num uint64) *Uint64

Add an item

func (*Uint64) Clear

func (s *Uint64) Clear()

Clear set

func (*Uint64) Contains

func (s *Uint64) Contains(num uint64) bool

Contains - Check if item exists in set

func (*Uint64) GetList

func (s *Uint64) GetList() []uint64

GetList - Get set items

func (*Uint64) Intersection

func (s *Uint64) Intersection(s2 *Uint64) *Uint64

Intersection returns common items in S and S2

func (*Uint64) Minus

func (s *Uint64) Minus(s2 *Uint64) *Uint64

Minus - s.Minus(s2) : all of S but not in S2

func (*Uint64) Remove

func (s *Uint64) Remove(num uint64) bool

Remove an item

func (*Uint64) Size

func (s *Uint64) Size() int

Size - Get size of set

func (*Uint64) Subset

func (s *Uint64) Subset(s2 *Uint64) bool

Subset checks if S is subset of S2

func (*Uint64) Superset

func (s *Uint64) Superset(s2 *Uint64) bool

Superset checks if S is superset of S2

func (*Uint64) Union

func (s *Uint64) Union(s2 *Uint64) *Uint64

Union returns all the items that are in S or in S2

type Uint64Sync

type Uint64Sync struct {
	sync.RWMutex
	// contains filtered or unexported fields
}

Uint64Sync - struct

func NewUint64Sync

func NewUint64Sync(nums []uint64) *Uint64Sync

NewUint64Sync creates set

func (*Uint64Sync) Add

func (s *Uint64Sync) Add(num uint64) *Uint64Sync

Add an item

func (*Uint64Sync) Clear

func (s *Uint64Sync) Clear()

Clear set

func (*Uint64Sync) Contains

func (s *Uint64Sync) Contains(num uint64) bool

Contains - Check if item exists in set

func (*Uint64Sync) GetList

func (s *Uint64Sync) GetList() []uint64

GetList - Get set items

func (*Uint64Sync) Intersection

func (s *Uint64Sync) Intersection(s2 *Uint64Sync) *Uint64Sync

Intersection returns common items in S and S2

func (*Uint64Sync) Minus

func (s *Uint64Sync) Minus(s2 *Uint64Sync) *Uint64Sync

Minus - s.Minus(s2) : all of S but not in S2

func (*Uint64Sync) Remove

func (s *Uint64Sync) Remove(num uint64) bool

Remove an item

func (*Uint64Sync) Size

func (s *Uint64Sync) Size() int

Size - Get size of set

func (*Uint64Sync) Subset

func (s *Uint64Sync) Subset(s2 *Uint64Sync) bool

Subset checks if S is subset of S2

func (*Uint64Sync) Superset

func (s *Uint64Sync) Superset(s2 *Uint64Sync) bool

Superset checks if S is superset of S2

func (*Uint64Sync) Union

func (s *Uint64Sync) Union(s2 *Uint64Sync) *Uint64Sync

Union returns all the items that are in S or in S2

type Uint8

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

Uint8 - struct

func NewUint8

func NewUint8(nums []uint8) *Uint8

NewUint8 creates set

func (*Uint8) Add

func (s *Uint8) Add(num uint8) *Uint8

Add an item

func (*Uint8) Clear

func (s *Uint8) Clear()

Clear set

func (*Uint8) Contains

func (s *Uint8) Contains(num uint8) bool

Contains - Check if item exists in set

func (*Uint8) GetList

func (s *Uint8) GetList() []uint8

GetList - Get set items

func (*Uint8) Intersection

func (s *Uint8) Intersection(s2 *Uint8) *Uint8

Intersection returns common items in S and S2

func (*Uint8) Minus

func (s *Uint8) Minus(s2 *Uint8) *Uint8

Minus - s.Minus(s2) : all of S but not in S2

func (*Uint8) Remove

func (s *Uint8) Remove(num uint8) bool

Remove an item

func (*Uint8) Size

func (s *Uint8) Size() int

Size - Get size of set

func (*Uint8) Subset

func (s *Uint8) Subset(s2 *Uint8) bool

Subset checks if S is subset of S2

func (*Uint8) Superset

func (s *Uint8) Superset(s2 *Uint8) bool

Superset checks if S is superset of S2

func (*Uint8) Union

func (s *Uint8) Union(s2 *Uint8) *Uint8

Union returns all the items that are in S or in S2

type Uint8Sync

type Uint8Sync struct {
	sync.RWMutex
	// contains filtered or unexported fields
}

Uint8Sync - struct

func NewUint8Sync

func NewUint8Sync(nums []uint8) *Uint8Sync

NewUint8Sync creates set

func (*Uint8Sync) Add

func (s *Uint8Sync) Add(num uint8) *Uint8Sync

Add an item

func (*Uint8Sync) Clear

func (s *Uint8Sync) Clear()

Clear set

func (*Uint8Sync) Contains

func (s *Uint8Sync) Contains(num uint8) bool

Contains - Check if item exists in set

func (*Uint8Sync) GetList

func (s *Uint8Sync) GetList() []uint8

GetList - Get set items

func (*Uint8Sync) Intersection

func (s *Uint8Sync) Intersection(s2 *Uint8Sync) *Uint8Sync

Intersection returns common items in S and S2

func (*Uint8Sync) Minus

func (s *Uint8Sync) Minus(s2 *Uint8Sync) *Uint8Sync

Minus - s.Minus(s2) : all of S but not in S2

func (*Uint8Sync) Remove

func (s *Uint8Sync) Remove(num uint8) bool

Remove an item

func (*Uint8Sync) Size

func (s *Uint8Sync) Size() int

Size - Get size of set

func (*Uint8Sync) Subset

func (s *Uint8Sync) Subset(s2 *Uint8Sync) bool

Subset checks if S is subset of S2

func (*Uint8Sync) Superset

func (s *Uint8Sync) Superset(s2 *Uint8Sync) bool

Superset checks if S is superset of S2

func (*Uint8Sync) Union

func (s *Uint8Sync) Union(s2 *Uint8Sync) *Uint8Sync

Union returns all the items that are in S or in S2

type UintSync

type UintSync struct {
	sync.RWMutex
	// contains filtered or unexported fields
}

UintSync - struct

func NewUintSync

func NewUintSync(nums []uint) *UintSync

NewUintSync creates set

func (*UintSync) Add

func (s *UintSync) Add(num uint) *UintSync

Add an item

func (*UintSync) Clear

func (s *UintSync) Clear()

Clear set

func (*UintSync) Contains

func (s *UintSync) Contains(num uint) bool

Contains - Check if item exists in set

func (*UintSync) GetList

func (s *UintSync) GetList() []uint

GetList - Get set items

func (*UintSync) Intersection

func (s *UintSync) Intersection(s2 *UintSync) *UintSync

Intersection returns common items in S and S2

func (*UintSync) Minus

func (s *UintSync) Minus(s2 *UintSync) *UintSync

Minus - s.Minus(s2) : all of S but not in S2

func (*UintSync) Remove

func (s *UintSync) Remove(num uint) bool

Remove an item

func (*UintSync) Size

func (s *UintSync) Size() int

Size - Get size of set

func (*UintSync) Subset

func (s *UintSync) Subset(s2 *UintSync) bool

Subset checks if S is subset of S2

func (*UintSync) Superset

func (s *UintSync) Superset(s2 *UintSync) bool

Superset checks if S is superset of S2

func (*UintSync) Union

func (s *UintSync) Union(s2 *UintSync) *UintSync

Union returns all the items that are in S or in S2

Jump to

Keyboard shortcuts

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