What is UniCastRemoteObject and what is its use in RMI?

Answer Posted / vatsal doshi

There are many purposes for using a Unicast Remote Object

1. All the basic functionalities of RMI are actualy
implemented in this class. When we extend this class, in our
Remote class, all the RMI code gets inherited and becomes
available in our class

2. UnicastRemoteObject also implements Serializable
interface. So your subclass also automatically implements
Serializable. And thus marshalling is then supported for
your type

3. UnicastRemoteObject also prevents the methods of Object
class from being directly inheritted into the Remote class.
Thereby, preventing the 11 methods of Object class from
being invoked Remotely. methods like hashcode() need
different implementations for Remote invocations.

Is This Answer Correct ?    23 Yes 5 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Why won’t the jvm terminate when I close all the application windows?

756


What does module-relative mean?

581


What is metaspace?

552


What is the difference between ear, jar and war file?

576


What is the difference between session and entity beans?

583






What is synchronization and why is it important?

548


What must a class do to implement an interface?

588


what is handle?

1857


What is clustering? What are the different algorithms used for clustering?

584


Why are component architectures useful?

575


What is the argument type of a programs main() method?

567


What do you know about seam?

602


What are transaction attributes?

616


What are the different types of exception?

574


How to pass parameters in RMI?

1693