Help us shape the future of Go! Take the 2026 Go Developer Survey

list

package
v1.53.0 Latest Latest
Warning

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

Go to latest
Published: Oct 19, 2026 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 Hook

type Hook[T any] struct {
	// contains filtered or unexported fields
}

func (*Hook[T]) Next

func (h *Hook[T]) Next() *T

func (*Hook[T]) Prev

func (h *Hook[T]) Prev() *T

type Hooked

type Hooked[T any] interface {
	*T
	// contains filtered or unexported methods
}

type List

type List[T any, P Hooked[T]] struct {
	// contains filtered or unexported fields
}

List is an intrusive doubly-linked list. Mutations involving a node the list does not own are no-ops, as in container/list. A node linked into a DIFFERENT list is indistinguishable from a member without a per-node list pointer and remains the caller's contract.

func (*List[T, P]) Back

func (l *List[T, P]) Back() P

func (*List[T, P]) Empty

func (l *List[T, P]) Empty() bool

func (*List[T, P]) Front

func (l *List[T, P]) Front() P

func (*List[T, P]) InsertAfter

func (l *List[T, P]) InsertAfter(it, mark P)

func (*List[T, P]) InsertBefore

func (l *List[T, P]) InsertBefore(it, mark P)

func (*List[T, P]) MoveToBack

func (l *List[T, P]) MoveToBack(it P)

func (*List[T, P]) MoveToFront

func (l *List[T, P]) MoveToFront(it P)

func (*List[T, P]) PushBack

func (l *List[T, P]) PushBack(it P)

func (*List[T, P]) PushFront

func (l *List[T, P]) PushFront(it P)

func (*List[T, P]) Remove

func (l *List[T, P]) Remove(it P)

Jump to

Keyboard shortcuts

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