Documentation ¶
Index ¶
- func ArrayListExample()
- func ArrayStackExample()
- func BinaryHeapExample()
- func CustomComparatorExample()
- func DoublyLinkedListExample()
- func HashMapExample()
- func HashSetExample()
- func LinkedListStackExample()
- func RedBlackTreeExample()
- func RedBlackTreeExtendedExample()
- func SinglyLinkedListExample()
- func SortExample()
- func TreeMapExample()
- func TreeSetExample()
- type RedBlackTreeExtended
- func (tree *RedBlackTreeExtended) Ceiling(key interface{}) (ceiling *rbt.Node, found bool)
- func (tree *RedBlackTreeExtended) Floor(key interface{}) (floor *rbt.Node, found bool)
- func (tree *RedBlackTreeExtended) GetMax() (value interface{}, found bool)
- func (tree *RedBlackTreeExtended) GetMin() (value interface{}, found bool)
- func (tree *RedBlackTreeExtended) RemoveMax() (value interface{}, deleted bool)
- func (tree *RedBlackTreeExtended) RemoveMin() (value interface{}, deleted bool)
- type User
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ArrayListExample ¶
func ArrayListExample()
func ArrayStackExample ¶
func ArrayStackExample()
func BinaryHeapExample ¶
func BinaryHeapExample()
func CustomComparatorExample ¶
func CustomComparatorExample()
func DoublyLinkedListExample ¶
func DoublyLinkedListExample()
func HashMapExample ¶
func HashMapExample()
func HashSetExample ¶
func HashSetExample()
func LinkedListStackExample ¶
func LinkedListStackExample()
func RedBlackTreeExample ¶
func RedBlackTreeExample()
func RedBlackTreeExtendedExample ¶
func RedBlackTreeExtendedExample()
func SinglyLinkedListExample ¶
func SinglyLinkedListExample()
func SortExample ¶
func SortExample()
func TreeMapExample ¶
func TreeMapExample()
func TreeSetExample ¶
func TreeSetExample()
Types ¶
type RedBlackTreeExtended ¶
func (*RedBlackTreeExtended) Ceiling ¶
func (tree *RedBlackTreeExtended) Ceiling(key interface{}) (ceiling *rbt.Node, found bool)
Find ceiling node of the input key, return the ceiling node or nil if no ceiling is found. Second return parameter is true if ceiling was found, otherwise false.
Ceiling node is defined as the smallest node that is larger than or equal to the given node. A ceiling node may not be found, either because the tree is empty, or because all nodes in the tree is smaller than the given node.
Key should adhere to the comparator's type assertion, otherwise method panics.
func (*RedBlackTreeExtended) Floor ¶
func (tree *RedBlackTreeExtended) Floor(key interface{}) (floor *rbt.Node, found bool)
Find floor node of the input key, return the floor node or nil if no ceiling is found. Second return parameter is true if floor was found, otherwise false.
Floor node is defined as the largest node that is smaller than or equal to the given node. A floor node may not be found, either because the tree is empty, or because all nodes in the tree is larger than the given node.
Key should adhere to the comparator's type assertion, otherwise method panics.
func (*RedBlackTreeExtended) GetMax ¶
func (tree *RedBlackTreeExtended) GetMax() (value interface{}, found bool)
func (*RedBlackTreeExtended) GetMin ¶
func (tree *RedBlackTreeExtended) GetMin() (value interface{}, found bool)
func (*RedBlackTreeExtended) RemoveMax ¶
func (tree *RedBlackTreeExtended) RemoveMax() (value interface{}, deleted bool)
func (*RedBlackTreeExtended) RemoveMin ¶
func (tree *RedBlackTreeExtended) RemoveMin() (value interface{}, deleted bool)