NuSphere Forums Forum Index
NuSphere Forums
Reply to topic
Code completion does not recognize Exception
Veteran

Joined: 30 Nov 2006
Posts: 186
Reply with quote
I have created my own exception like this.

class myException extends Exceptions {}

but I were expecting that PHPed (version 5) would code complete Exceptions when I wrote Exep <Ctrl + Space>

But it does not.

It does not recognize the core classes ?

Is this normal PHPed behaviour, or is it my PHP that is busted.
I AM having big problems getting the TechPlatform to work with MySQL See : mysql5-and-tech-platform-5-t3315.html so I might have messed something up in the configurations.
View user's profileFind all posts by hgrSend private message
Veteran

Joined: 30 Nov 2006
Posts: 186
Reply with quote
And it does not recognize the Reflection classes.

ReflectionClass:: gives you an error.

Code completion is not available due to the following error(s):
Failed to find class of "" member, (declared as "ReflectionClass")

ReflectionClass is a core php class too.
View user's profileFind all posts by hgrSend private message
Site Admin

Joined: 13 Jul 2003
Posts: 8344
Reply with quote
Please have a look at this post: http://forum.nusphere.com/code-completion-for-php-spl-dom-pdo-and-dom-t1733.html
this way you can add support for any embedded classes, functions, variables, constants and so forth, that comes with either standard php extensions or with custom ones.

_________________
The PHP IDE team
View user's profileFind all posts by dmitriSend private messageVisit poster's website
Veteran

Joined: 30 Nov 2006
Posts: 186
Reply with quote
Ok so you actually have to add a source file with spl.php to get it to recognize the build in structure.

Does such a source file exist for PHP 5.2.1 ?
View user's profileFind all posts by hgrSend private message
Site Admin

Joined: 13 Jul 2003
Posts: 8344
Reply with quote
if you mean Exception class, it's short.
if you mean complete list, it's very big.

_________________
The PHP IDE team
View user's profileFind all posts by dmitriSend private messageVisit poster's website
Veteran

Joined: 30 Nov 2006
Posts: 186
Reply with quote
dmitri wrote:
if you mean Exception class, it's short.
if you mean complete list, it's very big.


Well if spl.php is a sourcefile that you need to include in your project in order for PHPed to lookup the core features of PHP5, then that file in the forum, is a little old. It is for version 5.1 from back in 2005..

The only purpose is to get autocompletion to help you writing your code. So it is not only for the Exception class, but for all classes that are part of the core PHP 5.2.1
View user's profileFind all posts by hgrSend private message
Site Admin

Joined: 13 Jul 2003
Posts: 8344
Reply with quote
you don't need to include this into the project. Just point to that directory in Code Insight Includes list (see project properties). Regarding the rest, that's it.

_________________
The PHP IDE team
View user's profileFind all posts by dmitriSend private messageVisit poster's website
Veteran

Joined: 30 Nov 2006
Posts: 186
Reply with quote
Yes it works for Exception.

But it does not include the Reflection classes, of PHP 5.2
View user's profileFind all posts by hgrSend private message
Code completion does not recognize Exception
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
All times are GMT - 5 Hours  
Page 1 of 1  

  
  
 Reply to topic