storage

package
v1.0.8 Latest Latest
Warning

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

Go to latest
Published: Nov 4, 2023 License: GPL-3.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ArrHeap

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

func NewArrHeap

func NewArrHeap[T any]() (heap *ArrHeap[T])

Creates a new heap for allocation of array cells, whose sizes are multiple of the same element size elemSize

func (*ArrHeap[T]) DisposeArr

func (heap *ArrHeap[T]) DisposeArr(a **[]T)

Deallocates the cell at Address a and containing an array cell of elemNb elements by putting it in the link chained

func (*ArrHeap[T]) NewArr

func (heap *ArrHeap[T]) NewArr(cellNb int) (a *[]T)

Allocates into a a new cell for an array of elemNb elements of fixed size

func (*ArrHeap[T]) Stats

func (heap *ArrHeap[T]) Stats() (nb, nbElems, size int)

type ObjectElem

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

type Objects

type Objects[T any] []ObjectElem[T]

type RecHeap

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

Heap for cells of the same size

func NewRecHeap

func NewRecHeap[T any]() (heap *RecHeap[T])

Creates a new heap for allocation of cells with the unique size recSize

func (*RecHeap[T]) DisposeRec

func (heap *RecHeap[T]) DisposeRec(a **T)

Deallocates the cell at Address a by putting it into the link chained

func (*RecHeap[T]) NewRec

func (heap *RecHeap[T]) NewRec() *T

Allocates into a a new cell of fixed size

func (*RecHeap[T]) Stats

func (heap *RecHeap[T]) Stats() (nb, size int)

Jump to

Keyboard shortcuts

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