casacore
Loading...
Searching...
No Matches
casa
Exceptions.h
Go to the documentation of this file.
1
//# Exceptions.h: a module for exception handling
2
//# Copyright (C) 1995,1999,2000,2001
3
//# Associated Universities, Inc. Washington DC, USA.
4
//#
5
//# This library is free software; you can redistribute it and/or modify it
6
//# under the terms of the GNU Library General Public License as published by
7
//# the Free Software Foundation; either version 2 of the License, or (at your
8
//# option) any later version.
9
//#
10
//# This library is distributed in the hope that it will be useful, but WITHOUT
11
//# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
12
//# FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public
13
//# License for more details.
14
//#
15
//# You should have received a copy of the GNU Library General Public License
16
//# along with this library; if not, write to the Free Software Foundation,
17
//# Inc., 675 Massachusetts Ave, Cambridge, MA 02139, USA.
18
//#
19
//# Correspondence concerning AIPS++ should be addressed as follows:
20
//# Internet email: casa-feedback@nrao.edu.
21
//# Postal address: AIPS++ Project Office
22
//# National Radio Astronomy Observatory
23
//# 520 Edgemont Road
24
//# Charlottesville, VA 22903-2475 USA
25
26
#ifndef CASA_EXCEPTIONS_H
27
#define CASA_EXCEPTIONS_H
28
29
30
#include <casacore/casa/aips.h>
31
32
#include <casacore/casa/Exceptions/Error.h>
33
34
namespace
casacore
{
//# NAMESPACE CASACORE - BEGIN
35
36
// <module>
37
//
38
// <summary>
39
// Exception handling
40
// </summary>
41
//
42
// <reviewed reviewer="UNKNOWN" date="before2004/08/25" demos="">
43
// </reviewed>
44
//
45
// <synopsis>
46
// This module provides the exception handling mechanism used in Casacore.
47
// It allows the user to define new exception types and to <src>throw</src>,
48
// <src>catch</src>, and <src>rethrow</src> these exceptions. The interface
49
// to this exception handling mechanism is very similary to the ANSI standard
50
// exceptions. This will make it easy to switch when the time comes.
51
//
52
// This module supplies several <linkto file="Error.h">common exception types </linkto>.
53
// These provide examples for creating new errors.
54
//
55
// At some point, this exception mechanism will probably be replaced with
56
// compiler supported exceptions.
57
// </synopsis>
58
//
59
// <example>
60
// <em>This example shows how a more specific exception can be caught as
61
// a more general exception:</em>
62
// <srcblock>
63
// #include <casacore/casa/Exceptions.h>
64
// #include <iostream>
65
// main() {
66
// try {
67
// throw(indexError<int>(5,"Dummy error"));
68
// } catch (IndexError xx) {
69
// cout << "caught IndexError" << endl;
70
// }
71
// }
72
// </srcblock>
73
// </example>
74
// </module>
75
76
77
}
//# NAMESPACE CASACORE - END
78
79
#endif
casacore
this file contains all the compiler specific defines
Definition
mainpage.dox:28
Generated by
1.9.8