ProfessionsTableMapBuilder.php 1.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576
  1. <?php
  2. /**
  3. * This class adds structure of 'professions' table to 'propel' DatabaseMap object.
  4. *
  5. *
  6. * This class was autogenerated by Propel 1.3.0-dev on:
  7. *
  8. * Sat Sep 26 07:07:41 2009
  9. *
  10. *
  11. * These statically-built map classes are used by Propel to do runtime db structure discovery.
  12. * For example, the createSelectSql() method checks the type of a given column used in an
  13. * ORDER BY clause to know whether it needs to apply SQL to make the ORDER BY case-insensitive
  14. * (i.e. if it's a text column type).
  15. *
  16. * @package lib.model.map
  17. */
  18. class ProfessionsTableMapBuilder implements MapBuilder {
  19. /**
  20. * The (dot-path) name of this class
  21. */
  22. const CLASS_NAME = 'lib.model.map.ProfessionsTableMapBuilder';
  23. /**
  24. * The database map.
  25. */
  26. private $dbMap;
  27. /**
  28. * Tells us if this DatabaseMapBuilder is built so that we
  29. * don't have to re-build it every time.
  30. *
  31. * @return boolean true if this DatabaseMapBuilder is built, false otherwise.
  32. */
  33. public function isBuilt()
  34. {
  35. return ($this->dbMap !== null);
  36. }
  37. /**
  38. * Gets the databasemap this map builder built.
  39. *
  40. * @return the databasemap
  41. */
  42. public function getDatabaseMap()
  43. {
  44. return $this->dbMap;
  45. }
  46. /**
  47. * The doBuild() method builds the DatabaseMap
  48. *
  49. * @return void
  50. * @throws PropelException
  51. */
  52. public function doBuild()
  53. {
  54. $this->dbMap = Propel::getDatabaseMap(ProfessionsTablePeer::DATABASE_NAME);
  55. $tMap = $this->dbMap->addTable(ProfessionsTablePeer::TABLE_NAME);
  56. $tMap->setPhpName('ProfessionsTable');
  57. $tMap->setClassname('ProfessionsTable');
  58. $tMap->setUseIdGenerator(false);
  59. $tMap->addPrimaryKey('ID', 'Id', 'INTEGER', true, 11);
  60. $tMap->addColumn('NAME', 'Name', 'VARCHAR', true, 20);
  61. } // doBuild()
  62. } // ProfessionsTableMapBuilder