Documentation ¶
Index ¶
- type LinkedList
- func (list *LinkedList[E]) Chunk(size int) *LinkedList[*LinkedList[any]]
- func (list *LinkedList[E]) Clear()
- func (list *LinkedList[E]) Clone() *LinkedList[E]
- func (list *LinkedList[E]) Compact(callback func(a, b E) bool)
- func (list *LinkedList[E]) Contains(value E) bool
- func (list *LinkedList[E]) ContainsWhere(callback func(value E) bool) bool
- func (list *LinkedList[E]) Count() int64
- func (list *LinkedList[E]) Each(callback func(index int, value E) bool)
- func (list *LinkedList[E]) First() (E, bool)
- func (list *LinkedList[E]) FirstOr(value E) E
- func (list *LinkedList[E]) FirstWhere(callback func(item E) bool) (E, bool)
- func (list *LinkedList[E]) FirstWhereOr(callback func(item E) bool, value E) E
- func (list *LinkedList[E]) Get(index int) E
- func (list *LinkedList[E]) IndexOf(value E) int
- func (list *LinkedList[E]) IndexOfWhere(callback func(item E) bool) int
- func (list *LinkedList[E]) IsEmpty() bool
- func (list *LinkedList[E]) IsNotEmpty() bool
- func (list *LinkedList[E]) Last() (E, bool)
- func (list *LinkedList[E]) LastOr(value E) E
- func (list *LinkedList[E]) LastWhere(callback func(item E) bool) (E, bool)
- func (list *LinkedList[E]) LastWhereOr(callback func(item E) bool, value E) E
- func (list *LinkedList[E]) MarshalJSON() ([]byte, error)
- func (list *LinkedList[E]) Max(callback func(a, b E) int) E
- func (list *LinkedList[E]) Min(callback func(a, b E) int) E
- func (list *LinkedList[E]) Pop() (E, bool)
- func (list *LinkedList[E]) Push(values ...E)
- func (list *LinkedList[E]) Remove(value E)
- func (list *LinkedList[E]) RemoveAt(index int)
- func (list *LinkedList[E]) RemoveWhere(callback func(item E) bool)
- func (list *LinkedList[E]) Reverse()
- func (list *LinkedList[E]) Set(index int, value E)
- func (list *LinkedList[E]) Shift() (E, bool)
- func (list *LinkedList[E]) Sort(callback func(a, b E) int)
- func (list *LinkedList[E]) String() string
- func (list *LinkedList[E]) Sub(from, to int) *LinkedList[E]
- func (list *LinkedList[E]) ToArray() []E
- func (list *LinkedList[E]) ToJSON() ([]byte, error)
- func (list *LinkedList[E]) UnmarshalJSON(data []byte) error
- func (list *LinkedList[E]) Unshift(values ...E)
- func (list *LinkedList[E]) Where(callback func(item E) bool) *LinkedList[E]
- type List
- func (list *List[E]) Chunk(size int) *List[*List[any]]
- func (list *List[E]) Clear()
- func (list *List[E]) Clone() *List[E]
- func (list *List[E]) Compact(callback func(a, b E) bool)
- func (list *List[E]) Contains(value E) bool
- func (list *List[E]) ContainsWhere(callback func(value E) bool) bool
- func (list *List[E]) Count() int64
- func (list *List[E]) Each(callback func(index int, value E) bool)
- func (list *List[E]) First() (E, bool)
- func (list *List[E]) FirstOr(value E) E
- func (list *List[E]) FirstWhere(callback func(item E) bool) (E, bool)
- func (list *List[E]) FirstWhereOr(callback func(item E) bool, value E) E
- func (list *List[E]) Get(index int) E
- func (list *List[E]) IndexOf(value E) int
- func (list *List[E]) IndexOfWhere(callback func(item E) bool) int
- func (list *List[E]) IsEmpty() bool
- func (list *List[E]) IsNotEmpty() bool
- func (list *List[E]) Last() (E, bool)
- func (list *List[E]) LastOr(value E) E
- func (list *List[E]) LastWhere(callback func(item E) bool) (E, bool)
- func (list *List[E]) LastWhereOr(callback func(item E) bool, value E) E
- func (list *List[E]) MarshalJSON() ([]byte, error)
- func (list *List[E]) Max(callback func(a, b E) int) E
- func (list *List[E]) Min(callback func(a, b E) int) E
- func (list *List[E]) Pop() (E, bool)
- func (list *List[E]) Push(values ...E)
- func (list *List[E]) Remove(value E)
- func (list *List[E]) RemoveAt(index int)
- func (list *List[E]) RemoveWhere(callback func(item E) bool)
- func (list *List[E]) Reverse()
- func (list *List[E]) Set(index int, value E)
- func (list *List[E]) Shift() (E, bool)
- func (list *List[E]) Sort(callback func(a, b E) int)
- func (list *List[E]) String() string
- func (list *List[E]) Sub(from, to int) *List[E]
- func (list *List[E]) ToArray() []E
- func (list *List[E]) ToJSON() ([]byte, error)
- func (list *List[E]) UnmarshalJSON(data []byte) error
- func (list *List[E]) Unshift(values ...E)
- func (list *List[E]) Where(callback func(item E) bool) *List[E]
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type LinkedList ¶
LinkedList linked list
func NewLinkedList ¶
func NewLinkedList[E any](values ...E) *LinkedList[E]
NewLinkedList new linked list
func (*LinkedList[E]) Chunk ¶
func (list *LinkedList[E]) Chunk(size int) *LinkedList[*LinkedList[any]]
func (*LinkedList[E]) Clear ¶
func (list *LinkedList[E]) Clear()
func (*LinkedList[E]) Clone ¶
func (list *LinkedList[E]) Clone() *LinkedList[E]
func (*LinkedList[E]) Compact ¶
func (list *LinkedList[E]) Compact(callback func(a, b E) bool)
func (*LinkedList[E]) Contains ¶
func (list *LinkedList[E]) Contains(value E) bool
func (*LinkedList[E]) ContainsWhere ¶
func (list *LinkedList[E]) ContainsWhere(callback func(value E) bool) bool
func (*LinkedList[E]) Count ¶
func (list *LinkedList[E]) Count() int64
func (*LinkedList[E]) Each ¶
func (list *LinkedList[E]) Each(callback func(index int, value E) bool)
func (*LinkedList[E]) First ¶
func (list *LinkedList[E]) First() (E, bool)
func (*LinkedList[E]) FirstOr ¶
func (list *LinkedList[E]) FirstOr(value E) E
func (*LinkedList[E]) FirstWhere ¶
func (list *LinkedList[E]) FirstWhere(callback func(item E) bool) (E, bool)
func (*LinkedList[E]) FirstWhereOr ¶
func (list *LinkedList[E]) FirstWhereOr(callback func(item E) bool, value E) E
func (*LinkedList[E]) Get ¶
func (list *LinkedList[E]) Get(index int) E
func (*LinkedList[E]) IndexOf ¶
func (list *LinkedList[E]) IndexOf(value E) int
func (*LinkedList[E]) IndexOfWhere ¶
func (list *LinkedList[E]) IndexOfWhere(callback func(item E) bool) int
func (*LinkedList[E]) IsEmpty ¶
func (list *LinkedList[E]) IsEmpty() bool
func (*LinkedList[E]) IsNotEmpty ¶
func (list *LinkedList[E]) IsNotEmpty() bool
func (*LinkedList[E]) Last ¶
func (list *LinkedList[E]) Last() (E, bool)
func (*LinkedList[E]) LastOr ¶
func (list *LinkedList[E]) LastOr(value E) E
func (*LinkedList[E]) LastWhere ¶
func (list *LinkedList[E]) LastWhere(callback func(item E) bool) (E, bool)
func (*LinkedList[E]) LastWhereOr ¶
func (list *LinkedList[E]) LastWhereOr(callback func(item E) bool, value E) E
func (*LinkedList[E]) MarshalJSON ¶
func (list *LinkedList[E]) MarshalJSON() ([]byte, error)
func (*LinkedList[E]) Max ¶
func (list *LinkedList[E]) Max(callback func(a, b E) int) E
func (*LinkedList[E]) Min ¶
func (list *LinkedList[E]) Min(callback func(a, b E) int) E
func (*LinkedList[E]) Pop ¶
func (list *LinkedList[E]) Pop() (E, bool)
func (*LinkedList[E]) Push ¶
func (list *LinkedList[E]) Push(values ...E)
func (*LinkedList[E]) Remove ¶
func (list *LinkedList[E]) Remove(value E)
func (*LinkedList[E]) RemoveAt ¶
func (list *LinkedList[E]) RemoveAt(index int)
func (*LinkedList[E]) RemoveWhere ¶
func (list *LinkedList[E]) RemoveWhere(callback func(item E) bool)
func (*LinkedList[E]) Reverse ¶
func (list *LinkedList[E]) Reverse()
func (*LinkedList[E]) Set ¶
func (list *LinkedList[E]) Set(index int, value E)
func (*LinkedList[E]) Shift ¶
func (list *LinkedList[E]) Shift() (E, bool)
func (*LinkedList[E]) Sort ¶
func (list *LinkedList[E]) Sort(callback func(a, b E) int)
func (*LinkedList[E]) String ¶
func (list *LinkedList[E]) String() string
func (*LinkedList[E]) Sub ¶
func (list *LinkedList[E]) Sub(from, to int) *LinkedList[E]
func (*LinkedList[E]) ToArray ¶
func (list *LinkedList[E]) ToArray() []E
func (*LinkedList[E]) ToJSON ¶
func (list *LinkedList[E]) ToJSON() ([]byte, error)
func (*LinkedList[E]) UnmarshalJSON ¶
func (list *LinkedList[E]) UnmarshalJSON(data []byte) error
func (*LinkedList[E]) Unshift ¶
func (list *LinkedList[E]) Unshift(values ...E)
func (*LinkedList[E]) Where ¶
func (list *LinkedList[E]) Where(callback func(item E) bool) *LinkedList[E]
type List ¶
List list
func (*List[E]) ContainsWhere ¶
func (*List[E]) FirstWhere ¶
func (*List[E]) FirstWhereOr ¶
func (*List[E]) IndexOfWhere ¶
func (*List[E]) IsNotEmpty ¶
func (*List[E]) LastWhereOr ¶
func (*List[E]) MarshalJSON ¶
func (*List[E]) RemoveWhere ¶
func (*List[E]) UnmarshalJSON ¶
Click to show internal directories.
Click to hide internal directories.