//  stdexcept : headerfile for the free standard C++ library
//  
//  Copyright (C) 1999 by the free standard C++ Library Team
//                        see AUTHORS for more details
//
//  Homepage : http://www.inf.fu-berlin.de/~mkrueger/fscl/
//
//  This library is free software; you can redistribute it and/or
//  modify it under the terms of the GNU Library General Public
//  License as published by the Free Software Foundation; either	
//  version 2 of the License, or (at your option) any later version.
//
//  This library is distributed in the hope that it will be useful,
//  but WITHOUT ANY WARRANTY; without even the implied warranty of
//  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
//  Library General Public License for more details.
//  You should have received a copy of the GNU Library General Public
//  License along with this library; if not, write to the Free
//  Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
//
//  version : 0.1 last modified : 17.09.99

#ifndef __CPP_STDEXCEPT
#define __CPP_STDEXCEPT

#include<exception>

namespace std {
	
	class logic_error : public exception
	{
		public:
			logic_error(const char *what_arg) : what_str(what_arg)
			{
			}
			virtual const char *what() const
			{
				return what_str;
			}
		private:
			const char * what_str;
	};
	
	class domain_error : public logic_error
	{
		public:
			domain_error(const char *what_arg) : logic_error(what_arg)
			{
			}
	};
			
	class invalid_argument : public logic_error
	{
		public:
			invalid_argument(const char *what_arg) : logic_error(what_arg)
			{
			}
	};
	
	class length_error : public logic_error
	{
		public:
			length_error(const char *what_arg) : logic_error(what_arg)
			{
			}
	};
		
	class out_of_range : public logic_error
	{
		public:
			out_of_range(const char *what_arg) : logic_error(what_arg)
			{
			}
	};
	
	class runtime_error : public exception
	{
		public:
			runtime_error(const char *what_arg) : what_str(what_arg)
			{
			}
			virtual const char *what() const
			{
				return what_str;
			}
		private:
			const char *what_str;

	};

	class range_error : public runtime_error
	{
		public:
			range_error(const char *what_arg) : runtime_error(what_arg)
			{
			}			
	};

	class overflow_error : public runtime_error
	{
		public:
			overflow_error(const char *what_arg) : runtime_error(what_arg)
			{
			}
	};
	
	class underflow_error : public runtime_error
	{
		public:
			underflow_error(const char *what_arg) : runtime_error(what_arg)
			{
			}
	};
}
#endif
