Class MultiMethod


  • public class MultiMethod
    extends Object
    • Constructor Detail

      • MultiMethod

        public MultiMethod()
    • Method Detail

      • findMethodByParamsCached

        public static <T> Method findMethodByParamsCached​(Class<T> clazz,
                                                          String name,
                                                          List<Class<?>> typeSignature)
        Errors on lookup (such as no or multiple candidates) ar not cached in will result in new lookups.
        Type Parameters:
        T -
        Parameters:
        clazz -
        name -
        typeSignature -
        Returns:
      • findMethodByParams

        public static <T> Method findMethodByParams​(Class<T> clazz,
                                                    String name,
                                                    Class<?>... typeSignature)
      • findInvocationMethod

        public static <T> Method findInvocationMethod​(Class<T> clazz,
                                                      Class<?> returnType,
                                                      Class<?>... args)
        Find the best matching methods for the given types. Used for casts
        Type Parameters:
        T -
        Parameters:
        clazz -
        returnType -
        args -
        Returns: