FileDocCategorySizeDatePackage
RMIProvider.javaAPI DocApache Axis 1.43260Sat Apr 22 18:57:28 BST 2006org.apache.axis.providers.java

RMIProvider

public class RMIProvider extends RPCProvider
A basic RMI Provider
author
Davanum Srinivas (dims@yahoo.com)

Fields Summary
protected static Log
log
protected static Log
entLog
public static final String
OPTION_NAMING_LOOKUP
public static final String
OPTION_INTERFACE_CLASSNAME
Constructors Summary
Methods Summary
protected java.lang.StringgetServiceClassNameOptionName()
Return the option in the configuration that contains the service class name.

        return OPTION_INTERFACE_CLASSNAME;
    
protected java.lang.StringgetStrOption(java.lang.String optionName, org.apache.axis.Handler service)
Get a String option by looking first in the service options, and then at the Handler's options. This allows defaults to be specified at the provider level, and then overriden for particular services.

param
optionName the option to retrieve
return
String the value of the option or null if not found in either scope

        String value = null;
        if (service != null)
            value = (String) service.getOption(optionName);
        if (value == null)
            value = (String) getOption(optionName);
        return value;
    
protected java.lang.ObjectmakeNewServiceObject(org.apache.axis.MessageContext msgContext, java.lang.String clsName)
Return a object which implements the service.

param
msgContext the message context
param
clsName The JNDI name of the EJB home class
return
an object that implements the service


                                       
       
                                           
              
        // Read deployment descriptor options
        String namingLookup = getStrOption(OPTION_NAMING_LOOKUP, msgContext.getService());
        if (System.getSecurityManager() == null) {
            System.setSecurityManager(new RMISecurityManager());
        }
        Object targetObject = Naming.lookup(namingLookup);
        return targetObject;