Page 1 of 1
Generate Constructor,Getters and Setters in NetBeans PHP IDE
Posted: Sat Feb 05, 2011 6:41 am
by VladSun
I've never known it could be done in Netbeans IDE

(and it was already available in Netbeans 6.5 , 2008

)
http://netbeans.dzone.com/news/generate ... -getters-a
I was about to write a plugin for this functionaluity
How about submitting here such tips and tricks?
I often use the Code Templates (configured in Tools->Options->Editor/PHP), the fast Rename (cursor positioned on the varibale/function name and Ctrl+R pressed)
Re: Generate Constructor,Getters and Setters in NetBeans PHP
Posted: Sat Feb 05, 2011 7:20 am
by josh
Jump to matching bracket
keyboard shortcut = control + [
combine it with shift to select all code between current bracket & matching bracket.
Also highlight a project or path within a project and control f to search.
Also shift + escape hides all the docked panels and maximizes the code. control + 1 shows the projects window, control + 7 to show the navigator window again.
Re: Generate Constructor,Getters and Setters in NetBeans PHP
Posted: Sat Feb 05, 2011 7:26 am
by josh
Also this is really cool.
http://blogs.sun.com/netbeansphp/entry/type_hierarchy Couldn't get it to work though.
Re: Generate Constructor,Getters and Setters in NetBeans PHP
Posted: Sat Feb 05, 2011 7:50 am
by VladSun
Predefined palettes are also very useful

Re: Generate Constructor,Getters and Setters in NetBeans PHP
Posted: Sat Feb 05, 2011 11:16 am
by Jonah Bron
Very cool. Does anyone know if someone has made a dark gEdit Oblivion type palette?
Re: Generate Constructor,Getters and Setters in NetBeans PHP
Posted: Sat Feb 05, 2011 1:54 pm
by greyhoundcode
I dunno, but on the subject of palettes a minor gripe of mine - unless/hopefully I'm missing something - is that it doesn't seem possible to define your own colours in hex/RGB, instead you have to select from the predefined range of colours.
... Hopefully I am wrong?
Re: Generate Constructor,Getters and Setters in NetBeans PHP
Posted: Sat Feb 05, 2011 1:59 pm
by VladSun
I was talking about Code Palettes - i.e. a predefined set of code snippets to use.
No colors

Re: Generate Constructor,Getters and Setters in NetBeans PHP
Posted: Sun Feb 06, 2011 1:52 am
by greyhoundcode
VladSun wrote:I was talking about Code Palettes ... No colors

Aaahh... ! Even so, and continuing my slight

digression, I do like the darker [syntax highlighting] profiles - although I'm not completely enamoured with the supplied
Norway Today theme.
Re: Generate Constructor,Getters and Setters in NetBeans PHP
Posted: Sun Feb 06, 2011 9:36 am
by VladSun
Re: Generate Constructor,Getters and Setters in NetBeans PHP
Posted: Mon Feb 07, 2011 4:16 pm
by josh
I think you should extract new methods at that point. If you need to fold code, your methods are too long in my opinion

For me code folding is a tool for dealing with "code smells", not a tool for developing.
Re: Generate Constructor,Getters and Setters in NetBeans PHP
Posted: Mon Feb 07, 2011 4:19 pm
by VladSun
Nah, my PHP files are indeed very short. I just can't stand looking at methods like get/setVar
