rasdaman API
Public Member Functions | List of all members
r_Ref_Any Class Reference

#include <ref.hh>

Public Member Functions

 r_Ref_Any ()
 default constructor More...
 
 r_Ref_Any (const r_Ref_Any &)
 copy constructor More...
 
 r_Ref_Any (const r_OId &initOId)
 constructor for creating a reference with an oid More...
 
 r_Ref_Any (r_Object *)
 constructor getting a pointer to a persistent capable object More...
 
 r_Ref_Any (void *)
 constructor getting a general pointer More...
 
 ~r_Ref_Any ()
 destructor deletes referenced object from main memory and database More...
 
r_Ref_Anyoperator= (const r_Ref_Any &)
 assignment operator for assigning a {r_Ref_Any} pointer More...
 
r_Ref_Anyoperator= (r_Object *)
 assignment operator for assigning a pointer to a persistent capable object More...
 
void destroy ()
 delete from main memory More...
 
void delete_object ()
 deletes referenced object from main memory and database More...
 
int operator! () const
 operator for validity test More...
 
int is_null () const
 method for reference validity test More...
 
const r_OIdget_oid () const
 get oid More...
 
 operator const void * () const
 
 operator void * ()
 
 operator r_Point * ()
 
 operator r_Sinterval * ()
 
 operator r_Minterval * ()
 
 operator r_OId * ()
 
 operator r_Scalar * ()
 
 operator r_Structure * ()
 
 operator r_Primitive * ()
 
int operator== (const r_Ref_Any &) const
 
int operator!= (const r_Ref_Any &) const
 
int operator== (const r_Object *) const
 compares the memory pointer (does not load the object) More...
 
int operator!= (const r_Object *) const
 compares the memory pointer (does not load the object) More...
 
 r_Ref_Any (const r_OId &, r_Object *)
 constructor getting oid and memory pointer More...
 
unsigned int is_oid_valid () const
 
void * get_memory_ptr () const
 get memory pointer (without loading the object) More...
 

Detailed Description

The class {r_Ref_Any} is defined to support a reference to any type. Its primary purpose is to handle generic refernces and allow conversions of {r_Ref}s in the type hierarchy. A {r_Ref_Any} object can be used as an intermediary between any two types {r_Ref}<X> and {r_Ref}<Y> where X and Y are different types. A {r_Ref}<T> can always be converted to a {r_Ref_Any}; there is a function to perform the conversion in the {r_Ref}<T> template. Each {r_Ref}<T> class has a constructor and assignment operator that takes a reference to a {r_Ref_Any}.

Constructor & Destructor Documentation

r_Ref_Any::r_Ref_Any ( )

default constructor

r_Ref_Any::r_Ref_Any ( const r_Ref_Any )

copy constructor

r_Ref_Any::r_Ref_Any ( const r_OId initOId)

constructor for creating a reference with an oid

r_Ref_Any::r_Ref_Any ( r_Object )

constructor getting a pointer to a persistent capable object

Dereferencing the self object results in loading the object with { initOId}.

r_Ref_Any::r_Ref_Any ( void *  )

constructor getting a general pointer

r_Ref_Any::~r_Ref_Any ( )

destructor deletes referenced object from main memory and database

r_Ref_Any::r_Ref_Any ( const r_OId ,
r_Object  
)

constructor getting oid and memory pointer

Member Function Documentation

void r_Ref_Any::delete_object ( )

deletes referenced object from main memory and database

void r_Ref_Any::destroy ( )

delete from main memory

void* r_Ref_Any::get_memory_ptr ( ) const

get memory pointer (without loading the object)

const r_OId& r_Ref_Any::get_oid ( ) const
inline

get oid

int r_Ref_Any::is_null ( ) const

method for reference validity test

unsigned int r_Ref_Any::is_oid_valid ( ) const
inline
r_Ref_Any::operator const void * ( ) const
r_Ref_Any::operator r_Minterval * ( )
r_Ref_Any::operator r_OId * ( )
r_Ref_Any::operator r_Point * ( )
r_Ref_Any::operator r_Primitive * ( )
r_Ref_Any::operator r_Scalar * ( )
r_Ref_Any::operator r_Sinterval * ( )
r_Ref_Any::operator r_Structure * ( )
r_Ref_Any::operator void * ( )
int r_Ref_Any::operator! ( ) const

operator for validity test

int r_Ref_Any::operator!= ( const r_Ref_Any ) const
int r_Ref_Any::operator!= ( const r_Object ) const

compares the memory pointer (does not load the object)

r_Ref_Any& r_Ref_Any::operator= ( const r_Ref_Any )

assignment operator for assigning a {r_Ref_Any} pointer

r_Ref_Any& r_Ref_Any::operator= ( r_Object )

assignment operator for assigning a pointer to a persistent capable object

int r_Ref_Any::operator== ( const r_Ref_Any ) const

The method delivers true iff the oid and/or the memory pointer are valid.

int r_Ref_Any::operator== ( const r_Object ) const

compares the memory pointer (does not load the object)


The documentation for this class was generated from the following file: