开发者

Hungarian notation in Intellij IDEA

开发者 https://www.devze.com 2023-04-09 16:05 出处:网络
I have to do some maintenance on legacy code that uses Hungarian notation (and Sy开发者_开发百科stems Hungarian at that). Unfortunately, it\'s not practical for me to just clean it all out of the code

I have to do some maintenance on legacy code that uses Hungarian notation (and Sy开发者_开发百科stems Hungarian at that). Unfortunately, it's not practical for me to just clean it all out of the codebase.

Local Eclipse users claim that Eclipse can be configured so that auto-generated accessors and whatnot ignore the Hungarian prefixes (which is probably why they've been able to live with them for so long).

Is there any similar functionality in IDEA 10.5? It'd be nice if 'find usages' on m_sInstruction was smart enough to realize that getInstruction() is a getter, and give me the 'do you want to search for accessors?' prompt, for instance, or if 'generate getters and setters' could tell that this class already has them for almost all fields.


Settings | Code Style | Java | Code Generation, set the Name prefix for Field and Static field.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号