RBTree

package
v0.0.0-...-adc727d Latest Latest
Warning

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

Go to latest
Published: Oct 28, 2020 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const BLACK = false
View Source
const RED = true

Variables

This section is empty.

Functions

This section is empty.

Types

type Node

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

type RBTree

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

func Constructor

func Constructor() *RBTree

func (*RBTree) Add

func (this *RBTree) Add(key interface{}, val interface{})

向红黑树中添加新的元素(key, value)

func (*RBTree) Contains

func (this *RBTree) Contains(key interface{}) bool

func (*RBTree) Get

func (this *RBTree) Get(key interface{}) interface{}

func (*RBTree) GetSize

func (this *RBTree) GetSize() int

func (*RBTree) IsEmpty

func (this *RBTree) IsEmpty() bool

func (*RBTree) Remove

func (this *RBTree) Remove(key interface{}) interface{}

从二分搜索树中删除键为key的节点

func (*RBTree) Set

func (this *RBTree) Set(key interface{}, val interface{})

func (*RBTree) String

func (this *RBTree) String() string

Jump to

Keyboard shortcuts

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