dbReference Class Template Reference

#include <reference.h>

Inheritance diagram for dbReference:

dbAnyReference

List of all members.


Detailed Description

template<class T>
class dbReference< T >

Template for reference parameterized by class of referenced records.

Public Member Functions

dbFieldDescriptordbDescribeComponents (dbFieldDescriptor *fd)
 Internal method used to describe reference.
dbReferenceoperator= (dbReference const &ref)
 Assignment operator.
dbReferenceoperator= (dbNullReference const &)
 Operator for assigning null to reference.
dbReference< T > & unsafeAssign (dbAnyReference const &ref)
 Unsafe assignment operator.
bool operator== (dbReference const &ref) const
 Operator for comparision of two references of the same type.
bool operator!= (dbReference const &ref) const
 Operator for comparision of two references of the same type.
bool operator== (dbNullReference const &) const
 Operator for cecking if reference is null.
bool operator!= (dbNullReference const &) const
 Operator for cecking if reference is not null.
 dbReference (dbNullReference const &)
 Constructor of null reference.
 dbReference (dbReference const &ref)
 Copy constructor from reference of the same type.
 dbReference (oid_t oid=0)
 Construstor of reference from OID.

Constructor & Destructor Documentation

dbReference ( dbNullReference const &   )  [inline]

Constructor of null reference.

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

Copy constructor from reference of the same type.

dbReference ( oid_t  oid = 0  )  [inline]

Construstor of reference from OID.

Use this constructor with care, because FastDB 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

dbFieldDescriptor* dbDescribeComponents ( dbFieldDescriptor fd  )  [inline]

Internal method used to describe reference.

Reimplemented from dbAnyReference.

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

Assignment operator.

Parameters:
ref assigned reference of the same type
Returns:
this reference

dbReference& operator= ( dbNullReference const &   )  [inline]

Operator for assigning null to reference.

Returns:
this reference

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

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

Operator for comparision of two references of the same type.

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

Operator for comparision of two references of the same type.

bool operator== ( dbNullReference const &   )  const [inline]

Operator for cecking if reference is null.

bool operator!= ( dbNullReference const &   )  const [inline]

Operator for cecking if reference is not null.


Online Library Docs

sipXecs home page

Version 4.2.1-018930 2010-07-31T01:13:23 build16 abuild