Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Agile forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Rules Question

 
Mike Cunningham
Ranch Hand
Posts: 130
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The following code will not compile. I suspect it's because we can't have nested/inner methods? But I'm not sure.....let me know your thoughts.

 
Valentin Crettaz
Gold Digger
Sheriff
Posts: 7610
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
that's right nested methods are not allowed.
What does the compilation says ???
HIH

------------------
Valentin Crettaz
Sun Certified Programmer for Java 2 Platform
 
Mike Cunningham
Ranch Hand
Posts: 130
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The compiler output is expecting a ";" right after "getFieldSeven".
So, basically it says, "Don't you want to declare a variable? That's what I thought! So, pick up your book, Mike, and learn JAVA so you can get certified!!!"
 
Valentin Crettaz
Gold Digger
Sheriff
Posts: 7610
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You got it Mike.
Keep it up
------------------
Valentin Crettaz
Sun Certified Programmer for Java 2 Platform
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic