Package org.apache.axis.providers.java
Class JavaProvider
java.lang.Object
org.apache.axis.handlers.BasicHandler
org.apache.axis.providers.BasicProvider
org.apache.axis.providers.java.JavaProvider
- All Implemented Interfaces:
Serializable
,Handler
- Direct Known Subclasses:
MsgProvider
,RPCProvider
Base class for Java dispatching. Fetches various fields out of envelope,
looks up service object (possibly using session state), and delegates
envelope body processing to subclass via abstract processMessage method.
- Author:
- Doug Davis (dug@us.ibm.com), Carl Woolf (cwoolf@macromedia.com)
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected static org.apache.commons.logging.Log
protected static org.apache.commons.logging.Log
static final String
static final String
static final String
Fields inherited from class org.apache.axis.providers.BasicProvider
OPTION_EXTRACLASSES, OPTION_WSDL_INPUTSCHEMA, OPTION_WSDL_PORTTYPE, OPTION_WSDL_SERVICEELEMENT, OPTION_WSDL_SERVICEPORT, OPTION_WSDL_SOAPACTION_MODE, OPTION_WSDL_TARGETNAMESPACE
Fields inherited from class org.apache.axis.handlers.BasicHandler
makeLockable, name, options
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected Class
getServiceClass
(String clsName, SOAPService service, MessageContext msgContext) Returns the Class info about the service class.protected String
getServiceClassName
(Handler service) Return the class name of the serviceprotected String
Return the option in the configuration that contains the service class namegetServiceObject
(MessageContext msgContext, Handler service, String clsName, IntHolder scopeHolder) Get the service object whose method actually provides the service.void
initServiceDesc
(SOAPService service, MessageContext msgContext) Fill in a service description with the correct impl class and typemapping set.void
invoke
(MessageContext msgContext) Invoke the message by obtaining various common fields, looking up the service object (via getServiceObject), and actually processing the message (via processMessage).protected Object
makeNewServiceObject
(MessageContext msgContext, String clsName) Default java service object comes from simply instantiating the class wrapped in jcabstract void
processMessage
(MessageContext msgContext, SOAPEnvelope reqEnv, SOAPEnvelope resEnv, Object obj) Process the current message.Methods inherited from class org.apache.axis.providers.BasicProvider
addOperation, generateWSDL, getOperationName, getOperationNames, getOperationQNames
Methods inherited from class org.apache.axis.handlers.BasicHandler
canHandleBlock, cleanup, getDeploymentData, getName, getOption, getOptions, getUnderstoodHeaders, init, initHashtable, onFault, setName, setOption, setOptionDefault, setOptions, setOptionsLockable
-
Field Details
-
log
protected static org.apache.commons.logging.Log log -
entLog
protected static org.apache.commons.logging.Log entLog -
OPTION_CLASSNAME
- See Also:
-
OPTION_ALLOWEDMETHODS
- See Also:
-
OPTION_SCOPE
- See Also:
-
-
Constructor Details
-
JavaProvider
public JavaProvider()
-
-
Method Details
-
getServiceObject
public Object getServiceObject(MessageContext msgContext, Handler service, String clsName, IntHolder scopeHolder) throws Exception Get the service object whose method actually provides the service. May look up in session table.- Throws:
Exception
-
processMessage
public abstract void processMessage(MessageContext msgContext, SOAPEnvelope reqEnv, SOAPEnvelope resEnv, Object obj) throws Exception Process the current message. Side-effect resEnv to create return value.- Parameters:
msgContext
- self-explanatoryreqEnv
- the request enveloperesEnv
- the response envelopeobj
- the service object itself- Throws:
Exception
-
invoke
Invoke the message by obtaining various common fields, looking up the service object (via getServiceObject), and actually processing the message (via processMessage).- Parameters:
msgContext
- theMessageContext
to process with thisHandler
.- Throws:
AxisFault
- if the handler encounters an error
-
makeNewServiceObject
Default java service object comes from simply instantiating the class wrapped in jc- Throws:
Exception
-
getServiceClassName
Return the class name of the service -
getServiceClassNameOptionName
Return the option in the configuration that contains the service class name -
getServiceClass
protected Class getServiceClass(String clsName, SOAPService service, MessageContext msgContext) throws AxisFault Returns the Class info about the service class.- Throws:
AxisFault
-
initServiceDesc
Fill in a service description with the correct impl class and typemapping set. This uses methods that can be overridden by other providers (like the EJBProvider) to get the class from the right place.- Specified by:
initServiceDesc
in classBasicProvider
- Throws:
AxisFault
-