Win a copy of Programmer's Guide to Java SE 8 Oracle Certified Associate (OCA) this week in the OCAJP forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

spec gotcha

 
Rishi Yagnik
Ranch Hand
Posts: 84
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
SRV.2.1.3 Conditional GET Support
Hey Specs says that HttpServlet interface defines getLastModified() method to support conditional get support....
don't u think that specs seems to be misleading .......
API CLearly says HttpServlet is a Class not a interface don't u all think that such mistake should not have been done by sun.....
Rishi
 
Peter den Haan
author
Ranch Hand
Posts: 3252
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The word "interface" has more than one meaning. In the narrow sense, it means a Java interface. In the broad sense, it indicates the (public) API with which an object or module interfaces to the outside world, such as the public methods of a class; in this sense, you can even use the word "interface" with programming languages such as C++ that have only classes.
You could perhaps argue that the specification should have stuck with the narrow definition of "interface" for clarity's sake.
- Peter
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic