RedBlack::Tree(V)
Inherits Enumerable < Reference < Object
Constructors
new
Sourcenew
SourceInstance methods
<<(v : V)
Sourcecollect
Sourcedepth(x : Node(V) | Leaf)
Sourcedisplay(io : IO, h)
Sourcedisplay
Sourceeach_node
Sourceeach_node_with_index
Sourceempty!
Sourceempty?
Returns true if self does not contain any element.
([] of Int32).empty? # => true
([1]).empty? # => false
[nil, false].empty? # => false
#present?returns the inverse.
enum
Sourcefind(key : V)
Sourcefind!(key : V)
Sourcefind?(key : V)
Sourceheight(x : Node(V) | Leaf)
Sourceinsert(v : V)
Sourcemax_node
Sourcemax_node!
Sourcemax_node?
Sourcemin_node
Sourcemin_node!
Sourcemin_node?
Sourcepred(x : Node(V))
Sourcepred!(x : Node(V))
Sourcepred?(x : Node(V))
Sourcesucc(x : Node(V))
Sourcesucc!(x : Node(V))
Sourcesucc?(x : Node(V))
Sourceto_s(io)
Source