File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
Win a copy of Clojure in Action this week in the Clojure forum!
    Bookmark Topic Watch Topic
  • New Topic

Runtime and Compiletime

 
John Paterson
Ranch Hand
Posts: 171
  • 0
  • Mark post as helpful
  • send pies
  • Report post to moderator
Hi folks...

Do have a look at the following code:



Is it true that at comple time it's checked if the 'eat' method exists in the Animal class and at runtime Java selects the actual version of the method that is to be run, which in this case for object ref b it would have to be the eat method of the 'Horse' class??

 
Jaikiran Pai
Marshal
Pie
Posts: 10444
227
IntelliJ IDE Ubuntu
  • 0
  • Mark post as helpful
  • send pies
  • Report post to moderator
Please continue the discussion in your duplicate thread here http://www.coderanch.com/t/584125/java-programmer-SCJP/certification/run-time-compile-time
 
Don't get me started about those stupid light bulbs.
    Bookmark Topic Watch Topic
  • New Topic