Hi NuSphere Team
If someone else has just been writing about it, sorry
Please look at a below lines:
$link = new mysqli('host','user','pass','database');
$link->[OK!] // here code completion works
$result = $link->query("query");
$result->[NOTHING!] // here code completion does not work
... and here nothing happens. Why when $link->query returns mysqli_result object there are no code completion for it?
Please look at a below test:
class T_mysqli_result
{
public function close()
{ }
public function fetch_array()
{ }
// ...
}
class T_mysqli
{
function __construct($h,$u,$p,$d)
{ }
public function query($q)
{ return new T_mysqli_result; }
// ...
}
$link = new T_mysqli('host','user','pass','database');
$link->[OK!]
$result = $link->query();
$result->[OK!]
... and here code completion works perfectly and shows all available methods and properties of T_mysqli_result.
And now please look at a below next small test:
$link = new mysqli('host','user','pass','database');
$result = $link->query("query");
DoSthWithResult($result);
function DoSthWithResult(mysqli_result $result)
{
$result->[OK!]
}
... and here code completion also works.
Why in the first of above examples code completion does not work for standard classes? Is possible to correct it in next nearly versions of PhpED?
Regards and Respect