gradle
8.2

# typeOf

open fun <T> typeOf(type: Class<T>): TypeOf<T>

Creates an instance of TypeOf for the given Class.

#### Return

the TypeOf that captures the generic type of the given Class

#### Parameters

type

the Class

<T>

the parameterized type of the given Class

open fun <T> typeOf(type: Type): TypeOf<T>

Creates an instance of TypeOf for the given Type.

#### Return

the TypeOf that captures the generic type of the given Type

#### Parameters

type

the Type

<T>

the parameterized type of the given Type