]> cygwin.com Git - cygwin-apps/setup.git/blame - Exception.h
copyright
[cygwin-apps/setup.git] / Exception.h
CommitLineData
58ee6135
RC
1/*
2 * Copyright (c) 2001, Robert Collins.
3 *
4 * This program is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License as published by
6 * the Free Software Foundation; either version 2 of the License, or
7 * (at your option) any later version.
8 *
9 * A copy of the GNU General Public License can be found at
10 * http://www.gnu.org/
11 *
12 * Written by Robert Collins <rbtcollins@hotmail.com>
13 *
14 */
15
16/* this is the parent class for all package source (not source code - installation
17 * source as in http/ftp/disk file) operations.
18 */
19
20#ifndef _EXCEPTION_H_
21#define _EXCEPTION_H_
22
23#include <exception>
24
25/* Generic excpetion class for throwing exceptions */
26class Exception : public exception {
27public:
28 Exception (char const *where, char const *message, int appErrNo = 0);
29 char const *what() const;
30 int errNo() const;
31private:
32 char const *_message;
33 int appErrNo;
34};
35
36// Where should these live?
37#define APPERR_CORRUPT_PACKAGE 1
38#define APPERR_IO_ERROR 2
39
40#endif /* _EXCEPTION_H_ */
This page took 0.025037 seconds and 5 git commands to generate.