PDT Completion
am 25.01.2008 11:10:14 von wozozo
hello.
i'm using PDT. But, complement does not work well.
Please see the following codes.
------------------------------------------------------------ --------
class A {
public $a;
public function __construct() {
$this->a = new B();
}
}
class B {
public $b;
public function funcB() {
echo 'classB';
}
}
$obj = new A();
$obj->a->
------------------------------------------------------------ --------
after this I want to complement "" funcB() "" .
But It is not complemented even if it pushes Ctrl+Space.
" $obj->a" is complemented.
Can't this complement be performed in PDT?
Re: PDT Completion
am 25.01.2008 15:04:41 von Joe Scylla
wozozo wrote:
> hello.
>
> i'm using PDT. But, complement does not work well.
> Please see the following codes.
>
> ------------------------------------------------------------ --------
>
> class A {
> public $a;
> public function __construct() {
> $this->a = new B();
> }
> }
>
> class B {
> public $b;
>
> public function funcB() {
> echo 'classB';
> }
> }
>
> $obj = new A();
> $obj->a->
>
> ------------------------------------------------------------ --------
>
> after this I want to complement "" funcB() "" .
> But It is not complemented even if it pushes Ctrl+Space.
>
> " $obj->a" is complemented.
> Can't this complement be performed in PDT?
Yes, but only if you document your sourcecode with PHPDocumentor-Tags:
To get smarthelp for the property of your Class A you have to add
following documentation tags:
class A {
/**
* Type of class B
*
* @var B
*/
public $a;
public function __construct() {
$this->a = new B();
}
}
More infos at: http://www.phpdoc.org/
Joe