kexi

Kross::KexiDB::KexiDBSchema< T > Class Template Reference

#include <kexidbschema.h>

Inherits Kross::Api::Class< T >.

Public Member Functions

 KexiDBSchema (const TQString &name, ::KexiDB::SchemaData *schema, ::KexiDB::FieldList *fieldlist)
 

Protected Attributes

::KexiDB::SchemaData * m_schema
 
::KexiDB::FieldList * m_fieldlist
 

Detailed Description

template<class T>
class Kross::KexiDB::KexiDBSchema< T >

The KexiDBSchema object provides common functionality for schemas like KexiDBTableSchema or KexiDBQuerySchema.

Example (in Python) ;

# Get the tableschema from a KexiDBConnection object.
tableschema = connection.tableSchema("dept")
# Print some information.
print "table=%s description=%s" % (tableschema.name(), tableschema.description())
# Get the "SELECT * FROM dept;" queryschema for the table.
queryschema = tableschema.query()
# Walk through the fields/columns the queryschema has and print the fieldnames.
for field in queryschema.fieldlist().fields():
print "fieldname=%s" % field.name()
# Execute the query. The returned KexiDBCursor object could be used then to iterate through the result.
cursor = connection.executeQuerySchema(queryschema)

Definition at line 59 of file kexidbschema.h.

Constructor & Destructor Documentation

◆ KexiDBSchema()

template<class T >
KexiDBSchema::KexiDBSchema ( const TQString &  name,
::KexiDB::SchemaData *  schema,
::KexiDB::FieldList *  fieldlist 
)

Definition at line 36 of file kexidbschema.cpp.

◆ ~KexiDBSchema()

template<class T >
KexiDBSchema::~KexiDBSchema< T > ( )
virtual

Definition at line 36 of file kexidbschema.cpp.

Member Data Documentation

◆ m_fieldlist

template<class T >
::KexiDB::FieldList* Kross::KexiDB::KexiDBSchema< T >::m_fieldlist
protected

Definition at line 87 of file kexidbschema.h.

◆ m_schema

template<class T >
::KexiDB::SchemaData* Kross::KexiDB::KexiDBSchema< T >::m_schema
protected

Definition at line 86 of file kexidbschema.h.


The documentation for this class was generated from the following files: