Here you can find the source of getMethodByNameSimple(Class> clz, String methodName)
public static Method getMethodByNameSimple(Class<?> clz, String methodName)
//package com.java2s; //License from project: Apache License import java.lang.reflect.Method; public class Main { public static Method getMethodByNameSimple(Class<?> clz, String methodName) { Method[] methods = clz.getDeclaredMethods(); for (Method method : methods) { if (method.getName().equals(methodName)) { return method; }/*from w w w. ja v a2 s .c o m*/ } return null; } }