TableBugsProductsCustom.php 2.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. <?php
  2. /**
  3. * Zend Framework
  4. *
  5. * LICENSE
  6. *
  7. * This source file is subject to the new BSD license that is bundled
  8. * with this package in the file LICENSE.txt.
  9. * It is also available through the world-wide-web at this URL:
  10. * http://framework.zend.com/license/new-bsd
  11. * If you did not receive a copy of the license and are unable to
  12. * obtain it through the world-wide-web, please send an email
  13. * to license@zend.com so we can send you a copy immediately.
  14. *
  15. * @category Zend
  16. * @package Zend_Db
  17. * @subpackage UnitTests
  18. * @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
  19. * @license http://framework.zend.com/license/new-bsd New BSD License
  20. * @version $Id$
  21. */
  22. /**
  23. * @see Zend_Db_Table_TableBugsProducts
  24. */
  25. require_once 'Zend/Db/Table/TableBugsProducts.php';
  26. /**
  27. * @see Zend_Db_Table_Row_TestMyRow
  28. */
  29. require_once 'Zend/Db/Table/Row/TestMyRow.php';
  30. /**
  31. * @see Zend_Db_Table_Row_TestMyRowset
  32. */
  33. require_once 'Zend/Db/Table/Rowset/TestMyRowset.php';
  34. PHPUnit_Util_Filter::addFileToFilter(__FILE__);
  35. /**
  36. * @category Zend
  37. * @package Zend_Db
  38. * @subpackage UnitTests
  39. * @copyright Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
  40. * @license http://framework.zend.com/license/new-bsd New BSD License
  41. */
  42. class Zend_Db_Table_TableBugsProductsCustom extends Zend_Db_Table_TableBugsProducts
  43. {
  44. protected $_rowClass = 'Zend_Db_Table_Row_TestMyRow';
  45. protected $_rowsetClass = 'Zend_Db_Table_Rowset_TestMyRowset';
  46. protected $_referenceMap = array(
  47. 'Bug' => array(
  48. 'columns' => 'bug_id',
  49. 'refTableClass' => 'Zend_Db_Table_TableBugsCustom',
  50. 'refColumns' => 'bug_id',
  51. 'onDelete' => self::CASCADE,
  52. 'onUpdate' => self::CASCADE
  53. ),
  54. 'Product' => array(
  55. 'columns' => 'product_id',
  56. 'refTableClass' => 'Zend_Db_Table_TableProductsCustom',
  57. 'refColumns' => 'product_id',
  58. 'onDelete' => 'anything but self::CASCADE',
  59. 'onUpdate' => 'anything but self::CASCADE'
  60. )
  61. );
  62. }