I have been wondering for a while about the supplied database interface DB.java that comes with the assignment. My instructions say "Your data access class must be called 'Data.java', must be in a package called "suncertify.db", and must implement the following interface DB.java". It says nothing more about it.
Nowhere else in the instructions does it mention anyhting about the supplied source code.
What I am wondering is if I am allowed to modify this interface by adding on RemoteException's to each method signatures so it can be used with RMI.
The 'Programmer & Developer for Java 2 Study Guide' book by Kathy Sierra and Bert Bates says you can modify and add new methods, also the 'Java 2 Developer Exam Cram 2' book my Alain Trottier. But I heard from a lot of people that you must not or you will fail.
The exam instructions are none specific on the matter. I am looking for clarification. I hope someone out there knows the facts.
Originally posted by Jarvis Ragona: What I am wondering is if I am allowed to modify this interface by adding on RemoteException's to each method signatures so it can be used with RMI.
Jarvis, It may be risky to change the definitions of SUN's interface or its classes. Some of our ranchers here believe that there is an automated software checks program used by the examiners. If the definitions do not match, then it could directly result in an automatic failure and the examiner wouldn't bother looking at the code/reasons.
We have an obvious issue with the RemoteExceptions missing in the SUN's interface to support RMI in this assignment but there are ways to overcome it. For example: the classic Adapter pattern! Do read about this pattern and you may get some ideas...