| Total Complexity | 4 |
| Total Lines | 22 |
| Duplicated Lines | 0 % |
| Changes | 2 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 5 | class Demo_getChannels extends Demo |
||
| 6 | { |
||
| 7 | public $order = 500; |
||
| 8 | |||
| 9 | protected $channels = array('red', 'green', 'blue', 'alpha'); |
||
| 10 | |||
| 11 | function init() |
||
| 12 | { |
||
| 13 | $this->addField(new CheckboxField('red', true)); |
||
| 14 | $this->addField(new CheckboxField('green', false)); |
||
| 15 | $this->addField(new CheckboxField('blue', true)); |
||
| 16 | $this->addField(new CheckboxField('alpha', false)); |
||
| 17 | } |
||
| 18 | |||
| 19 | function execute($img, $request) |
||
| 27 | } |
||
| 28 | } |
||
| 29 |
Adding explicit visibility (
private,protected, orpublic) is generally recommend to communicate to other developers how, and from where this method is intended to be used.