Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
adding models/behaviors for object persist tests
git-svn-id: https://svn.cakephp.org/repo/branches/1.2.x.x@8119 3807eeeb-6ff5-0310-8944-8be069107fe0
- Loading branch information
gwoo
committed
Mar 19, 2009
1 parent
641a483
commit 3d4c5b4
Showing
4 changed files
with
146 additions
and
0 deletions.
There are no files selected for viewing
38 changes: 38 additions & 0 deletions
38
cake/tests/test_app/models/behaviors/persister_one_behavior.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
<?php | ||
/* SVN FILE: $Id$ */ | ||
/** | ||
* Behavior for binding management. | ||
* | ||
* Behavior to simplify manipulating a model's bindings when doing a find operation | ||
* | ||
* PHP versions 4 and 5 | ||
* | ||
* CakePHP(tm) : Rapid Development Framework (http://www.cakephp.org) | ||
* Copyright 2005-2008, Cake Software Foundation, Inc. (http://www.cakefoundation.org) | ||
* | ||
* Licensed under The MIT License | ||
* Redistributions of files must retain the above copyright notice. | ||
* | ||
* @filesource | ||
* @copyright Copyright 2005-2008, Cake Software Foundation, Inc. (http://www.cakefoundation.org) | ||
* @link http://www.cakefoundation.org/projects/info/cakephp CakePHP(tm) Project | ||
* @package cake | ||
* @subpackage cake.tests.test_app.models | ||
* @since CakePHP(tm) v 1.2.0.5669 | ||
* @version $Revision$ | ||
* @modifiedby $LastChangedBy$ | ||
* @lastmodified $Date$ | ||
* @license http://www.opensource.org/licenses/mit-license.php The MIT License | ||
*/ | ||
/** | ||
* Behavior to allow for dynamic and atomic manipulation of a Model's associations used for a find call. Most useful for limiting | ||
* the amount of associations and data returned. | ||
* | ||
* @package cake | ||
* @subpackage cake.cake.console.libs | ||
*/ | ||
class PersisterOneBehaviorBehavior extends ModelBehavior { | ||
|
||
|
||
} | ||
?> |
38 changes: 38 additions & 0 deletions
38
cake/tests/test_app/models/behaviors/persister_two_behavior.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
<?php | ||
/* SVN FILE: $Id$ */ | ||
/** | ||
* Behavior for binding management. | ||
* | ||
* Behavior to simplify manipulating a model's bindings when doing a find operation | ||
* | ||
* PHP versions 4 and 5 | ||
* | ||
* CakePHP(tm) : Rapid Development Framework (http://www.cakephp.org) | ||
* Copyright 2005-2008, Cake Software Foundation, Inc. (http://www.cakefoundation.org) | ||
* | ||
* Licensed under The MIT License | ||
* Redistributions of files must retain the above copyright notice. | ||
* | ||
* @filesource | ||
* @copyright Copyright 2005-2008, Cake Software Foundation, Inc. (http://www.cakefoundation.org) | ||
* @link http://www.cakefoundation.org/projects/info/cakephp CakePHP(tm) Project | ||
* @package cake | ||
* @subpackage cake.tests.test_app.models | ||
* @since CakePHP(tm) v 1.2.0.5669 | ||
* @version $Revision$ | ||
* @modifiedby $LastChangedBy$ | ||
* @lastmodified $Date$ | ||
* @license http://www.opensource.org/licenses/mit-license.php The MIT License | ||
*/ | ||
/** | ||
* Behavior to allow for dynamic and atomic manipulation of a Model's associations used for a find call. Most useful for limiting | ||
* the amount of associations and data returned. | ||
* | ||
* @package cake | ||
* @subpackage cake.cake.console.libs | ||
*/ | ||
class PersisterTwoBehaviorBehavior extends ModelBehavior { | ||
|
||
|
||
} | ||
?> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
<?php | ||
/* SVN FILE: $Id$ */ | ||
/** | ||
* Test App Comment Model | ||
* | ||
* | ||
* | ||
* PHP versions 4 and 5 | ||
* | ||
* CakePHP : Rapid Development Framework (http://www.cakephp.org) | ||
* Copyright 2006-2008, Cake Software Foundation, Inc. | ||
* | ||
* Licensed under The MIT License | ||
* Redistributions of files must retain the above copyright notice. | ||
* | ||
* @filesource | ||
* @copyright Copyright 2006-2008, Cake Software Foundation, Inc. | ||
* @link http://www.cakefoundation.org/projects/info/cakephp CakePHP Project | ||
* @package cake | ||
* @subpackage cake.tests.test_app.models | ||
* @since CakePHP v 1.2.0.7726 | ||
* @version $Revision$ | ||
* @modifiedby $LastChangedBy$ | ||
* @lastmodified $Date$ | ||
* @license http://www.opensource.org/licenses/mit-license.php The MIT License | ||
*/ | ||
class PersisterOne extends AppModel { | ||
var $useTable = 'posts'; | ||
var $name = 'PersisterOne'; | ||
|
||
var $actsAs = array('PersisterOneBehavior'); | ||
|
||
var $hasMany = array('Comment'); | ||
} | ||
?> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
<?php | ||
/* SVN FILE: $Id$ */ | ||
/** | ||
* Test App Comment Model | ||
* | ||
* | ||
* | ||
* PHP versions 4 and 5 | ||
* | ||
* CakePHP : Rapid Development Framework (http://www.cakephp.org) | ||
* Copyright 2006-2008, Cake Software Foundation, Inc. | ||
* | ||
* Licensed under The MIT License | ||
* Redistributions of files must retain the above copyright notice. | ||
* | ||
* @filesource | ||
* @copyright Copyright 2006-2008, Cake Software Foundation, Inc. | ||
* @link http://www.cakefoundation.org/projects/info/cakephp CakePHP Project | ||
* @package cake | ||
* @subpackage cake.tests.test_app.models | ||
* @since CakePHP v 1.2.0.7726 | ||
* @version $Revision$ | ||
* @modifiedby $LastChangedBy$ | ||
* @lastmodified $Date$ | ||
* @license http://www.opensource.org/licenses/mit-license.php The MIT License | ||
*/ | ||
class PersisterTwo extends AppModel { | ||
var $useTable = 'posts'; | ||
var $name = 'PersisterTwo'; | ||
|
||
var $actsAs = array('PersisterOneBehavior'); | ||
|
||
var $hasMany = array('Comment'); | ||
} | ||
?> |