Gets methods.

@param privileged the privileged
@return the methods
6506
public Set<Method> getMethods(boolean privileged) {
      if (privileged) {
         return Collections.unmodifiableSet(Sets.union(methods, declaredMethods));
      } else {
         return Collections.unmodifiableSet(methods);
      }
   }
307008
public static Set<String> getMethodNames(Class<?> clazz) throws SecurityException {
		final HashSet<String> methodSet = new HashSet<String>();
		final Method[] methods = getMethods(clazz);
		for (Method method : methods) {
			methodSet.add(method.getName());
		}
		return methodSet;
	}
1239516
public Set<Field> getFields(boolean privileged) {
      if (privileged) {
         return Collections.unmodifiableSet(Sets.union(fields, declaredFields));
      } else {
         return Collections.unmodifiableSet(fields);
      }
   }
811855
static Set<PasswordCredential> getPasswordCredentials(final Subject subject)
   {
      if (System.getSecurityManager() == null)
         return subject.getPrivateCredentials(PasswordCredential.class);

      return AccessController.doPrivileged(new PrivilegedAction<Set<PasswordCredential>>() 
      {
         public Set<PasswordCredential> run()
         {
            return subject.getPrivateCredentials(PasswordCredential.class);
         }
      });
   }
785928
public static List<Method> getPublicMethods(Class<?> clazz, Method... excludeMethods) {
		return ReflectUtil.getPublicMethods(clazz, excludeMethods);
	}
128813
private static List<MethodInfo> getPublicMethodInfos(final JavaClass cls) {
        List<MethodInfo> methodInfos = new ArrayList<>();
        Method[] methods = cls.getMethods();
        for (Method m : methods) {
            if ((m.getAccessFlags() & (Const.ACC_PUBLIC | Const.ACC_PROTECTED)) != 0) {
                ExceptionTable et = m.getExceptionTable();
                methodInfos
                        .add(new MethodInfo(m.getName(), m.getSignature(), et == null ? null : et.getExceptionNames()));
            }
        }
        return methodInfos;
    }
1041727
public static List<Method> getPublicMethods(Class<?> clazz, Method... excludeMethods) {
		final HashSet<Method> excludeMethodSet = CollectionUtil.newHashSet(excludeMethods);
		return getPublicMethods(clazz, new Filter<Method>() {
			@Override
			public boolean accept(Method method) {
				return false == excludeMethodSet.contains(method);
			}
		});
	}
1232412
public static Method getPublicMethod(Class<?> clazz, String methodName, Class<?>... paramTypes) throws SecurityException {
		return ReflectUtil.getPublicMethod(clazz, methodName, paramTypes);
	}
1364366
public Method getMethod(Class clz, String mangledMethodName) {

		Map<String, Method> methods = methodsByComponentType.get(clz);

		if (methods == null) {
			methods = new HashMap<String, Method>();
			methodsByComponentType.put(clz, methods);

			for (Method method : clz.getDeclaredMethods()) {
				Class<?>[] param = method.getParameterTypes();
				String mangledName1 = method.getName() + "__" + param.length;
				String mangledName2 = AbstractSkeleton
						.mangleName(method, false);

				if (param.length == 0 || !methods.containsKey(method.getName())) {
					methods.put(method.getName(), method);
				}

				methods.put(mangledName1, method);
				methods.put(mangledName2, method);
			}
		}

		return (Method) methods.get(mangledMethodName);
	}
1066918
private Map<Method, Class<? extends Annotation>> getControllerMethods(Class<? extends Controller> controllerClass) {
        // collect the annotated methods
        Map<Method, Class<? extends Annotation>> controllerMethods = new LinkedHashMap<>();

        // discover all annotated controllers methods
        for (Method method : ClassUtils.getDeclaredMethods(controllerClass)) {
            for (Annotation annotation : method.getAnnotations()) {
                Class<? extends Annotation> annotationClass = annotation.annotationType();
                if (httpMethodAnnotationClasses.contains(annotationClass)) {
                    controllerMethods.put(method, annotationClass);
                    break;
                }
            }
        }

        return controllerMethods;
    }
542116
@SuppressWarnings("unchecked")
   private Iterator getDomainData() throws PrivilegedActionException
   {
      return AccessController.doPrivileged(new PrivilegedExceptionAction<Iterator>()
      {
         public Iterator run() throws Exception
         {
            return Server.getDomainData();
         }
      });
   }
92494
public GroovyMethodDoc[] methods() {
        Collections.sort(methods);
        return methods.toArray(new GroovyMethodDoc[methods.size()]);
    }
639865
public static Method[] getMethods(Class<?> clazz, Filter<Method> filter) throws SecurityException {
		if (null == clazz) {
			return null;
		}
		return ArrayUtil.filter(getMethods(clazz), filter);
	}
152429
public final List<MethodInfo> getMethods() {
    List<MethodInfo> methodInfos = CollectUtils.newArrayList();
    for (Map.Entry<String, List<MethodInfo>> entry : methods.entrySet()) {
      for (MethodInfo info : entry.getValue())
        methodInfos.add(info);
    }
    Collections.sort(methodInfos);
    return methodInfos;
  }
579039
public static List<Method> getAllMethods(List<Method> methods, Class<?> clazz)
  {
    for (Method method : clazz.getDeclaredMethods())
    {
      methods.add(method);
    }

    if (clazz.getSuperclass() != null)
    {
      methods = getAllMethods(methods, clazz.getSuperclass());
    }

    return methods;
  }
786462
public Set<Constructor<?>> getConstructors(boolean privileged) {
      if (privileged) {
         return Collections.unmodifiableSet(Sets.union(constructors, declaredConstructors));
      } else {
         return Collections.unmodifiableSet(constructors);
      }
   }
1089038
public Method[] findAdaptMethodsFrom(Class from) {
        Method[] methods = mAdaptMethods;
        List<Method> candidates = new ArrayList<Method>(methods.length);
        for (int i=methods.length; --i>=0; ) {
            Method method = methods[i];
            if (method.getParameterTypes()[0].isAssignableFrom(from)) {
                candidates.add(method);
            }
        }
        return (Method[]) candidates.toArray(new Method[candidates.size()]);
    }