Win a copy of Java Mock Exams (software) this week in the Programmer Certification (OCPJP) forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

An Interface Design Question

fred norris
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In an all java 2 environment a remote interface may throw any super class exception in place of RemoteException.Does this design make sense then. Construct an Interface which throws Exception, And the DataBaseException. Construct an Adapter class which which handles Data access using a boolean
inNetworkMode and then implements the methods and deals with the exceptions based on this boolean. In other words it seems to me the design requested seems to mandate a client that does not care if it is "remote" or not, so I wonder about the need for a RemoteException.
Happiness is not a goal ... it's a by-product of a life well lived - Eleanor Roosevelt. Tiny ad:
the new thread boost feature: great for the advertiser and smooth for the coderanch user
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!