|
STK++ 1.0
|
The Proxy classe allow to surdefine operators and methods for every kind of class without using dynamic_cast. More...
#include <STK_Proxy.h>

Public Member Functions | |
| Proxy (TYPE &x) | |
| Default constructor : create a reference of the Real x. | |
| Proxy & | operator= (TYPE const &x) |
| overwrite with a TYPE. | |
| virtual | ~Proxy () |
| Virtual destructor. | |
| Proxy & | operator= (const Proxy< TYPE > &x) |
| overwrite with a Proxy<TYPE>. | |
| Proxy & | operator= (const ConstProxy< TYPE > &x) |
| overwrite with a ConstProxy<TYPE>. | |
| operator TYPE & () | |
| Conversion operator to TYPE. | |
| operator TYPE const & () const | |
| Constant Conversion operator to TYPE. | |
Protected Attributes | |
| TYPE & | x_ |
| A reference on the object wrapped. | |
The Proxy classe allow to surdefine operators and methods for every kind of class without using dynamic_cast.
This class allow:
dynamic_cast Definition at line 96 of file STK_Proxy.h.
| STK::Proxy< TYPE >::Proxy | ( | TYPE & | x | ) | [inline] |
Default constructor : create a reference of the Real x.
| x | the object to wrap |
Definition at line 105 of file STK_Proxy.h.
: x_(x) { ;}
| virtual STK::Proxy< TYPE >::~Proxy | ( | ) | [inline, virtual] |
| Proxy& STK::Proxy< TYPE >::operator= | ( | TYPE const & | x | ) | [inline] |
overwrite with a TYPE.
| x | the value to wrapp |
Definition at line 111 of file STK_Proxy.h.
References STK::Proxy< TYPE >::x_.
{
x_ = x;
return *this;
}
| Proxy& STK::Proxy< TYPE >::operator= | ( | const Proxy< TYPE > & | x | ) | [inline] |
overwrite with a Proxy<TYPE>.
| x | a wrapped value to copy |
Definition at line 124 of file STK_Proxy.h.
References STK::Proxy< TYPE >::x_.
{
x_ = x;
return *this;
}
| Proxy& STK::Proxy< TYPE >::operator= | ( | const ConstProxy< TYPE > & | x | ) | [inline] |
overwrite with a ConstProxy<TYPE>.
| x | a constant wrapped value to set |
Definition at line 133 of file STK_Proxy.h.
References STK::Proxy< TYPE >::x_.
{
x_ = x;
return *this;
}
| STK::Proxy< TYPE >::operator TYPE & | ( | ) | [inline] |
Conversion operator to TYPE.
Definition at line 141 of file STK_Proxy.h.
References STK::Proxy< TYPE >::x_.
{ return x_;}
| STK::Proxy< TYPE >::operator TYPE const & | ( | ) | const [inline] |
Constant Conversion operator to TYPE.
Definition at line 146 of file STK_Proxy.h.
References STK::Proxy< TYPE >::x_.
{ return x_;}
TYPE& STK::Proxy< TYPE >::x_ [protected] |
A reference on the object wrapped.
Definition at line 99 of file STK_Proxy.h.
Referenced by STK::Proxy< TYPE >::operator TYPE &(), STK::Proxy< TYPE >::operator TYPE const &(), and STK::Proxy< TYPE >::operator=().