This can be a little tricky to explain, so I'll give you some sample code. Please note that I am using NetBeans (latest).
class Dummy {
public function say(){ }
}
function say_something(){
return new Dummy();
}
$s=say_something();
When developing in netbeans, I can cause autocompletion by pressing Ctrl + space after entering "$ s->". The next prompt window has a say () item. This is because javadoc says say_something returns the Dummy and NetBeans Dummy parsed class to know that it has a method called "say ()".
So far so good.
My problem is with arrays. Code example:
function say_something2(){
return array(new Dummy(),new Dummy());
}
$s=say_something2();
If I try autocomplete again, but with "$ s [0] →" instead, I don't get the methods of the Dummy class. This is due to the fact that in JavaDoc I just said that it is an array, but not a value type.
, , - JavaDoc, , JavaDoc, ?