• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Challenges to refactor java program

 
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator


Problem with a java project refactoring
a)Code, Test, Evaluate and Refactor your own original Java program:

Write your Java code that implements your Phase 1 specifications. Document by adding Javadoc (/**...*/) and regular (//) comments that describe your resulting code. Debug (fix) your code when you discover incorrect behavior that doesn't match the specifications. Create unit tests using JUnit in JUnit. Evaluate your code and refactor to improve its internal structure.

b) Modify, Test, Evaluate and Refactor another Java program:

Write your Java code that implements your Phase 1 specifications. Document by adding

c) Research and Development:



i
 
author & internet detective
Posts: 41860
908
Eclipse IDE VI Editor Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
This looks like homework. What specifically are you stuck on?
 
Sheriff
Posts: 17644
300
Mac Android IntelliJ IDE Eclipse IDE Spring Debian Java Ubuntu Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Your Uno.main() method is over 150 lines of code long! That's at least 10 times longer than it should be. You definitely need to refactor that. If you can't succinctly but completely describe what a method does in one or two sentences, then that method is doing too much.  You main() method is doing WAAAY too much.
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic