Add method info.

@param methodInfoList
the method info list
@param classNameToClassInfo
the map from class name to class info
510
void addMethodInfo(final MethodInfoList methodInfoList, final Map<String, ClassInfo> classNameToClassInfo) {
        for (final MethodInfo mi : methodInfoList) {
            // Index method annotations
            addFieldOrMethodAnnotationInfo(mi.annotationInfo, /* isField = */ false, classNameToClassInfo);

            // Index method parameter annotations
            if (mi.parameterAnnotationInfo != null) {
                for (int i = 0; i < mi.parameterAnnotationInfo.length; i++) {
                    final AnnotationInfo[] paramAnnotationInfoArr = mi.parameterAnnotationInfo[i];
                    if (paramAnnotationInfoArr != null) {
                        for (int j = 0; j < paramAnnotationInfoArr.length; j++) {
                            final AnnotationInfo methodParamAnnotationInfo = paramAnnotationInfoArr[j];
                            final ClassInfo annotationClassInfo = getOrCreateClassInfo(
                                    methodParamAnnotationInfo.getName(), ANNOTATION_CLASS_MODIFIER,
                                    classNameToClassInfo);
                            annotationClassInfo.addRelatedClass(RelType.CLASSES_WITH_METHOD_PARAMETER_ANNOTATION,
                                    this);
                            this.addRelatedClass(RelType.METHOD_PARAMETER_ANNOTATIONS, annotationClassInfo);
                        }
                    }
                }
            }
        }
        if (this.methodInfo == null) {
            this.methodInfo = methodInfoList;
        } else {
            this.methodInfo.addAll(methodInfoList);
        }
    }
876526
public final List<MethodInfo> getMethods(String name) {
    List<MethodInfo> namedMethod = methods.get(name);
    if (null == namedMethod) return Collections.emptyList();
    else return namedMethod;
  }
18467
public void addAnnotationInfo(final AnnotationInfo annotationInfo) {
        ArgUtils.notNull(annotationInfo, "annotationInfo");
        
        removeAnnotationInfo(annotationInfo.getClassName());
        this.annotationInfos.add(annotationInfo);
    }
977618
def add_method(info, target_cls, virtual=False, dont_replace=False):
    """"""

    # escape before prefixing, like pygobject
    name = escape_identifier(info.name)
    if virtual:
        name = "do_" + name
        attr = VirtualMethodAttribute(info, target_cls, name)
    else:
        attr = MethodAttribute(info, target_cls, name)

    if dont_replace and hasattr(target_cls, name):
        return

    setattr(target_cls, name, attr)
74222
private final void internalInfo(Object source, Class sourceClass, String methodName, String messageIdentifier, Object object)
    {
        if (usePrintWriterForTrace)
        {
            if (printWriter != null)
            {
                StringBuffer stringBuffer = new StringBuffer(new java.util.Date().toString());

                stringBuffer.append(" I ");
                stringBuffer.append(sourceClass.getName());
                stringBuffer.append(".");
                stringBuffer.append(methodName);


                printWriter.println(stringBuffer.toString());
                printWriter.println("\t\t"+NLS.format(messageIdentifier, object));
                printWriter.flush();
            }
        }

        if (object != null)
        {
            Tr.info(traceComponent, messageIdentifier, object);
        }
        else
        {
            Tr.info(traceComponent, messageIdentifier);
        }
    }
1153019
public void setNodeInfoList(java.util.Collection<NodeInfo> nodeInfoList) {
        if (nodeInfoList == null) {
            this.nodeInfoList = null;
            return;
        }

        this.nodeInfoList = new java.util.ArrayList<NodeInfo>(nodeInfoList);
    }
1319903
protected static void addInfo(List<CmsAdditionalInfoBean> infos, String label, String value) {

        infos.add(new CmsAdditionalInfoBean(label, value, null));
    }
101175
void addFieldInfo(String className, List<FieldInfo> fieldInfoList) {
        if (ivFieldInfoMap == null) {
            ivFieldInfoMap = new HashMap<String, List<FieldInfo>>();
        }
        ivFieldInfoMap.put(className, fieldInfoList);
    }
899865
static void addClassContainment(final List<SimpleEntry<String, String>> classContainmentEntries,
            final Map<String, ClassInfo> classNameToClassInfo) {
        for (final SimpleEntry<String, String> ent : classContainmentEntries) {
            final String innerClassName = ent.getKey();
            final ClassInfo innerClassInfo = ClassInfo.getOrCreateClassInfo(innerClassName,
                    /* classModifiers = */ 0, classNameToClassInfo);
            final String outerClassName = ent.getValue();
            final ClassInfo outerClassInfo = ClassInfo.getOrCreateClassInfo(outerClassName,
                    /* classModifiers = */ 0, classNameToClassInfo);
            innerClassInfo.addRelatedClass(RelType.CONTAINED_WITHIN_OUTER_CLASS, outerClassInfo);
            outerClassInfo.addRelatedClass(RelType.CONTAINS_INNER_CLASS, innerClassInfo);
        }
    }
613956
public ClassInfo getClassInfo() {
        return new ClassInfo(version, access, name, signature, supername,
                             interfaces, methodMap, fieldMap);
    }
332801
public Map<String, MethodInfoList> asMap() {
        // Note that MethodInfoList extends InfoList rather than MappableInfoList, because one
        // name can be shared by multiple MethodInfo objects (so asMap() needs to be of type
        // Map<String, MethodInfoList> rather than Map<String, MethodInfo>)
        final Map<String, MethodInfoList> methodNameToMethodInfoList = new HashMap<>();
        for (final MethodInfo methodInfo : this) {
            final String name = methodInfo.getName();
            MethodInfoList methodInfoList = methodNameToMethodInfoList.get(name);
            if (methodInfoList == null) {
                methodInfoList = new MethodInfoList(1);
                methodNameToMethodInfoList.put(name, methodInfoList);
            }
            methodInfoList.add(methodInfo);
        }
        return methodNameToMethodInfoList;
    }
233283
public MethodInfo addMethod(Method method) {
        Modifiers modifiers = Modifiers.getInstance(method.getModifiers()).toAbstract(false);
        MethodInfo mi = addMethod(modifiers, method.getName(), MethodDesc.forMethod(method));
        
        // exception stuff...
        Class[] exceptions = method.getExceptionTypes();
        for (int i=0; i<exceptions.length; i++) {
            mi.addException(TypeDesc.forClass(exceptions[i]));
        }

        return mi;
    }
1295419
@Override
    public MethodInfo getMethodInfo(ELContext context) throws PropertyNotFoundException, MethodNotFoundException,
        ELException
    {
        checkNullArgument(context, "elcontext");
        checkNullState(methodBinding, "methodBinding");

        if (methodInfo == null)
        {
            final FacesContext facesContext = (FacesContext)context.getContext(FacesContext.class);
            if (facesContext != null)
            {
                methodInfo = invoke(new Invoker<MethodInfo>()
                {
                    public MethodInfo invoke()
                    {
                        return new MethodInfo(null, methodBinding.getType(facesContext), null);
                    }
                });
            }
        }
        return methodInfo;
    }
427883
public static function addMethodToDebugBlacklist($class, $methodName)
    {
        if (isset(static::$blacklistDebugMethods[$class]) === false) {
            static::$blacklistDebugMethods[$class] = array();
        }
        if (in_array($methodName, static::$blacklistDebugMethods[$class]) === false) {
            static::$blacklistDebugMethods[$class][] = $methodName;
        }
    }
123116
@Override
    void findReferencedClassNames(final Set<String> classNameListOut) {
        classNameListOut.add(className);
        classNameListOut.add(getFullyQualifiedClassName());
        for (final TypeArgument typeArgument : typeArguments) {
            typeArgument.findReferencedClassNames(classNameListOut);
        }
    }
387701
public void setStreamInfoList(java.util.Collection<StreamInfo> streamInfoList) {
        if (streamInfoList == null) {
            this.streamInfoList = null;
            return;
        }

        this.streamInfoList = new java.util.ArrayList<StreamInfo>(streamInfoList);
    }
862482
@SuppressWarnings({ "rawtypes", "unchecked" })
	public void callMethod(final MethodCallInfo info) {
		try {
			MethodsCaller.logger.info("loading class : ".concat(info.getClassName()));
			final Class clas = getClass().getClassLoader().loadClass(info.getClassName());
			MethodsCaller.logger.info("calling default constructor");
			final Object object = clas.newInstance();
			MethodsCaller.logger.info("calling method : " + info.getMethodName() + " , with params: ".concat(Arrays.toString(info.getParamters())));
			final Method method = clas.getMethod(info.getMethodName(), info.getParamtersTypes());
			final Object result = method.invoke(object, info.getParamters());
			if (!(result instanceof Serializable)) {
				throw new IllegalStateException("object " + result + " from type " + result.getClass().getName() + " is not serialzable");
			}
			info.setResult(result);
		} catch (ClassNotFoundException | InstantiationException | IllegalAccessException | NoSuchMethodException | SecurityException
				| IllegalArgumentException | InvocationTargetException e) {
			MethodsCaller.logger.severe("calling to method failed : ".concat(info.toString()));
			throw new RemoteReflectionException(e);
		}
	}