org.springframework.core

## 类 ParameterizedTypeReference<T>

- java.lang.Object
- - org.springframework.core.ParameterizedTypeReference<T>

-     public abstract class ParameterizedTypeReference<T>
      extends Object

  The purpose of this class is to enable capturing and passing a generic `Type`. In order to capture the generic type and retain it at runtime, you need to create a subclass (ideally as anonymous inline class) as follows:

       ParameterizedTypeReference<List<String>> typeRef = new ParameterizedTypeReference<List<String>>() {};

  The resulting `typeRef` instance can then be used to obtain a `Type` instance that carries the captured parameterized type information at runtime. For more information on "super type tokens" see the link to Neal Gafter's blog post.

  从以下版本开始:
    3.2
  作者:
    Arjen Poutsma, Rossen Stoyanchev
  另请参阅:
    Neal Gafter on Super Type Tokens

- - ### 构造器概要

    构造器
    限定符 | 构造器和说明
    --- | ---
    `protected` | `ParameterizedTypeReference()`

  - ### 方法概要

    所有方法 静态方法 实例方法 具体方法
    限定符和类型 | 方法和说明
    --- | ---
    `boolean` | `equals(Object other)`
    `static <T> ParameterizedTypeReference<T>` | `forType(Type type)` Build a `ParameterizedTypeReference` wrapping the given type.
    `Type` | `getType()`
    `int` | `hashCode()`
    `String` | `toString()`

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

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

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

    - #### ParameterizedTypeReference

          protected ParameterizedTypeReference()

  - ### 方法详细资料

    - #### getType

          public Type getType()

    - #### equals

          public boolean equals(Object other)

      覆盖:
        `equals` 在类中 `Object`

    - #### hashCode

          public int hashCode()

      覆盖:
        `hashCode` 在类中 `Object`

    - #### toString

          public String toString()

      覆盖:
        `toString` 在类中 `Object`

    - #### forType

          public static <T> ParameterizedTypeReference<T> forType(Type type)

      Build a `ParameterizedTypeReference` wrapping the given type.
      参数:
        `type` - a generic type (possibly obtained via reflection, e.g. from `Method.getGenericReturnType()`)
      返回:
        a corresponding reference which may be passed into `ParameterizedTypeReference`-accepting methods
      从以下版本开始:
        4.3.12