aspose file tools*
The moose likes Developer Certification (SCJD/OCMJD) and the fly likes URLyBird 1.2.1 - MUST not use the network server code Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of The Java EE 7 Tutorial Volume 1 or Volume 2 this week in the Java EE forum
or jQuery UI in Action in the JavaScript forum!
JavaRanch » Java Forums » Certification » Developer Certification (SCJD/OCMJD)
Bookmark "URLyBird 1.2.1 - MUST not use the network server code" Watch "URLyBird 1.2.1 - MUST not use the network server code" New topic
Author

URLyBird 1.2.1 - MUST not use the network server code

Kiev Gama
Greenhorn

Joined: Sep 11, 2005
Posts: 6
Hi all,

I have a question about the non networked mode which says "not to use the network server code".

I'm deciding to use the following design on my server implementation:

Networked Mode:
GUI --> ServerAdapter (RemoteServerAdapter)--RMI--> RemoteRoomsServer --> RoomsDAO
Non-Networked Mode:
GUI --> ServerAdapter (LocalServerAdapter) --> RoomsDAO

There would be a factory for the ServerAdapter, which would get the correct implementation based on the mode (alone or server).

The RoomsDAO is the class that communicates with the Data class (which implements DBAccess). By using this approach, both networked and non-networked modes are using the "same code". However the second approach bypasses the network.

My question is:
Is my design compliant with the requirement below?

"The operating mode is selected using the single command line argument that is permitted. Architecturally, this mode must use the database and GUI from the networked form, but must not use the network server code at all. "

Thanks in advance,

Kiev Gama
Andrew Monkhouse
author and jackaroo
Marshal Commander

Joined: Mar 28, 2003
Posts: 11430
    
  85

Hi Kiev,

Welcome to JavaRanch and this forum.

It certainly looks like you are meeting that requirement. Was there something specific that you thought might be problematic?

Regards, Andrew


The Sun Certified Java Developer Exam with J2SE 5: paper version from Amazon, PDF from Apress, Online reference: Books 24x7 Personal blog
Kiev Gama
Greenhorn

Joined: Sep 11, 2005
Posts: 6
I was not sure of what exactly was the "network server code". I see that it is meant to be the class that implements the java.rmi.Remote interface, not the particular class that has the "server code" (RoomsDAO) that deals with the Data.

So I thought I was violating the requirement because the same "server code" is responsible for dealing with the data in the server and alone modes. However, the network stuff is only in the RemoteServerAdapter.

Thanks for your opinion!

Best Regards,

Kiev
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: URLyBird 1.2.1 - MUST not use the network server code