TreeSet
Object Hierarchy:
Gee.TreeSet
Gee.TreeSet
Gee.TreeSet
Gee.AbstractBidirSortedSet
Gee.AbstractBidirSortedSet
Gee.AbstractBidirSortedSet->Gee.TreeSet
Gee.AbstractSortedSet
Gee.AbstractSortedSet
Gee.AbstractSortedSet->Gee.AbstractBidirSortedSet
Gee.AbstractSet
Gee.AbstractSet
Gee.AbstractSet->Gee.AbstractSortedSet
Gee.AbstractCollection
Gee.AbstractCollection
Gee.AbstractCollection->Gee.AbstractSet
GLib.Object
GLib.Object
GLib.Object->Gee.AbstractCollection
Gee.Traversable
Gee.Traversable
Gee.Traversable->Gee.AbstractCollection
Gee.Iterable
Gee.Iterable
Gee.Iterable->Gee.AbstractCollection
Gee.Collection
Gee.Collection
Gee.Collection->Gee.AbstractCollection
Gee.Set
Gee.Set
Gee.Set->Gee.AbstractSet
Gee.SortedSet
Gee.SortedSet
Gee.SortedSet->Gee.AbstractSortedSet
Gee.BidirSortedSet
Gee.BidirSortedSet
Gee.BidirSortedSet->Gee.AbstractBidirSortedSet
Description:
public class TreeSet <
G > :
AbstractBidirSortedSet <
G >
Left-leaning red-black tree implementation of the Set interface.
This implementation is especially well designed for large quantity of data. The (balanced) tree implementation insure that the set and
get methods are in logarithmic complexity. For a linear implementation see HashSet .
See also:
HashSet
Content:
Properties:
Creation methods:
Methods:
public override bool @foreach (ForallFunc <G > f)
public override bool add (G item)
Adds an item to this collection. Must not be called on read-only
collections.
public override BidirIterator <G > bidir_iterator ()
Returns a
BidirIterator that can be used for bi-directional iteration over this sorted set.
public override G ceil (G item)
Returns the element which is higher or equal then the specified
element.
public override void clear ()
Removes all items from this collection. Must not be called on read-
only collections.
public override bool contains (G item)
Determines whether this collection contains the specified item.
public override G first ()
Returns the first element of the sorted set. Set must not be empty.
public override G floor (G item)
Returns the element which is lower or equal then the specified
element.
public override SortedSet <G > head_set (G before)
Returns the sub-set of this sorted set containing elements strictly
lower than the specified element.
public override G higher (G item)
Returns the element which is strictly higher than the specified
element.
public override Iterator <G > iterator ()
Returns a Iterator
that can be used for simple iteration over a collection.
public override Iterator <G >? iterator_at (G item)
Returns a
BidirIterator initially pointed at the specified element.
public override G last ()
Returns the last element of the sorted set. Set must not be empty.
public override G lower (G item)
Returns the element which is strictly lower than the specified
element.
public override bool remove (G item)
Removes the first occurrence of an item from this collection. Must not
be called on read-only collections.
public override SortedSet <G > sub_set (G after, G before)
Returns the right-open sub-set of this sorted set, thus containing
elements equal or higher than the specified from
element, and stricly lower than the specified to
element.
public override SortedSet <G > tail_set (G after)
Returns the sub-set of this sorted set containing elements equal or
higher than the specified element.
Inherited Members:
All known members inherited from class Gee.AbstractBidirSortedSet
All known members inherited from class Gee.AbstractSortedSet
All known members inherited from class Gee.AbstractSet
All known members inherited from class Gee.AbstractCollection
All known members inherited from class GLib.Object
@get
@new
@ref
@set
add_toggle_ref
add_weak_pointer
bind_property
connect
constructed
disconnect
dispose
dup_data
dup_qdata
force_floating
freeze_notify
get_class
get_data
get_property
get_qdata
get_type
getv
interface_find_property
interface_install_property
interface_list_properties
is_floating
new_valist
new_with_properties
newv
notify
notify_property
ref_count
ref_sink
remove_toggle_ref
remove_weak_pointer
replace_data
replace_qdata
set_data
set_data_full
set_property
set_qdata
set_qdata_full
set_valist
setv
steal_data
steal_qdata
thaw_notify
unref
watch_closure
weak_ref
weak_unref
All known members inherited from interface Gee.BidirSortedSet
All known members inherited from interface Gee.SortedSet
All known members inherited from interface Gee.Set
All known members inherited from interface Gee.Traversable
All known members inherited from interface Gee.Iterable
All known members inherited from interface Gee.Collection