org.springframework.core.style

## 类 ToStringCreator

- java.lang.Object
- - org.springframework.core.style.ToStringCreator

-     public class ToStringCreator
      extends Object

  Utility class that builds pretty-printing `toString()` methods with pluggable styling conventions. By default, ToStringCreator adheres to Spring's `toString()` styling conventions.
  从以下版本开始:
    1.2.2
  作者:
    Keith Donald, Juergen Hoeller

- - ### 构造器概要

    构造器
    构造器和说明
    `ToStringCreator(Object obj)` Create a ToStringCreator for the given object.
    `ToStringCreator(Object obj, ToStringStyler styler)` Create a ToStringCreator for the given object, using the provided style.
    `ToStringCreator(Object obj, ValueStyler styler)` Create a ToStringCreator for the given object, using the provided style.

  - ### 方法概要

    所有方法 实例方法 具体方法
    限定符和类型 | 方法和说明
    --- | ---
    `ToStringCreator` | `append(Object value)` Append the provided value.
    `ToStringCreator` | `append(String fieldName, boolean value)` Append a boolean field value.
    `ToStringCreator` | `append(String fieldName, byte value)` Append a byte field value.
    `ToStringCreator` | `append(String fieldName, double value)` Append a double field value.
    `ToStringCreator` | `append(String fieldName, float value)` Append a float field value.
    `ToStringCreator` | `append(String fieldName, int value)` Append a integer field value.
    `ToStringCreator` | `append(String fieldName, long value)` Append a long field value.
    `ToStringCreator` | `append(String fieldName, Object value)` Append a field value.
    `ToStringCreator` | `append(String fieldName, short value)` Append a short field value.
    `String` | `toString()` Return the String representation that this ToStringCreator built.

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

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

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

    - #### ToStringCreator

          public ToStringCreator(Object obj)

      Create a ToStringCreator for the given object.
      参数:
        `obj` - the object to be stringified

    - #### ToStringCreator

          public ToStringCreator(Object obj,
                                 @Nullable
                                 ValueStyler styler)

      Create a ToStringCreator for the given object, using the provided style.
      参数:
        `obj` - the object to be stringified
        `styler` - the ValueStyler encapsulating pretty-print instructions

    - #### ToStringCreator

          public ToStringCreator(Object obj,
                                 @Nullable
                                 ToStringStyler styler)

      Create a ToStringCreator for the given object, using the provided style.
      参数:
        `obj` - the object to be stringified
        `styler` - the ToStringStyler encapsulating pretty-print instructions

  - ### 方法详细资料

    - #### append

          public ToStringCreator append(String fieldName,
                                        byte value)

      Append a byte field value.
      参数:
        `fieldName` - the name of the field, usually the member variable name
        `value` - the field value
      返回:
        this, to support call-chaining

    - #### append

          public ToStringCreator append(String fieldName,
                                        short value)

      Append a short field value.
      参数:
        `fieldName` - the name of the field, usually the member variable name
        `value` - the field value
      返回:
        this, to support call-chaining

    - #### append

          public ToStringCreator append(String fieldName,
                                        int value)

      Append a integer field value.
      参数:
        `fieldName` - the name of the field, usually the member variable name
        `value` - the field value
      返回:
        this, to support call-chaining

    - #### append

          public ToStringCreator append(String fieldName,
                                        long value)

      Append a long field value.
      参数:
        `fieldName` - the name of the field, usually the member variable name
        `value` - the field value
      返回:
        this, to support call-chaining

    - #### append

          public ToStringCreator append(String fieldName,
                                        float value)

      Append a float field value.
      参数:
        `fieldName` - the name of the field, usually the member variable name
        `value` - the field value
      返回:
        this, to support call-chaining

    - #### append

          public ToStringCreator append(String fieldName,
                                        double value)

      Append a double field value.
      参数:
        `fieldName` - the name of the field, usually the member variable name
        `value` - the field value
      返回:
        this, to support call-chaining

    - #### append

          public ToStringCreator append(String fieldName,
                                        boolean value)

      Append a boolean field value.
      参数:
        `fieldName` - the name of the field, usually the member variable name
        `value` - the field value
      返回:
        this, to support call-chaining

    - #### append

          public ToStringCreator append(String fieldName,
                                        @Nullable
                                        Object value)

      Append a field value.
      参数:
        `fieldName` - the name of the field, usually the member variable name
        `value` - the field value
      返回:
        this, to support call-chaining

    - #### append

          public ToStringCreator append(Object value)

      Append the provided value.
      参数:
        `value` - The value to append
      返回:
        this, to support call-chaining.

    - #### toString

          public String toString()

      Return the String representation that this ToStringCreator built.
      覆盖:
        `toString` 在类中 `Object`