Win a copy of Java 9 Modularity: Patterns and Practices for Developing Maintainable Applications this week in the Java 9 forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Unused constant  RSS feed

 
Michael Morris
Ranch Hand
Posts: 3451
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all.
There is a package-private constant that is defined in Data.java, DataInfo.java and FieldInfo.java that as far as I can tell is not used at all. Here's the definition:

My first instinct is to remove the definition altogether since I can see no apparent use for it. What are your thoughts?
Thanks
 
Mark Spritzler
ranger
Sheriff
Posts: 17309
11
IntelliJ IDE Mac Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'd just keep whatever they had doen in the code. The constant could have ben used in a previous version of the test, when you have to convert the data.
Mark
 
Michael Morris
Ranch Hand
Posts: 3451
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Mark. I have a tendecy to nit-pick others' code (and code that I wrote but can't remember when.) I will certainly leave it alone.
 
Burk Hufnagel
Ranch Hand
Posts: 839
2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Another possibillity is that it is used to tell the person marking your submission which version of the "legacy code" and db.db file you were assigned.
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!