Interface GenericTypeAdapter

All Known Implementing Classes:
ClassTypingContext, MethodTypingContext

public interface GenericTypeAdapter
Provides adapting of generic types from one scope to another scope.
  • Method Details

    • getAdaptationScope

      CtFormalTypeDeclarer getAdaptationScope()
      the scope of this type adapter
    • adaptType

      CtTypeReference<?> adaptType(CtTypeInformation type)
      adapts `type` to the CtTypeReference of the scope of this GenericTypeAdapter This mapping function is able to resolve CtTypeParameter of:
      A) input type or any super class or any enclosing class of input type or it's super class
      B) super interfaces of input type or super interfaces of it's super classes.
      The type reference is adapted recursive including all it's actual type arguments and bounds.
      type - to be adapted type
      CtTypeReference adapted to scope of this ClassTypingContext or null if type cannot be adapted to this `scope`.
    • getEnclosingGenericTypeAdapter

      GenericTypeAdapter getEnclosingGenericTypeAdapter()
      the GenericTypeAdapter, which adapts generic types of enclosing type