org.springframework.util.xml

## 类 TransformerUtils

- java.lang.Object
- - org.springframework.util.xml.TransformerUtils

-     public abstract class TransformerUtils
      extends Object

  Contains common behavior relating to `Transformers` and the `javax.xml.transform` package in general.
  从以下版本开始:
    2.5.5
  作者:
    Rick Evans, Juergen Hoeller

- - ### 字段概要

    字段
    限定符和类型 | 字段和说明
    --- | ---
    `static int` | `DEFAULT_INDENT_AMOUNT` The indent amount of characters if `indenting is enabled`.

  - ### 构造器概要

    构造器
    构造器和说明
    `TransformerUtils()`

  - ### 方法概要

    所有方法 静态方法 具体方法
    限定符和类型 | 方法和说明
    --- | ---
    `static void` | `disableIndenting(Transformer transformer)` Disable indenting for the supplied `Transformer`.
    `static void` | `enableIndenting(Transformer transformer)` Enable indenting for the supplied `Transformer`.
    `static void` | `enableIndenting(Transformer transformer, int indentAmount)` Enable indenting for the supplied `Transformer`.

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

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

- - ### 字段详细资料

    - #### DEFAULT_INDENT_AMOUNT

          public static final int DEFAULT_INDENT_AMOUNT

      The indent amount of characters if `indenting is enabled`.

      Defaults to "2".

      另请参阅:
        常量字段值

  - ### 构造器详细资料

    - #### TransformerUtils

          public TransformerUtils()

  - ### 方法详细资料

    - #### enableIndenting

          public static void enableIndenting(Transformer transformer)

      Enable indenting for the supplied `Transformer`.

      If the underlying XSLT engine is Xalan, then the special output key `indent-amount` will be also be set to a value of `DEFAULT_INDENT_AMOUNT` characters.

      参数:
        `transformer` - the target transformer
      另请参阅:
        `Transformer.setOutputProperty(String, String)`, `OutputKeys.INDENT`

    - #### enableIndenting

          public static void enableIndenting(Transformer transformer,
                                             int indentAmount)

      Enable indenting for the supplied `Transformer`.

      If the underlying XSLT engine is Xalan, then the special output key `indent-amount` will be also be set to a value of `DEFAULT_INDENT_AMOUNT` characters.

      参数:
        `transformer` - the target transformer
        `indentAmount` - the size of the indent (2 characters, 3 characters, etc)
      另请参阅:
        `Transformer.setOutputProperty(String, String)`, `OutputKeys.INDENT`

    - #### disableIndenting

          public static void disableIndenting(Transformer transformer)

      Disable indenting for the supplied `Transformer`.
      参数:
        `transformer` - the target transformer
      另请参阅:
        `OutputKeys.INDENT`