~charon-developers/charon-core/trunk

« back to all changes in this revision

Viewing changes to src/ExceptionHandler.h

  • Committer: jmgottfried
  • Date: 2010-03-16 15:18:38 UTC
  • Revision ID: svn-v4:7d56a235-2f8b-4627-957e-5f30cc86da59:charon-core/trunk:680
moved header files to seperate include directory

this makes e.g. Compile and Load test work even if charon-core is not yet installed
and gives a chance to get charon-meta working

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
/*  This file is part of Charon.
2
 
 
3
 
    Charon is free software: you can redistribute it and/or modify
4
 
    it under the terms of the GNU Lesser General Public License as published by
5
 
    the Free Software Foundation, either version 3 of the License, or
6
 
    (at your option) any later version.
7
 
 
8
 
    Charon is distributed in the hope that it will be useful,
9
 
    but WITHOUT ANY WARRANTY; without even the implied warranty of
10
 
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
11
 
    GNU Lesser General Public License for more details.
12
 
 
13
 
    You should have received a copy of the GNU Lesser General Public License
14
 
    along with Charon.  If not, see <http://www.gnu.org/licenses/>.
15
 
*/
16
 
/** @file ExceptionHandler.h
17
 
 *  Declaration of class WorkflowExecutor
18
 
 *  @author <a href="mailto:jmgottfried@web.de">Jens-Malte Gottfried</a>
19
 
 *  @date 2010-02-11
20
 
 */
21
 
 
22
 
#ifndef EXCEPTIONHANDLER_H
23
 
#define EXCEPTIONHANDLER_H
24
 
 
25
 
/// Routine to simplify exception handling during workflow executions.
26
 
namespace ExceptionHandler {
27
 
        /// Execute given function and catch exceptions.
28
 
        /** Exceptions are caught, error messages are printed to std::cerr.
29
 
         *  Exception type is given in error message, on gcc, typename
30
 
         *  demangling is performed.
31
 
         *  You may use this as return value of the main() routine.
32
 
         *  \returns return value of the given function
33
 
         */
34
 
        int run(int (&method)() /**[in] execution routine*/);
35
 
}
36
 
 
37
 
#endif // EXCEPTIONHANDLER_H