gatelib  2.1
g_cont_ref_const.h
1 #pragma once
2 
3 #include "g_cont_ref_base.h"
4 
5 namespace g
6 {
7 namespace cont
8 {
9 
10 template < class T > class ref_const : public ref_base<T>
11 {
12 public:
13  ref_const() { G_VERBOSE_MSG_L5("ref_const::ref_const()"); }
14  ref_const ( const ref_const<T>& o ) { G_VERBOSE_MSG_L5("ref_const::ref_const ( const ref_base<T>& o )"); this->mRefTake(o); }
15  ref_const ( const ref_custom<T>& o ) { G_VERBOSE_MSG_L5("ref_const::ref_const ( const ref_custom<T>& o )"); this->mRefTake(o); }
16 
17  ref_const& operator = ( const ref_const<T>& o ) { G_VERBOSE_MSG_L5("ref_const::operator = ( const ref_const<T>& )"); this->mRefTake(o); return *this; }
18  ref_const& operator = ( const ref_custom<T>& o ) { G_VERBOSE_MSG_L5("ref_const::operator = ( const ref_custom<T>& )"); this->mRefTake(o); return *this; }
19 
20  template < class O > operator ref_const() { G_VERBOSE_MSG_L5(operator ref_const()); ref_const<O> res; res.mRefTake (*this); return res; }
21 
22  const T& operator *() const { return *this->mGetObjP(); }
23  const T* operator ->() const { return this->mGetObjP(); }
24 };
25 
26 }//namespace g
27 }//namespace cont
28 
29 
30 
Definition: g.mthread.ThreadSimpleEvent.h:5