• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

[URLyBird] Data interface

 
Ranch Hand
Posts: 284
Netbeans IDE Firefox Browser Debian
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello,
i have several doubts regarding the DBAccess interface that the Data class must implement. This information is included in the server section of the document.

The problem arises related to the automatic check of the requirements.
I supose this class is going to be dinamically loaded from the server VM, or it's going to be exported to be tested in a client machine.

I decided using RMI, so in the first i should decide to wrap the Data object class in another (Remote) object and then give the client other remote interface more elaborated because this interface doesn't seem to be logic, ie i think locking methods should not be public to the client.
The second case is that worries me.
If this is the remote interface, what about RemoteExceptions? And why let a client lock a record without any other consideration?

I'm not sure at all is clear what i'm asking.
Thanks jRanchers
[ December 13, 2004: Message edited by: Ignacio del Valle ]
 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Ignacio,

I think you are on right path(at least that's what I have taken.)

My Data object implements DBAccess interface. This Data object is planned to do low level work e.g. reading and writing to file.

I also have a DBClient interface for clients, whose methods throw RemoteException. The object that implements this DBClient interface wraps methods of DBAccess interface and uses the Data object.

Hope this helps.

+Lalit
 
Oricio Ocle
Ranch Hand
Posts: 284
Netbeans IDE Firefox Browser Debian
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Lalit, thanks for your reply.
I also think this is the best choice.
Regards
 
author and jackaroo
Posts: 12200
280
Mac IntelliJ IDE Firefox Browser Oracle C++ Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Ignacio,

I decided using RMI, so in the first i should decide to wrap the Data object class in another (Remote) object and then give the client other remote interface more elaborated because this interface doesn't seem to be logic, ie i think locking methods should not be public to the client.



You might be interested in reading the discussions in "Should lock methods be callable by the client". It is extremely long, but there are some good arguments both for and against what you are suggesting.

My personal opinion is that the lock cookies only make sense if the lock method is made public to the client. (As you will see though, there is the counter argument that lock cookies do not make sense in any situation ).

Regards, Andrew
 
Oricio Ocle
Ranch Hand
Posts: 284
Netbeans IDE Firefox Browser Debian
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thank you Andrew, that was just what i looking for!
Regards
 
Oricio Ocle
Ranch Hand
Posts: 284
Netbeans IDE Firefox Browser Debian
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
A very interesting thread!
Thanks again, Andrew
 
Oricio Ocle
Ranch Hand
Posts: 284
Netbeans IDE Firefox Browser Debian
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Well, i've just finished reading the previous thread, but the question goes on.
Is the election determinant for passing the automatic check phase?
I think either of them (2 tiers / 3 tiers ) - see this thread - will be accepted if this phase is passed and you have the chance to explain your design to the examiners.
So this question is for current SCJDs:
What was your election?
Regards
[ December 13, 2004: Message edited by: Ignacio del Valle ]
 
it's a teeny, tiny, wafer thin ad:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic