Documentation ¶
Index ¶
- type HashSet
- type HashSetAtomic
- func (set *HashSetAtomic) Add(item string)
- func (set *HashSetAtomic) Clear()
- func (set *HashSetAtomic) ClearFast()
- func (set *HashSetAtomic) Contains(item uint32) bool
- func (set *HashSetAtomic) ContainsString(item string) bool
- func (set *HashSetAtomic) LoadFromArray(data []string)
- func (set *HashSetAtomic) LoadFromJSONArray(path string)
- func (set *HashSetAtomic) LoadFromRaw(path string, splitChar string)
- func (set *HashSetAtomic) Read() HashUint32Set
- func (set *HashSetAtomic) Remove(item string)
- func (set *HashSetAtomic) Size() int
- func (set *HashSetAtomic) UnsafeAddUint32(v uint32)
- type HashSetMutex
- func (s *HashSetMutex) Add(item string)
- func (s *HashSetMutex) Clear()
- func (s *HashSetMutex) ClearFast()
- func (s HashSetMutex) Contains(item string) bool
- func (s *HashSetMutex) LoadFromArray(data []string)
- func (s *HashSetMutex) LoadFromJSONArray(path string)
- func (s *HashSetMutex) LoadFromRaw(path string, splitChar string)
- func (s HashSetMutex) MatchAny(item string) bool
- func (s *HashSetMutex) Remove(item string)
- func (s *HashSetMutex) Size() int
- type HashSetWORM
- func (s *HashSetWORM) Add(item string)
- func (s *HashSetWORM) Clear()
- func (s *HashSetWORM) ClearFast()
- func (s HashSetWORM) Contains(item string) bool
- func (s *HashSetWORM) LoadFromArray(data []string)
- func (s *HashSetWORM) LoadFromJSONArray(path string)
- func (s *HashSetWORM) LoadFromRaw(path string, splitChar string)
- func (s HashSetWORM) MatchAny(item string) bool
- func (s *HashSetWORM) Remove(item string)
- func (s *HashSetWORM) Size() int
- type HashUint32Set
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type HashSet ¶
type HashSet struct {
// contains filtered or unexported fields
}
func NewHashSet ¶
func NewHashSet() HashSet
func NewHashSetPtr ¶
func NewHashSetPtr() *HashSet
type HashSetAtomic ¶
type HashSetAtomic struct {
// contains filtered or unexported fields
}
func NewAtomicHashSet ¶
func NewAtomicHashSet() HashSetAtomic
func NewAtomicHashSetPtr ¶
func NewAtomicHashSetPtr() HashSetAtomic
func (*HashSetAtomic) Add ¶
func (set *HashSetAtomic) Add(item string)
func (*HashSetAtomic) Clear ¶
func (set *HashSetAtomic) Clear()
func (*HashSetAtomic) ClearFast ¶
func (set *HashSetAtomic) ClearFast()
func (*HashSetAtomic) Contains ¶
func (set *HashSetAtomic) Contains(item uint32) bool
func (*HashSetAtomic) ContainsString ¶
func (set *HashSetAtomic) ContainsString(item string) bool
func (*HashSetAtomic) LoadFromArray ¶
func (set *HashSetAtomic) LoadFromArray(data []string)
func (*HashSetAtomic) LoadFromJSONArray ¶
func (set *HashSetAtomic) LoadFromJSONArray(path string)
func (*HashSetAtomic) LoadFromRaw ¶
func (set *HashSetAtomic) LoadFromRaw(path string, splitChar string)
func (*HashSetAtomic) Read ¶
func (set *HashSetAtomic) Read() HashUint32Set
func (*HashSetAtomic) Remove ¶
func (set *HashSetAtomic) Remove(item string)
func (*HashSetAtomic) Size ¶
func (set *HashSetAtomic) Size() int
func (*HashSetAtomic) UnsafeAddUint32 ¶
func (set *HashSetAtomic) UnsafeAddUint32(v uint32)
this call is considered as unsafe because write locks are removed from it
type HashSetMutex ¶
type HashSetMutex struct {
// contains filtered or unexported fields
}
func NewHashSetMutex ¶
func NewHashSetMutex() HashSetMutex
func NewHashSetMutexPtr ¶
func NewHashSetMutexPtr() *HashSetMutex
func (*HashSetMutex) Add ¶
func (s *HashSetMutex) Add(item string)
func (*HashSetMutex) Clear ¶
func (s *HashSetMutex) Clear()
func (*HashSetMutex) ClearFast ¶
func (s *HashSetMutex) ClearFast()
func (HashSetMutex) Contains ¶
func (s HashSetMutex) Contains(item string) bool
func (*HashSetMutex) LoadFromArray ¶
func (s *HashSetMutex) LoadFromArray(data []string)
content loaded via this method will make to allocate data on the heap
func (*HashSetMutex) LoadFromJSONArray ¶
func (s *HashSetMutex) LoadFromJSONArray(path string)
func (*HashSetMutex) LoadFromRaw ¶
func (s *HashSetMutex) LoadFromRaw(path string, splitChar string)
func (HashSetMutex) MatchAny ¶
func (s HashSetMutex) MatchAny(item string) bool
func (*HashSetMutex) Remove ¶
func (s *HashSetMutex) Remove(item string)
func (*HashSetMutex) Size ¶
func (s *HashSetMutex) Size() int
type HashSetWORM ¶
type HashSetWORM struct {
// contains filtered or unexported fields
}
HashSet WORM (Write Once Read Many) is an unsafe data structure in where data is loaded once for example, at init() functions an it is readed, after loading many times avoiding further modifications after being loaded.
func NewHashSetWORM ¶
func NewHashSetWORM() HashSetWORM
func NewHashSetWORMPtr ¶
func NewHashSetWORMPtr() *HashSetWORM
func (*HashSetWORM) Add ¶
func (s *HashSetWORM) Add(item string)
func (*HashSetWORM) Clear ¶
func (s *HashSetWORM) Clear()
func (*HashSetWORM) ClearFast ¶
func (s *HashSetWORM) ClearFast()
func (HashSetWORM) Contains ¶
func (s HashSetWORM) Contains(item string) bool
func (*HashSetWORM) LoadFromArray ¶
func (s *HashSetWORM) LoadFromArray(data []string)
content loaded via this method will make to allocate data on the heap
func (*HashSetWORM) LoadFromJSONArray ¶
func (s *HashSetWORM) LoadFromJSONArray(path string)
func (*HashSetWORM) LoadFromRaw ¶
func (s *HashSetWORM) LoadFromRaw(path string, splitChar string)
func (HashSetWORM) MatchAny ¶
func (s HashSetWORM) MatchAny(item string) bool
func (*HashSetWORM) Remove ¶
func (s *HashSetWORM) Remove(item string)
func (*HashSetWORM) Size ¶
func (s *HashSetWORM) Size() int
type HashUint32Set ¶
type HashUint32Set struct {
// contains filtered or unexported fields
}
func NewHashUint32Set ¶
func NewHashUint32Set() HashUint32Set
func NewHashUint32SetPtr ¶
func NewHashUint32SetPtr() *HashUint32Set
func (*HashUint32Set) ClearFast ¶
func (hs *HashUint32Set) ClearFast()
clears the map without extra allocations faster since go 1.11
Click to show internal directories.
Click to hide internal directories.