Add an implemented interface to this class.

@param interfaceName
the interface name
@param classNameToClassInfo
the map from class name to class info
174753
void addImplementedInterface(final String interfaceName, final Map<String, ClassInfo> classNameToClassInfo) {
        final ClassInfo interfaceClassInfo = getOrCreateClassInfo(interfaceName,
                /* classModifiers = */ Modifier.INTERFACE, classNameToClassInfo);
        interfaceClassInfo.isInterface = true;
        interfaceClassInfo.modifiers |= Modifier.INTERFACE;
        this.addRelatedClass(RelType.IMPLEMENTED_INTERFACES, interfaceClassInfo);
        interfaceClassInfo.addRelatedClass(RelType.CLASSES_IMPLEMENTING, this);
    }
303201
private static void addInternal(String name, ObjectIdentifier oid,
            Class clazz) {
        OIDInfo info = new OIDInfo(name, oid, clazz);
        oidMap.put(oid, info);
        nameMap.put(name, info);
    }
926030
private Map<Class<?>, InterfaceInfo> getInterfaceInfoMap() {

        if (interfaceInfoMap == null) {
            interfaceInfoMap = new HashMap<Class<?>, InterfaceInfo>();
            for (final Class<?> c : packageClasses) {
                if (INTERESTING_CLASSES.accept( c )) {
                    if (!interfaceInfoMap.containsKey( c )) {
                        interfaceInfoMap.put( c, new InterfaceInfo( c ) );
                    }
                } else {
                    final Contract contract = c.getAnnotation( Contract.class );
                    if (contract != null) {
                        InterfaceInfo ii = interfaceInfoMap.get( contract.value() );
                        if (ii == null) {
                            ii = new InterfaceInfo( contract.value() );
                            interfaceInfoMap.put( contract.value(), ii );
                        }
                        ii.add( c );
                    }
                }
            }
        }
        return interfaceInfoMap;
    }
798299
protected void register(final Class<? extends Component<?>> interfaceClass, final Class<? extends Component<?>> implClass, final PriorityLevel priority) {
        register(interfaceClass, implClass, priority, 0);
    }
112438
public function checkInterfaceImplements(self $classDefinition, self $interfaceDefinition)
    {
        foreach ($interfaceDefinition->getMethods() as $method) {
            if (!$classDefinition->hasMethod($method->getName())) {
                throw new CompilerException(
                    sprintf(
                        'Class %s must implement a method called: "%s" as requirement of interface: "%s"',
                        $classDefinition->getCompleteName(),
                        $method->getName(),
                        $interfaceDefinition->getCompleteName()
                    )
                );
            }

            if (!$method->hasParameters()) {
                continue;
            }

            $implementedMethod = $classDefinition->getMethod($method->getName());
            if ($implementedMethod->getNumberOfRequiredParameters() > $method->getNumberOfRequiredParameters() ||
                $implementedMethod->getNumberOfParameters() < $method->getNumberOfParameters()
            ) {
                throw new CompilerException(
                    sprintf(
                        'Method %s::%s() does not have the same number of required parameters in interface: "%s"',
                        $classDefinition->getCompleteName(),
                        $method->getName(),
                        $interfaceDefinition->getCompleteName()
                    )
                );
            }
        }
    }
613956
public ClassInfo getClassInfo() {
        return new ClassInfo(version, access, name, signature, supername,
                             interfaces, methodMap, fieldMap);
    }
674036
public void addInterface(Class<?> newInterface) {
        if (!newInterface.isInterface()) {
            throw new IllegalArgumentException(newInterface + " is not an interface");
        }
        additionalInterfaces.add(newInterface);
    }
716231
public void addIndividual(String className, ClassInformation classInformation) {
        Validate.notNull(className);
        Validate.notNull(classInformation);
        Validate.isTrue(!hierarchyMap.containsKey(className));
        
        hierarchyMap.put(className, classInformation);
    }
86856
private static void getAllInterfaces(Class<?> cls, Collection<Class<?>> interfacesFound) {
        while (cls != null) {
            Class<?>[] interfaces = cls.getInterfaces();

            for (int i = 0; i < interfaces.length; i++) {
                interfacesFound.add(interfaces[i]);
                getAllInterfaces(interfaces[i], interfacesFound);
            }

            cls = cls.getSuperclass();
         }
     }
1254506
public <S extends T> TypeSerializationInfo<T> addTypeInfo( Class<S> clazz, String typeInfo ) {
        typeClassToInfo.put( clazz, typeInfo );
        return this;
    }
147846
@Override
    void findReferencedClassNames(final Set<String> classNameListOut) {
        if (classBound != null) {
            classBound.findReferencedClassNames(classNameListOut);
        }
        for (final ReferenceTypeSignature typeSignature : interfaceBounds) {
            typeSignature.findReferencedClassNames(classNameListOut);
        }
    }
1184677
public void addMethodInfo(final MethodInfo methodInfo) {
        ArgUtils.notNull(methodInfo, "methodInfo");
        
        removeMethodInfo(methodInfo.getMethodName());
        this.methodInfos.add(methodInfo);
    }
36391
public TypeInfo registerInnerClassWithGeneratedName(String simpleName, int accessModifiers) {
    simpleName = classNames.generateName(simpleName);
    TypeInfo innerClass = outer.innerClass(simpleName);
    innerClassesAccessModifiers.put(innerClass, accessModifiers);
    return innerClass;
  }
1136324
@Nonnull
    public BugInstance addClass(@SlashedClassName(when = When.UNKNOWN)  String className) {
        ClassAnnotation classAnnotation = new ClassAnnotation(ClassName.toDottedClassName(className));
        add(classAnnotation);
        return this;
    }
1127699
private void addMethodInfo(ExecutableElement method, Content dl) {
        TypeElement enclosing = utils.getEnclosingTypeElement(method);
        List<? extends TypeMirror> intfacs = enclosing.getInterfaces();
        ExecutableElement overriddenMethod = utils.overriddenMethod(method);
        // Check whether there is any implementation or overridden info to be
        // printed. If no overridden or implementation info needs to be
        // printed, do not print this section.
        if ((!intfacs.isEmpty()
                && new ImplementedMethods(method, this.configuration).build().isEmpty() == false)
                || overriddenMethod != null) {
            MethodWriterImpl.addImplementsInfo(this, method, dl);
            if (overriddenMethod != null) {
                MethodWriterImpl.addOverridden(this,
                        utils.overriddenType(method),
                        overriddenMethod,
                        dl);
            }
        }
    }
235594
public void addPlugin(String pluginTypeName) {
		try {
			Class<?> pluginType = Class.forName(pluginTypeName);
			if (SimonConsolePlugin.class.isAssignableFrom(pluginType)) {
				addPlugin((Class<? extends SimonConsolePlugin>) pluginType);
			} else {
				throw new IllegalArgumentException("Invalid plugin type " + pluginTypeName);
			}
		} catch (ClassNotFoundException classNotFoundException) {
			throw new IllegalArgumentException("Invalid plugin type " + pluginTypeName, classNotFoundException);
		}
	}
1255634
public void addInterface(String interfaceName) {
        if (!mInterfaceSet.contains(interfaceName)) {
            mInterfaces.add(ConstantClassInfo.make(mCp, interfaceName));
            mInterfaceSet.add(interfaceName);
        }
    }