1
-------------------------------------------------------------------------------
3
-- <STRONG>Copyright (c) 2001, 2002 by Thomas Wolf.</STRONG>
5
-- This piece of software is free software; you can redistribute it and/or
6
-- modify it under the terms of the GNU General Public License as published
7
-- by the Free Software Foundation; either version 2, or (at your option)
8
-- any later version. This unit is distributed in the hope that it will be
9
-- useful, but <EM>without any warranty</EM>; without even the implied
10
-- warranty of <EM>merchantability or fitness for a particular purpose.</EM>
11
-- See the GNU General Public License for more details. You should have
12
-- received a copy of the GNU General Public License with this distribution,
13
-- see file "<A HREF="GPL.txt">GPL.txt</A>". If not, write to the Free
14
-- Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307,
18
-- As a special exception from the GPL, if other files instantiate generics
19
-- from this unit, or you link this unit with other files to produce an
20
-- executable, this unit does not by itself cause the resulting executable
21
-- to be covered by the GPL. This exception does not however invalidate any
22
-- other reasons why the executable file might be covered by the GPL.
26
-- Author:</STRONG><DD>
28
-- <ADDRESS><A HREF="mailto:twolf@acm.org">twolf@acm.org</A></ADDRESS></DL>
31
-- Purpose:</STRONG><DD>
32
-- Root package for GAL's "raw ADT" subsystem. The "raw ADTs" are used in the
33
-- <CODE><A HREF="gal-containers.html">Containers</A></CODE> subsystem to
34
-- implement containers.</DL>
39
-- 27-OCT-2001 TW Initial version.
40
-- 16-NOV-2001 TW Added boiler-plate comments.
41
-- 20-NOV-2001 TW Added Unordered_Error.
43
-------------------------------------------------------------------------------
45
pragma License (Modified_GPL);
51
Container_Empty : exception;
52
-- May be raised by some ADTs when an illegal operation is attempted on
53
-- an empty ADT object, e.g. trying to delete an item from an empty tree
56
Container_Full : exception;
57
-- May be raised by bounded ADTs when an item should be added to an ADT
58
-- that is already full.
60
Range_Error : exception;
61
-- Raised by operations that support ranges of some kind if the range is
62
-- invalid, e.g. there are some list operations where ranges can be
63
-- specified using two positions -- these operations raise Range_Error
64
-- if the two positions are not on the same list, or one of them is null.
66
Not_Found : exception;
67
-- Raised if an item we looked for in an ADT was not found, and the ADT
68
-- object is not empty. (If it is empty, Container_Empty should be raised
71
Duplicate_Key : exception;
72
-- Raised by asome ADTs that don't allow duplicates when a second item
73
-- that is considered equal to an item already in the ADT is about to be
76
Container_Error : exception;
77
-- General consistency error. Raised e.g. when an iterator is used that
78
-- has becomes invalid because the item it was referencing has vanished.
80
Navigation_Error : exception;
81
-- Raised when a semantically illegal operation through a position is
82
-- attempted, such as inserting an element after a position that already
83
-- is beyond the end of a list.
85
Unordered_Error : exception;
86
-- Raised by relational operators (<,>,<=,>=) if the two objects to be
87
-- compared are unordered. This can e.g. happen for list positions, if
88
-- the two positions are on different lists, or if one of them is null.
90
-- In addition to these exceptions, any ADT may potentially raise
92
-- Constraint_Error if an operation through a null-iterator is attempted.
93
-- Storage_Error if a dynamic storage allocation has failed.