Public Member Functions

ChildTable< ROW, DIMS > Class Template Reference

Table with two indexes for rows with a primary key and a foreign key. More...

#include <rdb/rdb.h>

Inherits RDB::SimpleTable< ROW, DIMS >.

List of all members.

Public Member Functions


Detailed Description

template<class ROW, int DIMS = 2>
class RDB::ChildTable< ROW, DIMS >

Table with two indexes for rows with a primary key and a foreign key.


Constructor & Destructor Documentation

ChildTable (  )  [inline]

Default constructor.


Member Function Documentation

void initParentIndex ( int  size,
typename Base::KeyMethod  keyMethod 
) [inline]

Initialize the parent (foreign) index.

Parameters:
size Size of the hash table to use.
keyMethod Pointer to method returning the foreign key.
ForeignIndex<ROW> parentIndex (  )  [inline]

Return the foreign index.

ForeignConstIndex<ROW> parentIndex (  )  const [inline]

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

void removeChildren ( int  parentKey  )  [inline]

Remove all rows with the given foreign key.