/*
* Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(- * * ies).
* All rights reserved.
* This component and the accompanying materials are made available
* under the terms of the License "Eclipse Public License v1.0"
* which accompanies this distribution, and is available
* at the URL "http://www.eclipse.org/legal/epl-v10.html".
*
* Initial Contributors:
* Nokia Corporation - initial contribution.
*
* Contributors:
*
* Description:
* Name : typeinfo
* Part of : standard c++ library.
*
*/
#ifndef _SYMCPP_TYPEINFO_H_
#define _SYMCPP_TYPEINFO_H_
#ifdef __EABI__
#include "exception"
namespace std
{
#ifdef __EDG__
#pragma define_type_info
#endif
class type_info
{
public:
IMPORT_C virtual ~type_info();
IMPORT_C bool operator==(const type_info&) const;
IMPORT_C bool operator!=(const type_info&) const;
IMPORT_C bool before(const type_info&) const;
IMPORT_C const char* name() const;
private:
type_info(const type_info&);
type_info& operator=(const type_info&);
private:
const char *__type_name;
};
class bad_cast : public exception
{
public:
IMPORT_C bad_cast() throw ();
IMPORT_C bad_cast(const bad_cast&) throw ();
IMPORT_C bad_cast& operator=(const bad_cast&) throw ();
IMPORT_C virtual ~bad_cast() throw ();
IMPORT_C virtual const char* what() const throw ();
};
class bad_typeid : public exception
{
public:
IMPORT_C bad_typeid() throw ();
IMPORT_C bad_typeid(const bad_typeid&) throw ();
IMPORT_C bad_typeid& operator=(const bad_typeid&) throw ();
IMPORT_C virtual ~bad_typeid() throw ();
IMPORT_C virtual const char* what() const throw ();
};
}
#else
# include <exception>
# include <cstring>
namespace std {
class bad_cast : public exception {
public :
bad_cast () __NO_THROW;
bad_cast ( const bad_cast &) __NO_THROW;
bad_cast & operator =( const bad_cast &) __NO_THROW;
virtual const char * what () const __NO_THROW;
};
class bad_typeid : public exception {
public :
bad_typeid () __NO_THROW;
bad_typeid ( const bad_typeid &) __NO_THROW;
bad_typeid & operator =( const bad_typeid &) __NO_THROW;
virtual const char * what () const __NO_THROW;
};
} //namespace std
# ifdef __WINSCW__
/*
* Incldue the header file that is as per the CodeWarrior
* typeinfo structure.
*/
# include<typeinfo_winscw.h>
# endif // __WINSCW__
#endif //__EABI__
#endif //_SYMCPP_TYPEINFO_