This week's book giveaway is in the OCPJP forum.
We're giving away four copies of OCA/OCP Java SE 7 Programmer I & II Study Guide and have Kathy Sierra & Bert Bates on-line!
See this thread for details.
The moose likes Programmer Certification (SCJP/OCPJP) and the fly likes strictfp doubt Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCA/OCP Java SE 7 Programmer I & II Study Guide this week in the OCPJP forum!
JavaRanch » Java Forums » Certification » Programmer Certification (SCJP/OCPJP)
Bookmark "strictfp doubt" Watch "strictfp doubt" New topic
Author

strictfp doubt

Kaarthick Ramamoorthy
Greenhorn

Joined: Sep 01, 2006
Posts: 23
interface Perform
{
public strictfp abstract void add(double a, double b);
public strictfp abstract void sub(double a, double b);
}

why strictfp is not allowed here?.
Barry Gaunt
Ranch Hand

Joined: Aug 03, 2002
Posts: 7729
strictfp is an implementation detail, so it only allowed to be used in the classes that implement the interface. That is, you cannot force the implementor of your interface to use the strictfp feature.


Ask a Meaningful Question and HowToAskQuestionsOnJavaRanch
Getting someone to think and try something out is much more useful than just telling them the answer.
 
 
subject: strictfp doubt