| 1 |
<?php |
| 2 |
/** |
| 3 |
* |
| 4 |
*/ |
| 5 |
|
| 6 |
/** |
| 7 |
* |
| 8 |
*/ |
| 9 |
abstract class CJT_Framework_View_Block_Parameter_Base_List |
| 10 |
extends CJT_Framework_View_Block_Parameter_Base_Abstract { |
| 11 |
|
| 12 |
/** |
| 13 |
* put your comment there... |
| 14 |
* |
| 15 |
* @param mixed $parameter |
| 16 |
* @param mixed $factory |
| 17 |
* @return CJT_Framework_Developer_Interface_Block_Shortcode_Parameters_Base_Abstract |
| 18 |
*/ |
| 19 |
public function __construct($parameter, $factory) { |
| 20 |
// Parent procedure! |
| 21 |
parent::__construct($parameter, $factory); |
| 22 |
// Set parent reference for all child parameters. |
| 23 |
foreach ($this->getParams() as $param) { |
| 24 |
$param->setParent($this); |
| 25 |
} |
| 26 |
} |
| 27 |
|
| 28 |
/** |
| 29 |
* put your comment there... |
| 30 |
* |
| 31 |
*/ |
| 32 |
public function enqueueScripts() { |
| 33 |
// @TODO: Enqueue all childs!! |
| 34 |
return array(); |
| 35 |
} |
| 36 |
|
| 37 |
/** |
| 38 |
* put your comment there... |
| 39 |
* |
| 40 |
*/ |
| 41 |
public function enqueueStyles() { |
| 42 |
// @TODO: Enqueue all childs!! |
| 43 |
return array(); |
| 44 |
} |
| 45 |
|
| 46 |
/** |
| 47 |
* put your comment there... |
| 48 |
* |
| 49 |
*/ |
| 50 |
public function getParams() { |
| 51 |
// Initialize. |
| 52 |
$params = array(); |
| 53 |
$typeObject = $this->getTypeObject(); |
| 54 |
// As the form objects might handle types that doesn't support |
| 55 |
// child parameters (Example: List type might handle Boolean type!). |
| 56 |
// We need to check the existance of the method. |
| 57 |
if (method_exists($typeObject, 'getParams')) { |
| 58 |
$params = $typeObject->getParams(); |
| 59 |
} |
| 60 |
return $params; |
| 61 |
} |
| 62 |
|
| 63 |
} // End class. |