53 lines
1.2 KiB
PHP
53 lines
1.2 KiB
PHP
<?php
|
|
|
|
class AllegroApiOfferMapBuilder
|
|
{
|
|
|
|
/**
|
|
* The (dot-path) name of this class
|
|
*/
|
|
const CLASS_NAME = 'plugins.stAllegroPlugin.lib.model.AllegroApiOfferMapBuilder';
|
|
|
|
/**
|
|
* The database map.
|
|
*/
|
|
private $dbMap;
|
|
|
|
/**
|
|
* Tells us if this DatabaseMapBuilder is built so that we
|
|
* don't have to re-build it every time.
|
|
*
|
|
* @return boolean true if this DatabaseMapBuilder is built, false otherwise.
|
|
*/
|
|
public function isBuilt()
|
|
{
|
|
return ($this->dbMap !== null);
|
|
}
|
|
|
|
/**
|
|
* Gets the databasemap this map builder built.
|
|
*
|
|
* @return the databasemap
|
|
*/
|
|
public function getDatabaseMap()
|
|
{
|
|
return $this->dbMap;
|
|
}
|
|
|
|
/**
|
|
* The doBuild() method builds the DatabaseMap
|
|
*
|
|
* @return void
|
|
* @throws PropelException
|
|
*/
|
|
public function doBuild()
|
|
{
|
|
$this->dbMap = Propel::getDatabaseMap('propel');
|
|
|
|
$tMap = $this->dbMap->addTable('st_allegro_api_offer');
|
|
$tMap->setPhpName('AllegroApiOffer');
|
|
|
|
$tMap->addPrimaryKey('ID', 'Id', 'string', CreoleTypes::CHAR, true, 38);
|
|
$tMap->addColumn('NAME', 'Name', 'string', CreoleTypes::VARCHAR, true, 255);
|
|
} // doBuild()
|
|
}
|