站内搜索: 请输入搜索关键词
当前页面: 在线文档首页 > Spring Framework 2.0.5 API 文档英文版

DelegatingEntityResolver (Spring Framework API 2.0) - Spring Framework 2.0.5 API 文档英文版

The Spring Framework

org.springframework.beans.factory.xml
Class DelegatingEntityResolver

java.lang.Object
  extended by org.springframework.beans.factory.xml.DelegatingEntityResolver
All Implemented Interfaces:
EntityResolver
Direct Known Subclasses:
ResourceEntityResolver

public class DelegatingEntityResolver
extends Object
implements EntityResolver

EntityResolver implementation that delegates to a BeansDtdResolver and a PluggableSchemaResolver for DTDs and XML schemas, respectively.

Since:
2.0
Author:
Rob Harrop, Juergen Hoeller, Rick Evans
See Also:
BeansDtdResolver, PluggableSchemaResolver

Field Summary
static String DTD_SUFFIX
          Suffix for DTD files
static String XSD_SUFFIX
          Suffix for schema definition files
 
Constructor Summary
DelegatingEntityResolver(ClassLoader classLoader)
          Create a new DelegatingEntityResolver that delegates to a default BeansDtdResolver and a default PluggableSchemaResolver.
DelegatingEntityResolver(EntityResolver dtdResolver, EntityResolver schemaResolver)
          Create a new DelegatingEntityResolver that delegates to the given EntityResolvers.
 
Method Summary
 InputSource resolveEntity(String publicId, String systemId)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DTD_SUFFIX

public static final String DTD_SUFFIX
Suffix for DTD files

See Also:
Constant Field Values

XSD_SUFFIX

public static final String XSD_SUFFIX
Suffix for schema definition files

See Also:
Constant Field Values
Constructor Detail

DelegatingEntityResolver

public DelegatingEntityResolver(ClassLoader classLoader)
Create a new DelegatingEntityResolver that delegates to a default BeansDtdResolver and a default PluggableSchemaResolver.

Configures the PluggableSchemaResolver with the supplied ClassLoader.

Parameters:
classLoader - the ClassLoader to use for loading
Throws:
IllegalArgumentException - if the supplied class loader is null

DelegatingEntityResolver

public DelegatingEntityResolver(EntityResolver dtdResolver,
                                EntityResolver schemaResolver)
Create a new DelegatingEntityResolver that delegates to the given EntityResolvers.

Parameters:
dtdResolver - the EntityResolver to resolve DTDs with
schemaResolver - the EntityResolver to resolve XML schemas with
Throws:
IllegalArgumentException - if either of the supplied resolvers is null
Method Detail

resolveEntity

public InputSource resolveEntity(String publicId,
                                 String systemId)
                          throws SAXException,
                                 IOException
Specified by:
resolveEntity in interface EntityResolver
Throws:
SAXException
IOException

The Spring Framework

Copyright © 2002-2007 The Spring Framework.