set

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: May 28, 2020 License: Apache-2.0 Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type StringSet

type StringSet map[string]struct{}

StringSet is a string set.

func NewStringSet

func NewStringSet(ss ...string) StringSet

NewStringSet builds a string set.

func (StringSet) Difference added in v1.0.0

func (s StringSet) Difference(rhs StringSet) StringSet

Difference returns the difference of two sets

func (StringSet) Exist

func (s StringSet) Exist(val string) bool

Exist checks whether `val` exists in `s`.

func (StringSet) Insert

func (s StringSet) Insert(val string)

Insert inserts `val` into `s`.

func (StringSet) Intersection

func (s StringSet) Intersection(rhs StringSet) StringSet

Intersection returns the intersection of two sets

func (StringSet) Remove added in v1.0.0

func (s StringSet) Remove(val string)

Remove removes `val` from `s`

Jump to

Keyboard shortcuts

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