2015-03-02 11:33:41 +01:00
|
|
|
Class
|
|
|
|
-----
|
|
|
|
<?php
|
|
|
|
|
2016-02-20 18:55:48 +01:00
|
|
|
class Foo extends Bar implements ABC, \DEF, namespace\GHI
|
2015-03-02 11:33:41 +01:00
|
|
|
{
|
|
|
|
var $a = 'foo';
|
|
|
|
private $b = 'bar';
|
|
|
|
static $c = 'baz';
|
|
|
|
function test()
|
|
|
|
{
|
|
|
|
$this->a = 'bar';
|
|
|
|
echo 'test';
|
|
|
|
}
|
|
|
|
|
|
|
|
protected function baz() {}
|
|
|
|
public function foo() {}
|
|
|
|
abstract static function bar() {}
|
|
|
|
}
|
2016-02-20 18:55:48 +01:00
|
|
|
|
|
|
|
trait Bar
|
|
|
|
{
|
|
|
|
function test()
|
|
|
|
{
|
|
|
|
}
|
|
|
|
}
|
2015-03-02 11:33:41 +01:00
|
|
|
-----
|
2016-02-20 18:55:48 +01:00
|
|
|
class Foo extends Bar implements ABC, \DEF, namespace\GHI
|
2015-03-02 11:33:41 +01:00
|
|
|
{
|
|
|
|
var $a = 'foo';
|
|
|
|
private $b = 'bar';
|
|
|
|
static $c = 'baz';
|
|
|
|
function test()
|
|
|
|
{
|
|
|
|
$this->a = 'bar';
|
|
|
|
echo 'test';
|
|
|
|
}
|
|
|
|
protected function baz()
|
|
|
|
{
|
|
|
|
}
|
|
|
|
public function foo()
|
|
|
|
{
|
|
|
|
}
|
|
|
|
static abstract function bar()
|
|
|
|
{
|
|
|
|
}
|
2016-02-20 18:55:48 +01:00
|
|
|
}
|
|
|
|
trait Bar
|
|
|
|
{
|
|
|
|
function test()
|
|
|
|
{
|
|
|
|
}
|
2015-03-02 11:33:41 +01:00
|
|
|
}
|