@@ 3-35 (lines=33) @@ | ||
1 | <?php |
|
2 | ||
3 | class SimpleClass { |
|
4 | ||
5 | const CONSTANT_VARIABLE = "test"; |
|
6 | ||
7 | static $staticProperty = "test"; |
|
8 | ||
9 | private $_privateProperty; |
|
10 | protected $_protectedProperty; |
|
11 | public $publicProperty; |
|
12 | ||
13 | private function _privateMethod() { |
|
14 | $localVar = "test"; |
|
15 | $this->_privateProperty = $localVar; |
|
16 | $this->_protectedProperty = $localVar; |
|
17 | $this->publicProperty = $localVar; |
|
18 | } |
|
19 | ||
20 | protected function _protectedMethod() { |
|
21 | $localVar = "test"; |
|
22 | $this->_privateProperty = $localVar; |
|
23 | $this->_protectedProperty = $localVar; |
|
24 | $this->publicProperty = $localVar; |
|
25 | } |
|
26 | ||
27 | public function publicMethod() { |
|
28 | $localVar = "test"; |
|
29 | $this->_privateProperty = $localVar; |
|
30 | $this->_protectedProperty = $localVar; |
|
31 | $this->publicProperty = $localVar; |
|
32 | $this->_protectedMethod(); |
|
33 | $this->_privateMethod(); |
|
34 | } |
|
35 | } |
|
36 | ||
37 | $simpleObject = new SimpleClass(); |
|
38 | $simpleObject->publicMethod(); |
@@ 2-2 (lines=1) @@ | ||
1 | <?php |
|
2 | class SimpleClass { const CONSTANT_VARIABLE = 'test'; static $staticProperty = 'test'; private $sp8839d9; protected $_protectedProperty; public $publicProperty; private function sp51fa3f() { $spd8dce8 = 'test'; $this->sp8839d9 = $spd8dce8; $this->_protectedProperty = $spd8dce8; $this->publicProperty = $spd8dce8; } protected function _protectedMethod() { $spd8dce8 = 'test'; $this->sp8839d9 = $spd8dce8; $this->_protectedProperty = $spd8dce8; $this->publicProperty = $spd8dce8; } public function publicMethod() { $spd8dce8 = 'test'; $this->sp8839d9 = $spd8dce8; $this->_protectedProperty = $spd8dce8; $this->publicProperty = $spd8dce8; $this->_protectedMethod(); $this->sp51fa3f(); } } $sp5de0e2 = new SimpleClass(); $sp5de0e2->publicMethod(); |