Returns the parameter types for the given {@link Method}.

@param method the {@link Method}
@return the parameter types
339971
static List<Class<?>> getParameterTypes(Method method) {
		if (parameterTypeCache.containsKey(method)) {
			return parameterTypeCache.get(method);
		}
		List<Class<?>> types = new ArrayList<>();
		Collections.addAll(types, method.getParameterTypes());
		types = Collections.unmodifiableList(types);
		parameterTypeCache.put(method, types);
		return types;
	}
959812
public Annotation[] getAnnotations(final Method method) throws AnnotationReadException {
        
        final Class<?> clazz = method.getDeclaringClass();
        
        if(xmlInfo != null && xmlInfo.containsClassInfo(clazz.getName())) {
            final ClassInfo classInfo = xmlInfo.getClassInfo(clazz.getName());
            
            if(classInfo.containsMethodInfo(method.getName())) {
                final MethodInfo methodInfo = classInfo.getMethodInfo(method.getName());
                final Map<String, Annotation> map = new HashMap<>();
                
                if(methodInfo.isOverride()) {
                    for(Annotation ann : method.getAnnotations()) {
                        map.put(ann.annotationType().getName(), ann);
                    }
                }
                
                for(AnnotationInfo annInfo: methodInfo.getAnnotationInfos()){
                    try {
                        map.put(annInfo.getClassName(),
                                annotationBuilder.buildAnnotation(Class.forName(annInfo.getClassName()), annInfo));
                    } catch (ClassNotFoundException e) {
                        throw new AnnotationReadException(String.format("not found class '%s'", annInfo.getClassName()), e);
                    }
                }
                
                return map.values().toArray(new Annotation[map.size()]);
            }
        }
        return method.getAnnotations();
    }
711917
public static MethodParameters of(Method method) {

		Assert.notNull(method, "Method must not be null!");

		return CACHE.computeIfAbsent(method, MethodParameters::new);
	}
941708
public static Class<?> getParamClass(Method method, int index) {
		Class<?>[] classes = getParamClasses(method);
		if (null != classes && classes.length > index) {
			return classes[index];
		}
		return null;
	}
104427
public static String methodToString(final Class<?> type, final Method method) {
        final StringBuilder res = new StringBuilder();
        res.append(type.getSimpleName()).append('#').append(method.getName()).append('(');
        int i = 0;
        for (Class<?> param : method.getParameterTypes()) {
            if (i > 0) {
                res.append(", ");
            }
            final Type generic = method.getGenericParameterTypes()[i];
            if (generic instanceof TypeVariable) {
                // using generic name, because its simpler to search visually in code
                res.append('<').append(((TypeVariable) generic).getName()).append('>');
            } else {
                res.append(param.getSimpleName());
            }
            i++;
        }
        res.append(')');
        return res.toString();
    }
247552
public static void assertNoParameters(final Method method, Class<? extends Annotation> annotation) 
   {
      if (method.getParameterTypes().length != 0)
      {
         throw annotation == null ? MESSAGES.methodHasToHaveNoParameters(method) : MESSAGES.methodHasToHaveNoParameters2(method, annotation);
      }
   }
162093
public SelectionType getSelection(final Method method) {
        final Annotation[] annotations = method.getAnnotations();
        return getSelection(annotations);
    }
574128
private List<Map<Class<? extends Annotation>, ParameterInfo<?>>> createParametersInfos(Method method) {
    if (method.getParameterTypes().length <= 2) {
      return Collections.emptyList();
    }

    List<Map<Class<? extends Annotation>, ParameterInfo<?>>> result = new ArrayList<>();
    Type[] parameterTypes = method.getGenericParameterTypes();
    Annotation[][] parameterAnnotations = method.getParameterAnnotations();

    for (int i = 2; i < parameterAnnotations.length; i++) {
      Annotation[] annotations = parameterAnnotations[i];
      Map<Class<? extends Annotation>, ParameterInfo<?>> paramAnnotations = new IdentityHashMap<>();

      for (Annotation annotation : annotations) {
        Class<? extends Annotation> annotationType = annotation.annotationType();
        ParameterInfo<?> parameterInfo;

        if (PathParam.class.isAssignableFrom(annotationType)) {
          parameterInfo = ParameterInfo.create(annotation,
                                               ParamConvertUtils.createPathParamConverter(parameterTypes[i]));
        } else if (QueryParam.class.isAssignableFrom(annotationType)) {
          parameterInfo = ParameterInfo.create(annotation,
                                               ParamConvertUtils.createQueryParamConverter(parameterTypes[i]));
        } else if (HeaderParam.class.isAssignableFrom(annotationType)) {
          parameterInfo = ParameterInfo.create(annotation,
                                               ParamConvertUtils.createHeaderParamConverter(parameterTypes[i]));
        } else {
          parameterInfo = ParameterInfo.create(annotation, null);
        }

        paramAnnotations.put(annotationType, parameterInfo);
      }

      // Must have either @PathParam, @QueryParam or @HeaderParam, but not two or more.
      int presence = 0;
      for (Class<? extends Annotation> annotationClass : paramAnnotations.keySet()) {
        if (SUPPORTED_PARAM_ANNOTATIONS.contains(annotationClass)) {
          presence++;
        }
      }
      if (presence != 1) {
        throw new IllegalArgumentException(
          String.format("Must have exactly one annotation from %s for parameter %d in method %s",
                        SUPPORTED_PARAM_ANNOTATIONS, i, method));
      }

      result.add(Collections.unmodifiableMap(paramAnnotations));
    }

    return Collections.unmodifiableList(result);
  }
667568
public static <T extends Annotation> List<T> getAnnotations(Method method, Class<T> type) {
		return filterAnnotations(getAnnotations(method), type);
	}
