Returns the Procyon method definition for a specified method,
or null if not found.
547707
public MethodDeclaration getMethod(String name, String signature) {
    for (EntityDeclaration node : type.getMembers()) {
      if (node.getEntityType() == EntityType.METHOD) {
        MethodDeclaration method = (MethodDeclaration) node;
        if (method.getName().equals(name) && signature.equals(signature(method))) {
          return method;
        }
      }
    }
    return null;
  }
852853
int getMethodIndex(ExecutableElement method)
    {
        TypeElement declaringClass = (TypeElement) method.getEnclosingElement();
        String fullyQualifiedname = declaringClass.getQualifiedName().toString();
        return getRefIndex(Methodref.class, fullyQualifiedname, method.getSimpleName().toString(), Descriptor.getDesriptor(method));
    }
591283
public Method getMethod(final String name) {
      if (StringUtils.isNullOrBlank(name)) {
         return null;
      }
      return getMethods().stream().filter(method -> method.getName().equals(name)).findFirst().orElse(null);
   }
622159
@Override
   protected String resolveMethod(Method method)
   {
      final String fallBackName = convertToBeanName(method.getName()); 
      final String resourceName = method.getAnnotation(Resource.class).name();

      return getName(resourceName, fallBackName);
   }
459847
private static int getMethodModifiers(ExecutableElement method) {
    int modifiers = ElementUtil.fromModifierSet(method.getModifiers());
    if (method.isVarArgs()) {
      modifiers |= ElementUtil.ACC_VARARGS;
    }
    if (ElementUtil.isSynthetic(method)) {
      modifiers |= ElementUtil.ACC_SYNTHETIC;
    }
    return modifiers;
  }
1053219
public static Field getFieldFromMethod(Method method, Field[] expectedFields, DisConfigTypeEnum disConfigTypeEnum) {

        String fieldName;

        if (disConfigTypeEnum.equals(DisConfigTypeEnum.FILE)) {

            DisconfFileItem disconfFileItem = method.getAnnotation(DisconfFileItem.class);
            // 根据用户设定的注解来获取
            fieldName = disconfFileItem.associateField();

        } else {

            DisconfItem disItem = method.getAnnotation(DisconfItem.class);
            // 根据用户设定的注解来获取
            fieldName = disItem.associateField();
        }

        //
        // 如果用户未设定注解，则猜其名字
        //
        if (StringUtils.isEmpty(fieldName)) {
            // 从方法名 获取其 Field 名
            fieldName = ClassUtils.getFieldNameByGetMethodName(method.getName());
        }

        // 确认此Field名是正确的
        for (Field field : expectedFields) {

            if (field.getName().equals(fieldName)) {
                return field;
            }
        }

        LOGGER.error(method.toString() + " cannot get its related field name. ");

        return null;
    }
854352
public static Method findMethod(Class<?> clazz, String name) {
		for (Method me : clazz.getDeclaredMethods()) {
			if (me.getName().equalsIgnoreCase(name)) {
				return me;
			}
		}
		if (clazz.getSuperclass() != null) {
			return findMethod(clazz.getSuperclass(), name);
		}
		return null;
	}
591044
public final SgMethod findMethodByName(final String name) {
        if (name == null) {
            throw new IllegalArgumentException("The argument 'name' cannot be null!");
        }
        for (int i = 0; i < methods.size(); i++) {
            final SgMethod method = methods.get(i);
            if (method.getName().equals(name)) {
                return method;
            }
        }
        return null;
    }
673166
protected String isGetter(final Method<?, ?> method)
   {

      String methodName = method.getName();
      String propertyName;

      if (methodName.startsWith(ClassUtils.JAVABEAN_GET_PREFIX))
      {
         propertyName = methodName.substring(ClassUtils.JAVABEAN_GET_PREFIX.length());

      }
      else if (methodName.startsWith(ClassUtils.JAVABEAN_IS_PREFIX)
               && method.getReturnType() != null && boolean.class.equals(method.getReturnType().getQualifiedName()))
      {

         // As per section 8.3.2 (Boolean properties) of The JavaBeans API specification, 'is'
         // only applies to boolean (little 'b')

         propertyName = methodName.substring(ClassUtils.JAVABEAN_IS_PREFIX.length());
      }
      else
      {
         return null;
      }

      return StringUtils.decapitalize(propertyName);
   }
527406
@Nullable
  public static MethodTree findMethod(MethodSymbol symbol, VisitorState state) {
    return JavacTrees.instance(state.context).getTree(symbol);
  }
1096677
public Method getMethod(String methodName) {
        return checkNotNull(methods().get(checkNotNull(methodName)), 
        		"The method %s is not exists of object %s", methodName, delegateClass().getName());
    }
211651
function prototypeMethodOrNull(className, method) {
  var ctor = goog.global[className];
  return (ctor && ctor.prototype && ctor.prototype[method]) || null;
}
1069089
private MethodConfig getMethodConfig(String methodName) {
        if (methods == null) {
            return null;
        }
        return methods.get(methodName);
    }
111914
public Method findMethod (String methodName, Object[] args)
        throws NoSuchMethodException
    {
        return findMethod(methodName, ClassUtil.getParameterTypesFrom(args));
    }
399318
@Override
	@Nullable
	public String getMapping(Method method) {

		Assert.notNull(method, "Method must not be null!");
		return getMapping(method.getDeclaringClass(), method);
	}
193488
public Method getMethod(MethodIdentifier methodIdentifier) {
        final Map<ParamNameList, Map<String, Method>> nameMap = methodsByTypeName.get(methodIdentifier.getName());
        if (nameMap == null) {
            return null;
        }
        final Map<String, Method> paramsMap = nameMap.get(createParamNameList(methodIdentifier.getParameterTypes()));
        if (paramsMap == null) {
            return null;
        }
        return paramsMap.get(methodIdentifier.getReturnType());
    }
533616
private static Optional<StandardMethod> maybeStandardMethod(ExecutableElement method) {
    String methodName = method.getSimpleName().toString();
    if (methodName.equals("equals")) {
      if (method.getParameters().size() == 1
          && method.getParameters().get(0).asType().toString().equals("java.lang.Object")) {
        return Optional.of(StandardMethod.EQUALS);
      } else {
        return Optional.empty();
      }
    } else if (methodName.equals("hashCode")) {
      if (method.getParameters().isEmpty()) {
        return Optional.of(StandardMethod.HASH_CODE);
      } else {
        return Optional.empty();
      }
    } else if (methodName.equals("toString")) {
      if (method.getParameters().isEmpty()) {
        return Optional.of(StandardMethod.TO_STRING);
      } else {
        return Optional.empty();
      }
    } else {
      return Optional.empty();
    }
  }