alpmList

package
v0.1.4 Latest Latest
Warning

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

Go to latest
Published: Jun 27, 2026 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Iterator

type Iterator struct {
	// contains filtered or unexported fields
}

Iterator provides iteration over a list

func (*Iterator) HasNext

func (it *Iterator) HasNext() bool

HasNext returns true if there are more elements

func (*Iterator) Next

func (it *Iterator) Next() uintptr

Next advances the iterator and returns the current element's data

type List

type List struct {
	// contains filtered or unexported fields
}

List represents an ALPM list node

func Add

func Add(l *List, data uintptr) *List

Add adds data to the list and returns the new list head

func NewList

func NewList(ptr uintptr) *List

NewList creates a new List wrapper from a C pointer

func (*List) Count

func (l *List) Count() int

Count returns the number of items in the list

func (*List) Data

func (l *List) Data() uintptr

Data returns the data pointer from the list node

func (*List) Free

func (l *List) Free()

Free frees the list structure (but not the data)

func (*List) Iterator

func (l *List) Iterator() *Iterator

Iterator returns an iterator for the list

func (*List) Next

func (l *List) Next() *List

Next returns the next node in the list

func (*List) Prev

func (l *List) Prev() *List

Prev returns the previous node in the list

func (*List) Ptr

func (l *List) Ptr() uintptr

Ptr returns the underlying C pointer

func (*List) ToSlice

func (l *List) ToSlice() []uintptr

ToSlice converts the list to a Go slice of pointers

Jump to

Keyboard shortcuts

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