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

Networked and Local System

 
Aruneesh Salhotra
Ranch Hand
Posts: 167
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi
I wanted to know about the assignment, as to what is the approach to make the assignment to work over the network, and locally.
How exactly do we do it, and what is the best approach.
I plan to use RMI as then I wouldnt have the issue of socket level stuff.
Regards
Aruneesh
 
Andrew Monkhouse
author and jackaroo
Marshal Commander
Posts: 12053
232
C++ Firefox Browser IntelliJ IDE Java Mac Oracle
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Aruneesh,

One thing you might like to look at is coding to an interface. Your interface will specify what methods your client application can call and what exceptions it will throw, no matter whether you are in networked or standalone mode.

Taking that a step further, you could look at using the Factory Design Pattern to return an object that implements that interface - it is not strictly necessary, but it can tidy the code a little bit.

Regards, Andrew
 
What are you doing? You are supposed to be reading this tiny ad!
the new thread boost feature brings a LOT of attention to your favorite threads
https://coderanch.com/t/674455/Thread-Boost-feature
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!