1 ------------------------------------------------------------------------------
3 -- GNAT LIBRARY COMPONENTS --
5 -- ADA.CONTAINERS.RED_BLACK_TREES.GENERIC_KEYS --
9 -- This specification is adapted from the Ada Reference Manual for use with --
10 -- GNAT. In accordance with the copyright of that document, you can freely --
11 -- copy and modify this specification, provided that if you redistribute a --
12 -- modified version, any changes that you have made are clearly indicated. --
14 ------------------------------------------------------------------------------
16 with Ada.Containers.Red_Black_Trees.Generic_Operations;
19 with package Tree_Operations is new Generic_Operations (<>);
21 use Tree_Operations.Tree_Types;
23 type Key_Type (<>) is limited private;
25 with function Is_Less_Key_Node
27 R : Node_Access) return Boolean;
29 with function Is_Greater_Key_Node
31 R : Node_Access) return Boolean;
33 package Ada.Containers.Red_Black_Trees.Generic_Keys is
34 pragma Pure (Generic_Keys);
37 with function New_Node return Node_Access;
38 procedure Generic_Insert_Post
39 (Tree : in out Tree_Type;
45 with procedure Insert_Post
46 (Tree : in out Tree_Type;
51 procedure Generic_Conditional_Insert
52 (Tree : in out Tree_Type;
54 Node : out Node_Access;
55 Success : out Boolean);
58 with procedure Insert_Post
59 (Tree : in out Tree_Type;
64 procedure Generic_Unconditional_Insert
65 (Tree : in out Tree_Type;
67 Node : out Node_Access);
70 with procedure Insert_Post
71 (Tree : in out Tree_Type;
76 with procedure Unconditional_Insert_Sans_Hint
77 (Tree : in out Tree_Type;
79 Node : out Node_Access);
81 procedure Generic_Unconditional_Insert_With_Hint
82 (Tree : in out Tree_Type;
85 Node : out Node_Access);
88 with procedure Insert_Post
89 (Tree : in out Tree_Type;
94 with procedure Conditional_Insert_Sans_Hint
95 (Tree : in out Tree_Type;
97 Node : out Node_Access;
98 Success : out Boolean);
100 procedure Generic_Conditional_Insert_With_Hint
101 (Tree : in out Tree_Type;
102 Position : Node_Access;
104 Node : out Node_Access;
105 Success : out Boolean);
109 Key : Key_Type) return Node_Access;
113 Key : Key_Type) return Node_Access;
117 Key : Key_Type) return Node_Access;
121 Key : Key_Type) return Node_Access;
124 with procedure Process (Node : Node_Access);
125 procedure Generic_Iteration
130 with procedure Process (Node : Node_Access);
131 procedure Generic_Reverse_Iteration
135 end Ada.Containers.Red_Black_Trees.Generic_Keys;