DB Link
API Reference Guide
Product Documentation:

Visualization DB Link
Documentation Home
List of all members | Public Member Functions
IldKey Class Reference

This class describes the primary key of the tables. More...

#include <ildblink/ildrel.h>

Inheritance diagram for IldKey:
IldFKey IldTableIndex

Public Member Functions

const IldColumngetColumn (IlUShort index) const
 Get a column from the relation. More...
 
IlUShort getCount () const
 Get the number of columns in the key. More...
 
IldKeyType getKeyType () const
 Get the type of the key. More...
 
const char * getName () const
 Get the name. More...
 
IlBoolean isForeign () const
 Tell if the key is foreign. More...
 
IlBoolean isPrimary () const
 Tell is the key is a primary key. More...
 
IlBoolean isSpecialColumn () const
 Tell if this key is a special columns key. More...
 

Detailed Description

This class describes the primary key of the tables.

Library: dbkernel

It is also the base class for the foreign keys, indexes, and special-column description.

See also
IldDbms, IldFKey, IldRelation, IldTableIndex.

Member Function Documentation

◆ getColumn()

const IldColumn * IldKey::getColumn ( IlUShort  index) const

Get a column from the relation.

Parameters
indexThe column index.
Returns
The column object situated at the position index of the current key.

◆ getCount()

IlUShort IldKey::getCount ( ) const

Get the number of columns in the key.

Returns
The number of columns that makes up the key of the related table.

◆ getKeyType()

IldKeyType IldKey::getKeyType ( ) const

Get the type of the key.

Returns
The type of the current object as one of the possible values from the enumeration IldKeyType.

◆ getName()

const char * IldKey::getName ( ) const

Get the name.

Returns
The name of the key, if any.

If the key is not named, a null pointer is returned.

◆ isForeign()

IlBoolean IldKey::isForeign ( ) const

Tell if the key is foreign.

Returns
IlTrue if the current object is a foreign key descriptor, or IlFalse otherwise.

◆ isPrimary()

IlBoolean IldKey::isPrimary ( ) const

Tell is the key is a primary key.

Returns
IlTrue if the current object is a primary key descriptor, IlFalse otherwise.

◆ isSpecialColumn()

IlBoolean IldKey::isSpecialColumn ( ) const

Tell if this key is a special columns key.

Returns
IlTrue if the current object describes the special columns of the relation, IlFalse otherwise.