Click here to view and discuss this page in DocCommentXchange. In the future, you will be sent there automatically.

SQL Anywhere 10.0.1 » UltraLite - C and C++ Programming » Developing Applications Using the UltraLite C++ API

Developing Applications Using the UltraLite C++ API Next Page

Using the UltraLite namespace

The UltraLite C++ interface provides a set of classes with names that are prefixed by UltraLite_ (for example, UltraLite_Connection and UltraLite_DatabaseManager). Most of the functions for each of these classes implement a function from an underlying interface with the string _iface appended to it. For example, the UltraLite_Connection class implements functions from UltraLite_Connection_iface.

When you explicitly use the UltraLite namespace, you can use a shorter name to refer to each class. Instead of declaring a connection as an UltraLite_Connection object, you can declare it as a Connection object if you are using the UltraLite namespace:

using namespace UltraLite;
ULSqlca sqlca;
DatabaseManager * dbMgr = ULInitDatabaseManager(sqlca);
Connection *  conn = UL_NULL;

As a result of this architecture, code samples in this chapter use types such as DatabaseManager, Connection, and TableSchema, but links for more information may direct you to UltraLite_DatabaseManager_iface, UltraLite_Connection_iface, and UltraLite_TableSchema_iface, respectively.