I guess this is about RMI? You should really post in the appropriate forum where you'd likely be told to read the documentation for your RMI compiler and JDK which explains the what, why, and how in considerable detail.
I’ve looked at a lot of different solutions, and in my humble opinion Aspose is the way to go. Here’s the link: http://aspose.com
subject: how to create stub & skeleton with jdk1.5