Documentation
¶
Index ¶
- type StringSet
- func (s StringSet) Add(values ...string)
- func (s StringSet) Contains(value string) bool
- func (s StringSet) Difference(other StringSet) StringSet
- func (s StringSet) DifferenceList(values ...string) StringSet
- func (s StringSet) DifferenceMap(values map[string]string) StringSet
- func (s StringSet) Intersection(other StringSet) StringSet
- func (s StringSet) IntersectionList(values ...string) StringSet
- func (s StringSet) IntersectionMap(values map[string]string) StringSet
- func (s StringSet) List() []string
- func (s StringSet) Remove(values ...string)
- func (s StringSet) SymmetricDifference(other StringSet) StringSet
- func (s StringSet) SymmetricDifferenceList(values ...string) StringSet
- func (s StringSet) SymmetricDifferenceMap(values map[string]string) StringSet
- func (s StringSet) Union(other StringSet) StringSet
- func (s StringSet) UnionList(values ...string) StringSet
- func (s StringSet) UnionMap(values map[string]string) StringSet
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type StringSet ¶
type StringSet map[string]struct{}
func NewStringSet ¶
NewStringSet creates a new string set with optional input values.
func NewStringSetFromMap ¶
NewStringSetFromMap creates a new string set from a map.
func (StringSet) Difference ¶
Difference returns string set that consists of items that are in set and and not in second set.
func (StringSet) DifferenceList ¶
DifferenceList returns string set that consists of items that are in set and and not in list.
func (StringSet) DifferenceMap ¶
DifferenceMap returns string set that consists of items that are in set and and not in map.
func (StringSet) Intersection ¶
Intersection returns string set that consists of items that are in both sets.
func (StringSet) IntersectionList ¶
IntersectonList returns string set that consists of items that are in both set and list.
func (StringSet) IntersectionMap ¶
IntersectonMap returns string set that consists of items that are in both set and map.
func (StringSet) SymmetricDifference ¶
SymmetricDifference returns string set that consists of items that are not in both sets.
func (StringSet) SymmetricDifferenceList ¶
SymmetricDifferenceList returns string set that consists of items that are not in set and list.
func (StringSet) SymmetricDifferenceMap ¶
SymmetricDifferenceMap returns string set that consists of items that are not in set and map.
func (StringSet) Union ¶
Union returns string set that consists of items that are in either of the 2 sets.