Building AIR Applications with the NetBeans PHP IDE
A user of the NetBeans PHP IDE published a tutorial on how to setup a project for developing rich AJAX/HTML Desktop Applications using NetBeans and Adobe AIR SDK.
Recent PostsPromo Video about NetBeans 6.8 Small Experiment about File Path in the Editor Tab Select edited file in Project view, Files view or Favourite view Planning features for NetBeans next ... Continuation II Planning features for NetBeans next ... Continuation I Planning features for NetBeans next International PHP Conference 2009 PHP Namespace Support Screencast Download NetBeans IDE 6.8 Milestone 2 Flickr Slideshow with NetBeans IDE 6.5 Screencast: Declaring Variables in Comment and Code Completion for Constructors and SQL Queries RSS Feeds |
Building AIR Applications with the NetBeans PHP IDE
Posted by Petr Pisl
on Aug 07 2008, 11:29:35 AM CEST
A user of the NetBeans PHP IDE published a tutorial on how to setup a project for developing rich AJAX/HTML Desktop Applications using NetBeans and Adobe AIR SDK.
Trackback URL: http://blogs.sun.com/netbeansphp/entry/building_air_applications_with_the
Post a Comment: |
Thanx a lot.
Please write a tutorial on using netbeans-php for developing projects based on cakephp or zend framework. It will be of immense help.
Is it possible for NB to offer code completion for cakephp in built classes and functions?
Posted by Kiran on August 08, 2008 at 11:13 AM CEST #
I've got another question, if I compile my own php module written in C - can I somehow use header file to get code completion for my custom functions in NetBeans? It would be a great feature...
Cheers!
Posted by Azrael Valedhel on August 08, 2008 at 12:32 PM CEST #
Hi Kiran,
I haven't time to look at cake php in deep. I have tried only small tutorials so far. I expect that there will be tutorial how to set up NB in such case soon.
Regarding code completion for cakephp in built classes and functions. These are defined in PHP files (not in binary libraries) what I saw. So if I'm right and you don't have these files in your sources, then you can add the folder with these files into project Iclude path (Project Properties -> Include Path). Then cc will work.
Let me know, whether it helps you.
Thanks,
Petr
Posted by Petr on August 08, 2008 at 01:24 PM CEST #
Hi Azrael,
we don't support code completion from c header files. Can you send me example of such header file?
The solution it would be to have a php signature file for your module and this signature file you can put on the project or global Include (in the IDE) path as I mentioned in my comment above. You can write this signature file by hand, or generate though a script.
We have a php script which finds out all php registered modules and generate signature files for these modules. This script is bigger, because it also put PHP doc into signature files.
I think writing php file, which will translate a header file to the php signature file should be simple. Probably it can be a part of NB as well.
Let me know, what you think or whether I can help you.
Thanks,
Petr
Posted by Petr on August 08, 2008 at 01:39 PM CEST #
I just thought about adding /** */ phpdoc-style blocks that would be parsed to add parameters and other info (since the "prototypes" are not exactly what we see normally).
This is an example header file for building php module:
http://pastebin.com/m2dda9e4f
Now, to add some info besides cc of function name:
http://pastebin.com/m24f053d9
...OR we could parse .C file, and that would be even better:
http://pastebin.com/m23e40db
We could get the args, the exact types, the return type and if there are optional parameters - we would know it.
These files are based on basic "hello world" module:
http://devzone.zend.com/node/view/id/1021
Given some time I would probably do something like it myself, but I'm kind of out of time lately... And it would be a nice feature I think - for module developers at least, but not only.
Posted by Azrael Valedhel on August 08, 2008 at 02:36 PM CEST #
So the signature file for the mentioned example should look like:
<?php
/**
* Funkcja zwracająca opis modułu
* @return true
*/
function astro_About () {}
/**
* astro_Resonance - oblicza rezonans dwoch planet
* @param double $x
* @param double $orb
* @return double 0..1
*/
function astro_Resonance ($x, $orb) {}
?>
Is this OK? I have written this by hand. Writing a java file or php file, which will do it, shouldn't be hard.
How do you generate the PHP documentation for your library?
Thanks,
Petr
Posted by Petr on August 08, 2008 at 03:08 PM CEST #
Yes Petr, it's "@return true" there, I just copied it from my files and that would be the old ver. with returning void (null), and I'm still at the very beginning of making this. I think I changed returning value from null to true while writing that comment ;)
I generally use phpdoc for php and will use phpdoc for php modules, as it is supported by NB and can be nicely exported.
Posted by Azrael Valedhel on August 08, 2008 at 03:45 PM CEST #