Hi Chirag,
Welcome to JavaRanch and this forum.
I deleted your earlier post, as it appears that this post contains everything that was in the other post and more. If I am wrong, and you want the other post put back, just say so.
If you ever want to edit a post you created, you can click on the
icon that is above
your post (there is one for each post in a topic - but you can only edit your own posts).
You do not need to worry about serialization happening behind the scenes with any of the classes you call. All you need to worry about is if
you implicitly serialize some data.
But in case you are still concerned: RMI does not automatically serialize a class that extends UnicastRemoteObject - you would still have to tell RMI that the class can be serialized (by implementing the Serializable interface).
Regards, Andrew