org.springframework.beans.factory.xml

## 类 ResourceEntityResolver

- java.lang.Object
- - org.springframework.beans.factory.xml.DelegatingEntityResolver
  - - org.springframework.beans.factory.xml.ResourceEntityResolver

- 所有已实现的接口:
    EntityResolver

      public class ResourceEntityResolver
      extends DelegatingEntityResolver

  `EntityResolver` implementation that tries to resolve entity references through a `ResourceLoader` (usually, relative to the resource base of an `ApplicationContext`), if applicable. Extends `DelegatingEntityResolver` to also provide DTD and XSD lookup.

  Allows to use standard XML entities to include XML snippets into an application context definition, for example to split a large XML file into various modules. The include paths can be relative to the application context's resource base as usual, instead of relative to the JVM working directory (the XML parser's default).

  Note: In addition to relative paths, every URL that specifies a file in the current system root, i.e. the JVM working directory, will be interpreted relative to the application context too.

  从以下版本开始:
    31.07.2003
  作者:
    Juergen Hoeller
  另请参阅:
    `ResourceLoader`, `org.springframework.context.ApplicationContext`

- - ### 字段概要

    - ### 从类继承的字段 org.springframework.beans.factory.xml.DelegatingEntityResolver

      `DTD_SUFFIX, XSD_SUFFIX`

  - ### 构造器概要

    构造器
    构造器和说明
    `ResourceEntityResolver(org.springframework.core.io.ResourceLoader resourceLoader)` Create a ResourceEntityResolver for the specified ResourceLoader (usually, an ApplicationContext).

  - ### 方法概要

    所有方法 实例方法 具体方法
    限定符和类型 | 方法和说明
    --- | ---
    `InputSource` | `resolveEntity(String publicId, String systemId)`

    - ### 从类继承的方法 org.springframework.beans.factory.xml.DelegatingEntityResolver

      `toString`

    - ### 从类继承的方法 java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- - ### 构造器详细资料

    - #### ResourceEntityResolver

          public ResourceEntityResolver(org.springframework.core.io.ResourceLoader resourceLoader)

      Create a ResourceEntityResolver for the specified ResourceLoader (usually, an ApplicationContext).
      参数:
        `resourceLoader` - the ResourceLoader (or ApplicationContext) to load XML entity includes with

  - ### 方法详细资料

    - #### resolveEntity

          @Nullable
          public InputSource resolveEntity(@Nullable
                                                      String publicId,
                                                      @Nullable
                                                      String systemId)
                                               throws SAXException,
                                                      IOException

      指定者:
        `resolveEntity` 在接口中 `EntityResolver`
      覆盖:
        `resolveEntity` 在类中 `DelegatingEntityResolver`
      抛出:
        `SAXException`
        `IOException`