public

Inheritance Graph

graph BT
	ReferenceObject
	ReferenceObject --> Object
	click ReferenceObject "classEScript_1_1ReferenceObject"
	click Object "classEScript_1_1Object"

Description

[ ReferenceObject ] > [ Object ] A ReferenceObject can be used as wrapper for user defined C++ objects. The encapsulated data can be an object, a pointer or a smart reference and is defined by the first template parameter.

The second template parameter defines how two instances are compared during an test for equality. If the default value ‘ Policies::EqualContent_ComparePolicy ‘ is used, the two referenced values are compared using their ‘==’-operator (which has to be defined for the values’s type). If ‘Policies::SameEObjects’ is used, the pointers of the two compared ReferenceObject are used for equality testing. The latter can be used if the values is an object (and not a reference) and the this object does not define a ‘==’ operator.

Public Types

   
   
typedef ReferenceObject < _T, comparisonPolicy > ReferenceObject_t

Public Functions

     
     
  ReferenceObject( Type * type)
(ctor) Uses referenced object’s default constructor.
 
template< typename other_type_t , typename >    
  ReferenceObject(other_type_t && otherObject, Type * type)
(ctor) Passes a reference or rvalue reference to the object’s constructor (if possible)
 
template< typename… args >    
  ReferenceObject( Type * type, args &&… params)
(ctor) Passes arbitrary parameters to the object’s constructor.
 
     
  ~ReferenceObject()  
     
const _T & ref() const  
     
_T & ref()  
     
const _T & operator*() const  
     
_T & operator*()  
     
ReferenceObject_t * clone() const  
     
bool rt_isEqual( Runtime & void, const ObjPtr & o)
> [ Object ]

Documentation

typedef
EScript::ReferenceObject::ReferenceObject_t

public
 
 
typedef ReferenceObject < _T, comparisonPolicy > ReferenceObject_t

Defined in EScript/EScript/Objects/ReferenceObject.h:50


function
EScript::ReferenceObject::ReferenceObject

public inline
     
     
ReferenceObject( Type * type )

(ctor) Uses referenced object’s default constructor.

Defined in EScript/EScript/Objects/ReferenceObject.h:55


function
EScript::ReferenceObject::ReferenceObject

public inline explicit
     
template< typename other_type_t , typename = typename std::enable_if<std::is_convertible<other_type_t, _T>:: value >::type >    
ReferenceObject( other_type_t && otherObject,
  Type * type
)    

(ctor) Passes a reference or rvalue reference to the object’s constructor (if possible)

Defined in EScript/EScript/Objects/ReferenceObject.h:61


function
EScript::ReferenceObject::ReferenceObject

public inline explicit
     
template< typename… args >    
ReferenceObject( Type * type,
  args &&… params
)    

(ctor) Passes arbitrary parameters to the object’s constructor.

Defined in EScript/EScript/Objects/ReferenceObject.h:67


function
EScript::ReferenceObject::~ReferenceObject

public inline virtual
   
   
~ReferenceObject( )

Defined in EScript/EScript/Objects/ReferenceObject.h:71


function
EScript::ReferenceObject::ref

public const inline
   
   
const _T & ref( ) const

Defined in EScript/EScript/Objects/ReferenceObject.h:73


function
EScript::ReferenceObject::ref

public inline
   
   
_T & ref( )

Defined in EScript/EScript/Objects/ReferenceObject.h:74


function
EScript::ReferenceObject::operator*

public const inline
   
   
const _T & operator*( ) const

Defined in EScript/EScript/Objects/ReferenceObject.h:76


function
EScript::ReferenceObject::operator*

public inline
   
   
_T & operator*( )

Defined in EScript/EScript/Objects/ReferenceObject.h:77


function
EScript::ReferenceObject::clone

public const inline virtual
   
   
ReferenceObject_t * clone( ) const
> [ Object ] Direct cloning of a ReferenceObject is forbidden; but you may override the clone function in the specific implementation

Defined in EScript/EScript/Objects/ReferenceObject.h:81


function
EScript::ReferenceObject::rt_isEqual

public inline virtual
     
     
bool rt_isEqual( Runtime & void,
  const ObjPtr & o
)    
> [ Object ]

Defined in EScript/EScript/Objects/ReferenceObject.h:86