Public Member Functions | Protected Attributes | Friends

dbReference< T > Class Template Reference

#include <reference.h>

Inheritance diagram for dbReference< T >:
dbAnyReference

List of all members.

Public Member Functions

dbFieldDescriptordbDescribeComponents (dbFieldDescriptor *fd)
dbReference< T > & operator= (dbReference< T > const &ref)
dbReference< T > & operator= (dbNullReference const &)
dbReference< T > & unsafeAssign (dbAnyReference const &ref)
bool operator== (dbReference< T > const &ref) const
bool operator!= (dbReference< T > const &ref) const
bool operator== (dbNullReference const &) const
bool operator!= (dbNullReference const &) const
 dbReference (dbNullReference const &)
 dbReference (dbReference< T > const &ref)
 dbReference (oid_t oid=0)
oid_t getOid () const
bool isNull () const

Protected Attributes

oid_t oid

Friends

bool isNull (dbAnyReference const &ref)

Detailed Description

template<class T>
class dbReference< T >

Template for reference parameterized by class of referenced records.


Constructor & Destructor Documentation

template<class T>
dbReference< T >::dbReference ( dbNullReference const &   )  [inline]

Constructor of null reference

template<class T>
dbReference< T >::dbReference ( dbReference< T > const &  ref  )  [inline]

Copy constructor from reference of the same type

template<class T>
dbReference< T >::dbReference ( oid_t  oid = 0  )  [inline]

Construstor of reference from OID. Use this constructor with care, because GigaBASE is not able to check if asigned OID belongs to the required table. If you assign OID of record friom some other table and then use this reference, results will be unpredicted (even database corruption is possible)


Member Function Documentation

oid_t dbAnyReference::getOid (  )  const [inline, inherited]
bool dbAnyReference::isNull (  )  const [inline, inherited]

Check whether reference is null

template<class T>
bool dbReference< T >::operator!= ( dbNullReference const &   )  const [inline]

Operator for cecking if reference is not null

template<class T>
bool dbReference< T >::operator!= ( dbReference< T > const &  ref  )  const [inline]

Operator for comparision of two references of the same type

template<class T>
dbReference<T>& dbReference< T >::operator= ( dbReference< T > const &  ref  )  [inline]

Assignment operator

Parameters:
ref assigned reference of the same type
Returns:
this reference
template<class T>
dbReference<T>& dbReference< T >::operator= ( dbNullReference const &   )  [inline]

Operator for assigning null to reference

Returns:
this reference
template<class T>
bool dbReference< T >::operator== ( dbNullReference const &   )  const [inline]

Operator for cecking if reference is null

template<class T>
bool dbReference< T >::operator== ( dbReference< T > const &  ref  )  const [inline]

Operator for comparision of two references of the same type

template<class T>
dbReference<T>& dbReference< T >::unsafeAssign ( dbAnyReference const &  ref  )  [inline]

Unsafe assignment operator. Assign any refernce.

Parameters:
ref assigned reference. If it is not of the same type - result is unpredicted.
Returns:
this reference

Friends And Related Function Documentation

bool isNull ( dbAnyReference const &  ref  )  [friend, inherited]

Check whether reference is null


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