Rogue Wave Views
Data Access Package API Reference Guide
Product Documentation:

Rogue Wave Views
Documentation Home
List of all members | Public Member Functions
IliSQLCatalog Class Reference

User interface class. More...

#include <ilviews/dataccess/tbldef.h>

Public Member Functions

 IliSQLCatalog (IlvDisplay *display)
 Initializes a new, empty catalog. More...
 
 IliSQLCatalog (const IliSQLCatalog &source)
 Copy constructor for the class IliSQLCatalog. More...
 
IlInt appendTableDef (IliSQLTableDef *def)
 Appends the table definition at the end of the catalog. More...
 
void deleteAll ()
 Removes and deletes all the table definitions in the catalog.
 
IlvDisplaygetDisplay () const
 Returns the display of the catalog. More...
 
const IliSQLTableDefgetTableDef (IlInt p) const
 Returns the table definition. More...
 
IliSQLTableDefgetTableDef (IlInt p)
 Returns the table definition. More...
 
const IliSQLTableDefgetTableDef (const IliSQLTableRef &ref) const
 Returns the first table definition in the catalog with a given t able reference. More...
 
IliSQLTableDefgetTableDef (const IliSQLTableRef &ref)
 Returns the first table definition in the catalog with a given table reference. More...
 
IlInt getTableDefIndex (const IliSQLTableRef &ref) const
 Returns the position, in the catalog, of the first table definition with a specific table reference. More...
 
IlInt getTableDefIndex (const IliSQLTableDef *tdef) const
 Returns the position, in the catalog, of the table definition. More...
 
IlInt getTableDefsCount () const
 Returns the number of table definitions in the catalog. More...
 
IlBoolean insertTableDef (IlInt pos, IliSQLTableDef *def)
 Inserts a table definition in the catalog. More...
 
void read (std::istream &input)
 Reads the definition of the catalog from an input stream. More...
 
void removeTableDef (IlInt index, IlBoolean deleteIt=IlTrue)
 Removes the table definition from the catalog. More...
 
void write (std::ostream &output) const
 Writes the definition of the catalog to an output stream in a form suitable to be read back by the read member function. More...
 

Detailed Description

User interface class.

Library: dataccess
An IliSQLCatalog contains an ordered collection of IliSQLTableDef objects. It is used to hold a subset of the schema of a database.

See also
IliSQLTableDef, IliSQLTableRef.

Constructor & Destructor Documentation

§ IliSQLCatalog() [1/2]

IliSQLCatalog::IliSQLCatalog ( IlvDisplay display)

Initializes a new, empty catalog.

Parameters
displayThe display.

§ IliSQLCatalog() [2/2]

IliSQLCatalog::IliSQLCatalog ( const IliSQLCatalog source)

Copy constructor for the class IliSQLCatalog.

Parameters
sourceThe catalog to be copied.

Member Function Documentation

§ appendTableDef()

IlInt IliSQLCatalog::appendTableDef ( IliSQLTableDef def)

Appends the table definition at the end of the catalog.

Once a table definition has been inserted into a catalog, the catalog becomes the owner of this table definition.

Parameters
defThe table definition.
Returns
The insertion position.

§ getDisplay()

IlvDisplay* IliSQLCatalog::getDisplay ( ) const

Returns the display of the catalog.

Returns
The display of the catalog.

§ getTableDef() [1/4]

const IliSQLTableDef* IliSQLCatalog::getTableDef ( IlInt  p) const

Returns the table definition.

Parameters
pThe position.
Returns
The table definition.

§ getTableDef() [2/4]

IliSQLTableDef* IliSQLCatalog::getTableDef ( IlInt  p)

Returns the table definition.

Parameters
pThe position.
Returns
The table definition.

§ getTableDef() [3/4]

const IliSQLTableDef* IliSQLCatalog::getTableDef ( const IliSQLTableRef ref) const

Returns the first table definition in the catalog with a given t able reference.

Parameters
refThe table reference.
Returns
The table definition, or 0 if no such table definition is found.

§ getTableDef() [4/4]

IliSQLTableDef* IliSQLCatalog::getTableDef ( const IliSQLTableRef ref)

Returns the first table definition in the catalog with a given table reference.

Parameters
refThe table reference.
Returns
The table definition, or 0 if no such table definition is found.

§ getTableDefIndex() [1/2]

IlInt IliSQLCatalog::getTableDefIndex ( const IliSQLTableRef ref) const

Returns the position, in the catalog, of the first table definition with a specific table reference.

Parameters
refThe table reference.
Returns
The position, or -1 if no such table definition is found.

§ getTableDefIndex() [2/2]

IlInt IliSQLCatalog::getTableDefIndex ( const IliSQLTableDef tdef) const

Returns the position, in the catalog, of the table definition.

Parameters
tdefThe table definition.
Returns
The position, in the catalog, of the table definition or -1 if it does not belong to the catalog.

§ getTableDefsCount()

IlInt IliSQLCatalog::getTableDefsCount ( ) const

Returns the number of table definitions in the catalog.

Returns
The number of table definitions in the catalog.

§ insertTableDef()

IlBoolean IliSQLCatalog::insertTableDef ( IlInt  pos,
IliSQLTableDef def 
)

Inserts a table definition in the catalog.

Parameters
posThe insertion position.
defThe table definition.
Returns
IlTrue if successful.

§ read()

void IliSQLCatalog::read ( std::istream &  input)

Reads the definition of the catalog from an input stream.

Parameters
inputThe input stream.

§ removeTableDef()

void IliSQLCatalog::removeTableDef ( IlInt  index,
IlBoolean  deleteIt = IlTrue 
)

Removes the table definition from the catalog.

Parameters
indexThe table definition position.
deleteItIf IlTrue, the table definition object is also deleted.

§ write()

void IliSQLCatalog::write ( std::ostream &  output) const

Writes the definition of the catalog to an output stream in a form suitable to be read back by the read member function.

Parameters
outputThe output stream.

© Copyright 2018, Rogue Wave Software, Inc. All Rights Reserved.
Rogue Wave is a registered trademark of Rogue Wave Software, Inc. in the United States and other countries. All other trademarks are the property of their respective owners.