|
Spring Web Services Framework | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.springframework.xml.transform.TransformerObjectSupport org.springframework.ws.transport.http.LocationTransformerObjectSupport org.springframework.ws.transport.http.XsdSchemaHandlerAdapter
public class XsdSchemaHandlerAdapter
Adapter to use the XsdSchema
interface with the generic DispatcherServlet
.
XsdSchema
implementation, and writes that as the result to the
HttpServletResponse
. Allows for post-processing the schema in subclasses.
XsdSchema
,
getSchemaSource(XsdSchema)
Field Summary | |
---|---|
static String |
DEFAULT_SCHEMA_LOCATION_EXPRESSION
Default XPath expression used for extracting all schemaLocation attributes from the WSDL definition. |
Constructor Summary | |
---|---|
XsdSchemaHandlerAdapter()
|
Method Summary | |
---|---|
void |
afterPropertiesSet()
|
long |
getLastModified(HttpServletRequest request,
Object handler)
|
protected Source |
getSchemaSource(XsdSchema schema)
Returns the Source of the given schema. |
ModelAndView |
handle(HttpServletRequest request,
HttpServletResponse response,
Object handler)
|
void |
setSchemaLocationExpression(String schemaLocationExpression)
Sets the XPath expression used for extracting the schemaLocation attributes from the WSDL 1.1 definition. |
void |
setTransformSchemaLocations(boolean transformSchemaLocations)
Sets whether relative address schema locations in the WSDL are to be transformed using the request URI of the incoming HttpServletRequest . |
boolean |
supports(Object handler)
|
protected void |
transformSchemaLocations(Document definitionDocument,
HttpServletRequest request)
Transforms all schemaLocation attributes to reflect the server name given HttpServletRequest . |
Methods inherited from class org.springframework.ws.transport.http.LocationTransformerObjectSupport |
---|
transformLocation, transformLocations |
Methods inherited from class org.springframework.xml.transform.TransformerObjectSupport |
---|
createTransformer, getTransformerFactory, newTransformerFactory, setTransformerFactoryClass, transform |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final String DEFAULT_SCHEMA_LOCATION_EXPRESSION
schemaLocation
attributes from the WSDL definition.
Constructor Detail |
---|
public XsdSchemaHandlerAdapter()
Method Detail |
---|
public void setSchemaLocationExpression(String schemaLocationExpression)
schemaLocation
attributes from the WSDL 1.1 definition.
Defaults to DEFAULT_SCHEMA_LOCATION_EXPRESSION
.
public void setTransformSchemaLocations(boolean transformSchemaLocations)
HttpServletRequest
. Defaults to false
.
public long getLastModified(HttpServletRequest request, Object handler)
getLastModified
in interface HandlerAdapter
public ModelAndView handle(HttpServletRequest request, HttpServletResponse response, Object handler) throws Exception
handle
in interface HandlerAdapter
Exception
public boolean supports(Object handler)
supports
in interface HandlerAdapter
public void afterPropertiesSet() throws Exception
afterPropertiesSet
in interface InitializingBean
Exception
protected Source getSchemaSource(XsdSchema schema) throws Exception
Source
of the given schema. Allows for post-processing and transformation of the schema in
sub-classes.
Default implementation simply returns XsdSchema.getSource()
.
schema
- the schema
Exception
- in case of errorsprotected void transformSchemaLocations(Document definitionDocument, HttpServletRequest request) throws Exception
schemaLocation
attributes to reflect the server name given HttpServletRequest
.
Determines the suitable attributes by evaluating the defined XPath expression, and delegates to transformLocation
to do the transformation for all attributes that match.
This method is only called when the transformSchemaLocations
property is true.
Exception
setSchemaLocationExpression(String)
,
LocationTransformerObjectSupport.transformLocation(String, javax.servlet.http.HttpServletRequest)
|
Spring Web Services Framework | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |