Class TypeHints
java.lang.Object
ru.progrm_jarvis.javacommons.util.TypeHints
Utilities related to special hacks around Java's types, especially generics.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic @interfaceMarks the specified method argument as a type hint. -
Method Summary
-
Method Details
-
resolve
Resolves the generic type being the component of the provided var-arg array. This is intended for automatic type-deduction in generic context without explicit class object specification.- Type Parameters:
T- generic type whose class object should be resolved- Parameters:
typeHint- array used to discover the type, its contents don't matter and it can be empty- Returns:
- class object for the given array
-