This section is empty.


This section is empty.


This section is empty.


type Set

type Set struct {
	// contains filtered or unexported fields

    Set is an implementation of ISet using the builtin map type. Set is threadsafe.

    func New

    func New(items ...interface{}) *Set

      New is the constructor for sets. It will pull from a reuseable memory pool if it can. Takes a list of items to initialize the set with.

      func (*Set) Add

      func (set *Set) Add(items ...interface{})

        Add will add the provided items to the set.

        func (*Set) All

        func (set *Set) All(items ...interface{}) bool

          All returns a bool indicating if all of the supplied items exist in the set.

          func (*Set) Clear

          func (set *Set) Clear()

            Clear will remove all items from the set.

            func (*Set) Dispose

            func (set *Set) Dispose()

              Dispose will add this set back into the pool.

              func (*Set) Exists

              func (set *Set) Exists(item interface{}) bool

                Exists returns a bool indicating if the given item exists in the set.

                func (*Set) Flatten

                func (set *Set) Flatten() []interface{}

                  Flatten will return a list of the items in the set.

                  func (*Set) Len

                  func (set *Set) Len() int64

                    Len returns the number of items in the set.

                    func (*Set) Remove

                    func (set *Set) Remove(items ...interface{})

                      Remove will remove the given items from the set.

                      Source Files