クラス XsdSchemaHandlerAdapter
java.lang.ObjectSE
org.springframework.xml.transform.TransformerObjectSupport
org.springframework.ws.transport.http.LocationTransformerObjectSupport
org.springframework.ws.transport.http.XsdSchemaHandlerAdapter
- 実装されたすべてのインターフェース:
org.springframework.beans.factory.InitializingBean
,org.springframework.web.servlet.HandlerAdapter
public class XsdSchemaHandlerAdapter
extends LocationTransformerObjectSupport
implements org.springframework.web.servlet.HandlerAdapter, org.springframework.beans.factory.InitializingBean
汎用
DispatcherServlet
で XsdSchema
インターフェースを使用するためのアダプター。 マップされた XsdSchema
実装からソースを読み取り、その結果として HttpServletResponse
に書き込みます。サブクラスでスキーマを後処理できます。
- 導入:
- 1.5.3
- 作成者:
- Arjen Poutsma
- 関連事項:
フィールドのサマリー
フィールドコンストラクターの概要
コンストラクターメソッドのサマリー
修飾子と型メソッド説明void
long
getLastModified
(jakarta.servlet.http.HttpServletRequest request, ObjectSE handler) protected SourceSE
getSchemaSource
(XsdSchema schema) 指定されたスキーマのSource
SE を返します。org.springframework.web.servlet.ModelAndView
handle
(jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpServletResponse response, ObjectSE handler) void
setSchemaLocationExpression
(StringSE schemaLocationExpression) WSDL 1.1 定義からschemaLocation
属性を抽出するために使用される XPath 式を設定します。void
setTransformSchemaLocations
(boolean transformSchemaLocations) 受信HttpServletRequest
のリクエスト URI を使用して WSDL 内の相対アドレススキーマの場所を変換するかどうかを設定します。boolean
protected void
transformSchemaLocations
(DocumentSE definitionDocument, jakarta.servlet.http.HttpServletRequest request) HttpServletRequest
で指定されたサーバー名を反映するように、すべてのschemaLocation
属性を変換します。クラス org.springframework.ws.transport.http.LocationTransformerObjectSupport から継承されたメソッド
transformLocation, transformLocations
クラス org.springframework.xml.transform.TransformerObjectSupport から継承されたメソッド
createTransformer, getTransformerFactory, newTransformerFactory, setTransformerFactoryClass, transform
フィールドの詳細
DEFAULT_SCHEMA_LOCATION_EXPRESSION
WSDL 定義からすべてのschemaLocation
属性を抽出するために使用されるデフォルトの XPath 式。- 関連事項:
コンストラクターの詳細
XsdSchemaHandlerAdapter
public XsdSchemaHandlerAdapter()
メソッドの詳細
setSchemaLocationExpression
WSDL 1.1 定義からschemaLocation
属性を抽出するために使用される XPath 式を設定します。デフォルトは
DEFAULT_SCHEMA_LOCATION_EXPRESSION
です。setTransformSchemaLocations
public void setTransformSchemaLocations(boolean transformSchemaLocations) 受信HttpServletRequest
のリクエスト URI を使用して WSDL 内の相対アドレススキーマの場所を変換するかどうかを設定します。デフォルトはfalse
です。getLastModified
- 次で指定:
- インターフェース
org.springframework.web.servlet.HandlerAdapter
のgetLastModified
handle
public org.springframework.web.servlet.ModelAndView handle(jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpServletResponse response, ObjectSE handler) throws ExceptionSE - 次で指定:
- インターフェース
org.springframework.web.servlet.HandlerAdapter
のhandle
- 例外:
ExceptionSE
supports
- 次で指定:
- インターフェース
org.springframework.web.servlet.HandlerAdapter
のsupports
afterPropertiesSet
- 次で指定:
- インターフェース
org.springframework.beans.factory.InitializingBean
のafterPropertiesSet
- 例外:
ExceptionSE
getSchemaSource
指定されたスキーマのSource
SE を返します。サブクラスのスキーマの後処理と変換を可能にします。デフォルトの実装は単に
XsdSchema.getSource()
を返します。- パラメーター:
schema
- スキーマ- 戻り値:
- 指定されたスキーマのソース
- 例外:
ExceptionSE
- エラーの場合
transformSchemaLocations
protected void transformSchemaLocations(DocumentSE definitionDocument, jakarta.servlet.http.HttpServletRequest request) throws ExceptionSE HttpServletRequest
で指定されたサーバー名を反映するように、すべてのschemaLocation
属性を変換します。定義された XPath 式を評価して適切な属性を決定し、transformLocation
に委譲して、一致するすべての属性の変換を実行します。このメソッドは、
transformSchemaLocations
プロパティが true の場合にのみ呼び出されます。