• Post Reply Bookmark Topic Watch Topic
  • New Topic

Any suggested naming convention?  RSS feed

 
Bupjae Lee
Ranch Hand
Posts: 107
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What is common naming convention for swing component variable?

In NetBeans, default name is like "jCheckBox1", "jTextField1".

For example, what name is acceptable for 'JEditorPane component for displaying messages in chat room'?
 
Gregg Bolinger
Ranch Hand
Posts: 15304
6
Chrome IntelliJ IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
5 people will probably give you 5 different answers. My opinion is something like:

chatPane or chatJEditorPane

I had an instructor in school once that liked the latter because you could always tell what kind of component it was without looking at the declaration.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!