redblack

package
v7.6.2 Latest Latest
Warning

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

Go to latest
Published: Feb 5, 2024 License: Apache-2.0 Imports: 0 Imported by: 0

Documentation

Overview

Simple, incomplete red-black tree implementation meant only to rebuild the directory tree of a CDF file.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type LessFunc

type LessFunc func(i, j interface{}) bool

type Node

type Node struct {
	Item     interface{}
	Less     LessFunc
	Red      bool
	Children [2]*Node
}

type Tree

type Tree struct {
	Root  *Node
	Less  LessFunc
	Count uint
}

func New

func New(less LessFunc) *Tree

func (*Tree) Insert

func (t *Tree) Insert(item interface{})

func (*Tree) Nodes

func (t *Tree) Nodes() []*Node

Jump to

Keyboard shortcuts

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