Class xPDOGenerator_sqlite

Description

An extension for generating xPDOObject class and map files for SQLite.

A SQLite-specific extension to an xPDOManager instance that can generate class stub and meta-data map files from a provided XML schema of a database structure.

Located in /xpdo/om/sqlite/xpdogenerator.class.php (line 43)

xPDOGenerator
   |
   --xPDOGenerator_sqlite
Method Summary
 void compile ([ $path = ''])
 void getIndex ( $index)
 boolean writeSchema (string $schemaFile, [string $package = ''], [string $baseClass = ''], [string $tablePrefix = ''], [boolean $restrictPrefix = false])
Variables
Methods
compile (line 44)
  • access: public
void compile ([ $path = ''])
  • $path

Redefinition of:
xPDOGenerator::compile()
Compile the packages into a single file for quicker loading.
getIndex (line 48)
  • access: public
void getIndex ( $index)
  • $index

Redefinition of:
xPDOGenerator::getIndex()
Format the passed database index value as an XML attribute.
writeSchema (line 70)

Write an xPDO XML Schema from your database.

  • return: True on success, false on failure.
  • access: public
boolean writeSchema (string $schemaFile, [string $package = ''], [string $baseClass = ''], [string $tablePrefix = ''], [boolean $restrictPrefix = false])
  • string $schemaFile: The name (including path) of the schemaFile you want to write.
  • string $package: Name of the package to generate the classes in.
  • string $baseClass: The class which all classes in the package will extend; by default this is set to xPDOObject and any auto_increment fields with the column name 'id' will extend xPDOSimpleObject automatically.
  • string $tablePrefix: The table prefix for the current connection, which will be removed from all of the generated class and table names. Specify a prefix when creating a new xPDO instance to recreate the tables with the same prefix, but still use the generic class names.
  • boolean $restrictPrefix: Only reverse-engineer tables that have the specified tablePrefix; if tablePrefix is empty, this is ignored.

Inherited Methods

Inherited From xPDOGenerator

 xPDOGenerator::__construct()
 xPDOGenerator::compile()
 xPDOGenerator::getClassName()
 xPDOGenerator::getClassPlatformTemplate()
 xPDOGenerator::getClassTemplate()
 xPDOGenerator::getDefault()
 xPDOGenerator::getIndex()
 xPDOGenerator::getMapFooter()
 xPDOGenerator::getMapHeader()
 xPDOGenerator::getTableName()
 xPDOGenerator::outputClasses()
 xPDOGenerator::outputMaps()
 xPDOGenerator::parseSchema()
 xPDOGenerator::_handleCData()
 xPDOGenerator::_handleCloseElement()
 xPDOGenerator::_handleOpenElement()

Documentation generated on Fri, 17 Jun 2011 10:04:07 -0600 by phpDocumentor 1.4.3