Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

RMI - How do i use the interface DB provided by sun

 
Derick Potgieter
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi, I`m done with my whole program for a local database side. I wrote
the program so that is uses a proxy class that will return or a local instance of the database or a remote instance via RMI.

The code should all be right. but..

The interface provided by sun does`nt throw RemoteException, so i cant use it in my DBImpl class.



DB is the interface class provided. this is the best solution i could come up with, but now in my DBImpl class i cant throw RemoteException on the methods i have to implement.

Does anyone have any ideas or is there another approuch to this??

Thanks a mil!!
Derick
 
Phil Harron
Greenhorn
Posts: 29
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Derik,

There are a lot of threads already on this subject. One idea seems to be creating a new interface, with exactly matches the methods in DBMain interface provided by Sun, and changing the method signatures to throw IO/Remote Exception. have a look here -here
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic