- Main Page
- Namespaces
- Classes
- Files
- Directories
- Related Pages

- File List
- File Members

# CClass.hpp File Reference

## Detailed Description

Definition of a class object.

Definition in file CClass.hpp.

Go to the source code of this file.

## Namespaces

- namespace Exponent
- namespace Exponent::Basics

## Classes

- class Exponent::Basics::CClass
    Class representation class. More...

## Defines

- #define EXPONENT_CLASS_CONSTRUCTION(theClassName) theClassName::CCLASS_THE_CLASS++;
- #define EXPONENT_CLASS_DECLARATION
- #define EXPONENT_CLASS_DESTRUCTION(theClassName) theClassName::CCLASS_THE_CLASS--;
- #define EXPONENT_CLASS_IMPLEMENTATION(theClassName, theParentName) CClass theClassName::CCLASS_THE_CLASS(#theClassName, #theParentName);
- #define EXPONENT_CLASS_IMPLEMENTATION_NO_PARENT(theClassName) CClass theClassName::CCLASS_THE_CLASS(#theClassName);
- #define EXPONENT_TEMPLATE_CLASS_IMPLEMENTATION(theClassName, TypeName, theParentName) template<class TypeName> CClass theClassName::CCLASS_THE_CLASS(#theClassName, typeid(TypeName), #theParentName);
- #define EXPONENT_TEMPLATE_CLASS_IMPLEMENTATION_NO_PARENT(theClassName, TypeName) template<class TypeName> CClass theClassName::CCLASS_THE_CLASS(#theClassName, typeid(TypeName));
- #define EXPONENT_TEMPLATE_CLASS_IMPLEMENTATION_TEMPLATE_PARENT(theClassName, TypeName, theParentName, ParentTypeName) template<class TypeName> CClass theClassName::CCLASS_THE_CLASS(#theClassName, typeid(TypeName), #theParentName, typeid(ParentTypeName));

## Define Documentation

#define EXPONENT_CLASS_CONSTRUCTION | ( | theClassName |  | ) | theClassName::CCLASS_THE_CLASS++;

Place this at the top of your constructor, passing the name of the class *without quotes* as the parameter

Definition at line 386 of file CClass.hpp.

Referenced by Exponent::Audio::TAudioFile< TypeName >::TAudioFile(), Exponent::Collections::TAutomaticPointer< Exponent::GUI::Controls::CMenuItem >::TAutomaticPointer(), Exponent::MathTools::TComplex< TypeName >::TComplex(), and Exponent::MathTools::TRandomNumberGenerator< TypeName >::TRandomNumberGenerator().

#define EXPONENT_CLASS_DECLARATION

Value:

    public:\
            virtual const CClass &getObjectClass() const { return CCLASS_THE_CLASS; }\
            static const CClass &getClass() { return CCLASS_THE_CLASS; }\
        private:\
            static CClass CCLASS_THE_CLASS;

Declares a class to be part of the Exponent class heirachy. Make sure that you place this define immediately after a classes opening brackets
It ensure that class descriptions are properly placed throughout the code.

Definition at line 339 of file CClass.hpp.

#define EXPONENT_CLASS_DESTRUCTION | ( | theClassName |  | ) | theClassName::CCLASS_THE_CLASS--;

Place this at the top of your destructor, passing the name of the class *without quotes* as the parameter

Definition at line 393 of file CClass.hpp.

Referenced by Exponent::Audio::TAudioFile< TypeName >::~TAudioFile(), Exponent::Collections::TAutomaticPointer< Exponent::GUI::Controls::CMenuItem >::~TAutomaticPointer(), Exponent::MathTools::TComplex< TypeName >::~TComplex(), and Exponent::MathTools::TRandomNumberGenerator< TypeName >::~TRandomNumberGenerator().

#define EXPONENT_CLASS_IMPLEMENTATION | ( | theClassName,
|  | theParentName |  | ) | CClass theClassName::CCLASS_THE_CLASS(#theClassName, #theParentName);

Place this at the top of your implementation file, passing the name of the class and the name of the parent class *without quotes* as the parameter The parent name must be a valid class name for it to be used as a parent matchng string.

Definition at line 358 of file CClass.hpp.

#define EXPONENT_CLASS_IMPLEMENTATION_NO_PARENT | ( | theClassName |  | ) | CClass theClassName::CCLASS_THE_CLASS(#theClassName);

Place this at the top of your implementation file, passing the name of the class *without quotes* as the parameter

Definition at line 350 of file CClass.hpp.

#define EXPONENT_TEMPLATE_CLASS_IMPLEMENTATION | ( | theClassName,
|  | TypeName,
|  | theParentName |  | ) | template<class TypeName> CClass theClassName::CCLASS_THE_CLASS(#theClassName, typeid(TypeName), #theParentName);

Place this at the top of your implementation file, passing the name of the class *without quotes* as the parameter

Definition at line 372 of file CClass.hpp.

#define EXPONENT_TEMPLATE_CLASS_IMPLEMENTATION_NO_PARENT | ( | theClassName,
|  | TypeName |  | ) | template<class TypeName> CClass theClassName::CCLASS_THE_CLASS(#theClassName, typeid(TypeName));

Place this at the top of your implementation file, passing the name of the class *without quotes* as the parameter

Definition at line 365 of file CClass.hpp.

#define EXPONENT_TEMPLATE_CLASS_IMPLEMENTATION_TEMPLATE_PARENT | ( | theClassName,
|  | TypeName,
|  | theParentName,
|  | ParentTypeName |  | ) | template<class TypeName> CClass theClassName::CCLASS_THE_CLASS(#theClassName, typeid(TypeName), #theParentName, typeid(ParentTypeName));

Place this at the top of your implementation file, passing the name of the class *without quotes* as the parameter

Definition at line 379 of file CClass.hpp.