Core Java| JSP| Servlets| XML| EJB| JEE5| Web Services| J2ME| Glossary| Questions?

 

 

 

 

 

 

 

 

 

 

 

 

 

Search Tutorials

Latest Questions
Comments
 
Java Remote Interface 
 

The Remote interface identifies interfaces whose methods may be invoked remotely from a non-local virtual machine.

 

Java Remote Interface

                         

The Remote interface identifies interfaces whose methods may be invoked remotely from a non-local virtual machine. Any remote object must directly or indirectly implement this interface. Implementation classes can implement any number of remote interfaces and can extend other remote implementation classes.

The methods specified in a "remote interface", extends java.rmi.Remote. Therefore, these methods must be defined as being capable of throwing a java.rmi.RemoteException. This exception is thrown by the RMI system from a remote method invocation to indicate that either a communication failure or a protocol error has occurred.

The Enterprise Java Bean (EJB) 2.0 specification also contains a remote client view in cases when you plan to use the bean in distributed environments.

To access a remote object, you first need to find it, which can usually be accomplished through the use of a directory or naming service, such as the RMI registry or JNDI

When you obtain a reference to a remote object through a directory service, you don't receive an actual reference to that object, but rather a reference to a stub object that implements the same interface as the remote object. The stub marshals the method parameters and converts them into a byte-stream representation. Then it sends the marshaled parameters over the network to a skeleton object, which unmarshals them and invokes the actual remote method you wanted to invoke. Then the method returns a value to the skeleton, the skeleton marshals the return value and transports it to the stub, and the stub unmarshals it and returns the value to the caller.

 

Read example at:

http:/www.roseindia.net/javabeans/sessionbeantutorial.shtml

 

                         

» View all related tutorials
Related Tags:

Leave your comment:

Name:

Email:

URL:

Title:

Comments:


Enter Code:

Audio Version
Reload Image
 

Note: Emails will not be visible or used in any way, and are not required. Please keep comments relevant. Any content deemed inappropriate or offensive may be edited and/or deleted.

No HTML code is allowed. Line breaks will be converted automatically. URLs will be auto-linked. Please use BBCode to format your text.

Add This Tutorial To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Training Courses
Tell A Friend
Your Friend Name
Software Solutions
Least Viewed
Most Rated
Recently Viewed
Search Tutorials

 

 
 

Home | JSP | EJB | JDBC | Java Servlets | WAP  | Free JSP Hosting  | Search Engine | News Archive | Jboss 3.0 tutorial | Free Linux CD's | Forum | Blogs

About Us | Advertising On RoseIndia.net  | Site Map

India News

Indian Software Development Company | iPhone Development Company in India | Flex Development Company in India | Java Training Delhi | Java Training at Noida |

Send your comments, Suggestions or Queries regarding this site at roseindia_net@yahoo.com.

Copyright © 2008. All rights reserved.