Units Class Hierarchy Classes, Interfaces, Objects and Records Types Variables Constants Functions and Procedures Identifiers |
Class TGenTreeSet
Unit
GContnrs
Declaration
type generic TGenTreeSet<_TItem_> = class(TAbstractTreeSet)
Description
no description available, TAbstractTreeSet description follows no description available, TContainer description follows Hierarchy
Overview
Internal Types
Methods
Properties
Description
Internal Types
|
TCompareItems = function (const A, B: _TItem_) : Integer of object; |
|
|
TItemToString = function (const Item: _TItem_) : String of object; |
|
Methods
|
function Ceiling(const Item: _TItem_) : TTreeSetCursor; |
Searches for the first item which is not less than Item. If such an item is found, a cursor that designates it is returned. Otherwise NilCursor is returned.
|
|
procedure Clear; |
Removes all the items from the container.
|
|
function Contains(const Item: _TItem_) : Boolean; |
Returns true if the container contains Item.
|
|
constructor Create; |
Creates an empty tree set.
|
|
function DefaultCompareItems(const A, B: _TItem_) : Integer; virtual; |
|
|
function DefaultItemToString(const Item: _TItem_) : String; virtual; |
|
|
procedure Delete(const Item: _TItem_); |
Checks if Item is present in the container. If a match is found, removes the element from the set. Otherwise, raises an exception.
|
|
procedure DeleteAt(const Position: TTreeSetCursor); |
Deletes the item designated by Position.
|
|
procedure DeleteFirst; |
Deletes the first item.
|
|
procedure DeleteLast; |
Deletes the last item.
|
|
destructor Destroy; override; |
|
|
procedure Difference(Left, Right: TGenTreeSet); |
Clears Self and then adds to Self all the items of Left that are not present in Right.
|
|
procedure Exclude(const Item: _TItem_); |
Checks if Item is present in the container. If a match is found, removes the item from the set.
|
|
procedure ExcludeAll(ASet: TGenTreeSet); |
Excludes all the items of ASet.
|
|
function First: TTreeSetCursor; |
Returns a cursor that designates the first element of the container or NilCursor if the container is empty.
|
|
function FirstItem: _TItem_; |
Returns the first Item.
|
|
function Floor(const Item: _TItem_) : TTreeSetCursor; |
Searches for the last item which is not greater than Item. If such an item is found, a cursor that designates it is returned. Otherwise NilCursor is returned.
|
|
procedure Include(const Item: _TItem_); |
Checks if Item is present in the container. If no match is found, inserts the item into the set.
|
|
procedure IncludeAll(ASet: TGenTreeSet); |
Includes all the items of ASet.
|
|
procedure Insert(const Item: _TItem_); |
Checks if Item is present in the container. If no match is found, inserts the item into the set. Otherwise, raises an exception.
|
|
procedure Insert(const Item: _TItem_; out Inserted: Boolean); |
Checks if Item is present in the container. If no match is found, inserts the item into the set and sets Inserted to true. Otherwise, sets Inserted to false.
|
|
procedure Intersection(Left, Right: TGenTreeSet); |
Clears Self and then adds to Self all the items of Left that are present in Right.
|
|
function IsEmpty: Boolean; inline; |
Returns true if the set is empty.
|
|
function IsSubset(OfSet: TGenTreeSet) : Boolean; |
Returns true if all the items in Self are present in OfSet.
|
|
function Last: TTreeSetCursor; |
Returns a cursor that designates the last element of the container or NilCursor if the container is empty.
|
|
function LastItem: _TItem_; |
Returns the last Item.
|
|
function Overlaps(ASet: TGenTreeSet) : Boolean; |
Returns true if at least one item of Self is present in ASet.
|
|
procedure ReadFirstItem(out Value : _TItem_); inline; |
|
|
procedure ReadItemAt(const Position: TTreeSetCursor; out Value: _TItem_); |
|
|
procedure ReadLastItem(out Value : _TItem_); inline; |
|
|
procedure SymmetricDifference(Left, Right: TGenTreeSet); |
Clears Self and then adds to Self all the items of Left that are not present in Right all the items of Right that are not present in Left.
|
|
function ToString : String; override; |
Return a string representation for the container.
|
|
procedure Union(Left, Right: TGenTreeSet); |
Clears Self and then adds to Self all the items of Left and all the items of Right.
|
Properties
|
property Items[constPosition:TTreeSetCursor]: _TItem_ read GetItemAt; |
Provides access to the items in the container.
|
|
property OnCompareItems : TCompareItems read GetOnCompareItems write SetOnCompareItems; |
|
|
property OnItemToString : TItemToString read GetOnItemToString write SetOnItemToString; |
|
|
property Size : Integer read GetSize; |
Number of items.
|
Generated by PasDoc 0.13.0 on 2014-07-29 16:12:40
|