46774
public static String[] getParameterNames(Method method) {
		// AssertUtil.assertNotNull(method, "参数method不能为空.");
		Class<?> clazz = method.getDeclaringClass();
		return getParameterNames(clazz, method);
	}
583575
public String getMethodDescriptor(ExecutableType method) {
    StringBuilder sb = new StringBuilder("(");
    for (TypeMirror t : method.getParameterTypes()) {
      sb.append(getSignatureName(t));
    }
    sb.append(")");
    sb.append(getSignatureName(method.getReturnType()));
    return sb.toString();
  }
563889
final public void MethodParameters() throws ParseException {
                                             /*@bgen(jjtree) MethodParameters */
  AstMethodParameters jjtn000 = new AstMethodParameters(JJTMETHODPARAMETERS);
  boolean jjtc000 = true;
  jjtree.openNodeScope(jjtn000);
    try {
      jj_consume_token(LPAREN);
      switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
      case START_SET_OR_MAP:
      case INTEGER_LITERAL:
      case FLOATING_POINT_LITERAL:
      case STRING_LITERAL:
      case TRUE:
      case FALSE:
      case NULL:
      case LPAREN:
      case LBRACK:
      case NOT0:
      case NOT1:
      case EMPTY:
      case MINUS:
      case IDENTIFIER:
        Expression();
        label_15:
        while (true) {
          switch ((jj_ntk==-1)?jj_ntk():jj_ntk) {
          case COMMA:
            ;
            break;
          default:
            jj_la1[37] = jj_gen;
            break label_15;
          }
          jj_consume_token(COMMA);
          Expression();
        }
        break;
      default:
        jj_la1[38] = jj_gen;
        ;
      }
      jj_consume_token(RPAREN);
    } catch (Throwable jjte000) {
      if (jjtc000) {
        jjtree.clearNodeScope(jjtn000);
        jjtc000 = false;
      } else {
        jjtree.popNode();
      }
      if (jjte000 instanceof RuntimeException) {
        {if (true) throw (RuntimeException)jjte000;}
      }
      if (jjte000 instanceof ParseException) {
        {if (true) throw (ParseException)jjte000;}
      }
      {if (true) throw (Error)jjte000;}
    } finally {
      if (jjtc000) {
        jjtree.closeNodeScope(jjtn000, true);
      }
    }
  }
189389
public String [] getParamTypeDescriptors() {
        return methodType().parameterList().stream()
                .map(BSHType::getTypeDescriptor).toArray(String[]::new);
    }
757105
public String getName(Method method) {
        String name = getMethodName(method);

        if (method.isAnnotationPresent(JsonProperty.class) &&
            !"".equals(method.getAnnotation(JsonProperty.class).value())) {
            name = method.getAnnotation(JsonProperty.class).value();
        } else if (serializationConfig != null && serializationConfig.getPropertyNamingStrategy() != null) {
            Annotation[] declaredAnnotations = method.getDeclaredAnnotations();
            AnnotationMap annotationMap = buildAnnotationMap(declaredAnnotations);

            int paramsLength = method.getParameterAnnotations().length;
            AnnotationMap[] paramAnnotations = new AnnotationMap[paramsLength];
            for (int i = 0; i < paramsLength; i++) {
                AnnotationMap parameterAnnotationMap = buildAnnotationMap(method.getParameterAnnotations()[i]);
                paramAnnotations[i] = parameterAnnotationMap;
            }

            AnnotatedClass annotatedClass = AnnotatedClassBuilder.build(method.getDeclaringClass(), serializationConfig);
            AnnotatedMethod annotatedField = AnnotatedMethodBuilder.build(annotatedClass, method, annotationMap, paramAnnotations);
            name = serializationConfig.getPropertyNamingStrategy().nameForGetterMethod(serializationConfig, annotatedField, name);
        }
        return name;
    }
622249
private static boolean isRunnerMethod(Method method) {
        Class<?>[] parameterTypes = method.getParameterTypes();

        for (Class<?> parameterType : parameterTypes) {
            if (parameterType.isAssignableFrom(TestRunner.class)) {
                return true;
            }
        }

        return false;
    }
1137511
public static List<String> getParameters(final String methodDesc) {
//        final String[] types = resolveMethodSignature(methodDesc);
//        return IntStream.range(0, types.length).mapToObj(i -> types[i]).collect(Collectors.toList());
        if (methodDesc == null)
            return emptyList();

        final char[] buffer = methodDesc.toCharArray();
        final List<String> args = new ArrayList<>();

        // TODO resolve type parameters correctly -> information useful? -> maybe use ASM's SignatureReader/Visitor
        int offset = methodDesc.indexOf('(') + 1;
        while (buffer[offset] != ')') {
            final String type = getNextType(buffer, offset);
            args.add(type);
            offset += type.length();// + (type.charAt(0) == 'L' ? 2 : 0);
        }

        // TODO change, see type parameters
        // prevent type parameter identifiers
        final ListIterator<String> iterator = args.listIterator();
        while (iterator.hasNext()) {
            final String arg = iterator.next();
            if (arg.charAt(0) == 'T')
                iterator.set(OBJECT);
        }

        return args;
    }
459151
public static Method getMethod(Class<?> clazz, String methodName, Class<?>... parameterTypes) {
        if (clazz == null || methodName == null || methodName.length() == 0) {
            return null;
        }

        for (Class<?> itr = clazz; hasSuperClass(itr); ) {
            Method[] methods = itr.getDeclaredMethods();

            for (Method method : methods) {
                if (method.getName().equals(methodName) && Arrays.equals(method.getParameterTypes(), parameterTypes)) {
                    return method;
                }
            }

            itr = itr.getSuperclass();
        }
        return null;
    }