PermissionsTableMapBuilder.php 2.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384
  1. <?php
  2. /**
  3. * This class adds structure of 'permissions' 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:40 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 PermissionsTableMapBuilder implements MapBuilder {
  19. /**
  20. * The (dot-path) name of this class
  21. */
  22. const CLASS_NAME = 'lib.model.map.PermissionsTableMapBuilder';
  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(PermissionsTablePeer::DATABASE_NAME);
  55. $tMap = $this->dbMap->addTable(PermissionsTablePeer::TABLE_NAME);
  56. $tMap->setPhpName('PermissionsTable');
  57. $tMap->setClassname('PermissionsTable');
  58. $tMap->setUseIdGenerator(true);
  59. $tMap->addPrimaryKey('ID', 'Id', 'INTEGER', true, 11);
  60. $tMap->addForeignKey('LINK_ID', 'LinkId', 'INTEGER', 'links', 'ID', true, 11);
  61. $tMap->addColumn('GID', 'Gid', 'VARCHAR', false, 15);
  62. $tMap->addColumn('MODE', 'Mode', 'CHAR', true, null);
  63. $tMap->addColumn('CHANGE_AT', 'ChangeAt', 'TIMESTAMP', true, null);
  64. $tMap->addColumn('CHANGE_LOGIN', 'ChangeLogin', 'VARCHAR', true, 25);
  65. } // doBuild()
  66. } // PermissionsTableMapBuilder