aspose file tools*
The moose likes Developer Certification (SCJD/OCMJD) and the fly likes An Age-Old Problem: Having a Remote Object implement a non-Remote interface Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Java 8 in Action this week in the Java 8 forum!
JavaRanch » Java Forums » Certification » Developer Certification (SCJD/OCMJD)
Bookmark "An Age-Old Problem: Having a Remote Object implement a non-Remote interface" Watch "An Age-Old Problem: Having a Remote Object implement a non-Remote interface" New topic
Author

An Age-Old Problem: Having a Remote Object implement a non-Remote interface

Paul Tongyoo
Ranch Hand

Joined: Sep 30, 2003
Posts: 91
Hello JavaRanchers--

I've been searching this forum for almost an hour and haven't been able to interpret any concensus on the best design solution for this problem: Having my RemoteObjectImpl (which needs to throw RemoteException) implement my Data interface (which does not need to throw RemoteException). Rancher veterans-- what has been the best approach to this problem?? Ideally, I do not want my Data interface to throw any additional exceptions since it's functions shouldn't need to.

Now FYI, this is NOT for the SCJD exam -- as an attempt to pound my SCJWCD work into my head, I'm refactoring my SCJD app so I could build a JSP/Servlet interface to the business tier in place of the original Swing front-end. So I would love to hear *any* design suggestions (not bound by Sun's specs)! I just figure I'd post my question here since many SCJD'ers may have solved this problem.

Thank you in advance!

Paul

[ May 30, 2004: Message edited by: Paul Tongyoo ]

Sun Certified Java Web Component Developer for J2EE v1.4<br />Sun Certified Java Developer for J2SE v1.4<br />Sun Certified Java Programmer for J2SE v1.4
Andrew Monkhouse
author and jackaroo
Marshal Commander

Joined: Mar 28, 2003
Posts: 11280
    
  59

Hi Paul,

I did a similar exercise when I was studying for SCWCD - try to use every single item I was studying in SCWCD in a SCJD front end. The end result was something like the Java Pet Store - a good example of every bit of the technology, but a bad example of how to write a real web application . But it served it's purpose.

But what I decided early in the exercise, was that it makes no sense to rewrite the back end, or indeed, any of the logic. I wanted to use this for SCWCD, not as a core java learning exercise.

My original application used an MVC design (well, an HMVC design, but let's not get picky ), so all I needed to do was develop logical views and controllers which connected to my existing model.

I did not go back and refactor the network interface at all - doing so would have (IMHO) distracted me from SCWCD.

Regards, Andrew


The Sun Certified Java Developer Exam with J2SE 5: paper version from Amazon, PDF from Apress, Online reference: Books 24x7 Personal blog
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: An Age-Old Problem: Having a Remote Object implement a non-Remote interface
 
Similar Threads
An Interface Design Question
Design questions (with RMI)
The RMI Data Access Conundrum
Does the client RMI object need to extend Remote?
NX: Question on Max's DVD project