Generate getters/setters for protected property?

I link the feature to generate getters/setters but it looks like the only way for this feature to work is to declare a property private
If I declare a property protected and then click Ctrl+Insert to bring up the Generate menu, then clickin on Getters and Setters just prints an error
"no private fields to generate both getters and setters for"

I think this is a mistake because it's perfectly fine to have properties declared 'protected' and still use getters and setters for them.

I personally almost never declare method and properties as 'private', instead always using 'protected' modifier.

What do you think? Should this be considered a bug?

3 comments
Comment actions Permalink

works fine for me...

0
Comment actions Permalink

Hi Dmitri,

Please provide some standalone small code example where it does not work (e.g. file or two in empty project).

0
Comment actions Permalink

It works now. I think it did not work before because I already had all getters and setters defined.

0

Please sign in to leave a comment.