Check if the methodMetaData interface is internal and supposed to be unprotected as per
spec.

@param methodMetaData methodMetaData to get the interface type
@return true if it should be unprotected, otherwise false
762068
private boolean isInternalUnprotectedMethod(EJBMethodMetaData methodMetaData) {
        EJBMethodInterface interfaceType = methodMetaData.getEJBMethodInterface();
        /***
         * For TIMED_OBJECT, the code references EJB 2.1 spec section 22.2.2 and matches a
         * method signature, which is necessary but not sufficient. As of EJB 3.0, the
         * TimedObject interface is not necessary and arbitrary methods can be designated
         * as timeout callback methods using the @Timeout annotation. Further, the EJB
         * 3.1 spec adds the ability to specify timeout methods without a Timer argument,
         * and it also adds new timeout callback methods via the @Schedule annotation. In
         * all of these cases, the MethodInterface will be TIMED_OBJECT.
         *
         * For LIFECYCLE_INTERCEPTOR, this type is used only for lifecycle interceptors of
         * EJB 3.1 singleton session beans. This type should have been added to the EJB 3.1
         * spec, but it was overlooked by the EG. However, EJB container needs to classify
         * methods in this way, so an internal type was added.
         *
         * For background on why returning true from internalUnprotected is correct for
         * LIFECYCLE_INTERCEPTOR, a singleton method invocation has two steps, and the
         * container invokes the security collaborator for each.
         *
         * 1. Obtain the bean instance if it does not already exist.
         * If the bean does not exist, the container calls the security collaborator
         * with LifecycleInterceptor to establish a RunAs security context. However,
         * authorization checks are not needed because the bean is performing
         * initialization, not business logic. Further, attempting to pass the
         * internal-only LifecycleInterceptor type to JACC causes an
         * IllegalArgumentException.
         *
         * If a singleton session bean is annotated @Startup, then the container
         * performs this step as part of application start rather than when a method
         * is first invoked on the bean. This is the scenario for this defect.
         *
         * 2. Invoke the business method.
         * The container calls the security collaborator "as normal" with Local,
         * Remote, or ServiceEndpoint to both authorize the caller security context
         * and to establish a RunAs security context as needed.
         *
         * Per EJB spec section 22.2.2:
         *
         * Since the ejbTimeout method is an internal method of the bean class,
         * it has no client security context. When getCallerPrincipal is called
         * from within the ejbTimeout method, it returns the container
         * representation of the unauthenticated identity.
         * Since the ejbTimeout method is an internal method of the bean class,
         * it has no client security context. The Bean Provider should use the
         * run-as deployment descriptor element to specify a security identity to
         * be used for the invocation of methods from within the ejbTimeout method.
         *
         * Because of the above spec requirements, we still need to establish the
         * runasSpecified identity when this method is called.
         **/
        if (EJBMethodInterface.LIFECYCLE_INTERCEPTOR.value() == (interfaceType.value()) ||
            EJBMethodInterface.TIMER.value() == (interfaceType.value())) {
            return true;
            //TODO: should this logic go into ejb container?
        }
        return false;
    }
380589
ObjectMetadata toObjectMetadata(ObjectMetadata metadata, CryptoMode mode) {
        return mode == CryptoMode.EncryptionOnly && !usesKMSKey()
               ? toObjectMetadataEO(metadata)
               : toObjectMetadata(metadata);
    }
287908
public boolean hasDeclaredMethodAnnotation(final String methodAnnotationName) {
        for (final MethodInfo mi : getDeclaredMethodInfo()) {
            if (mi.hasAnnotation(methodAnnotationName)) {
                return true;
            }
        }
        return false;
    }
834400
public boolean isMethod(MetaMethod method) {
        return getName().equals(method.getName())
            && getModifiers() == method.getModifiers()
            && getReturnType().equals(method.getReturnType())
            && equal(getParameterTypes(), method.getParameterTypes());
    }
207584
private static boolean isGetterMethod(Method method) {
		return !Modifier.isStatic(method.getModifiers())
			&& (method.getName().startsWith("get") || method.getName().startsWith("is"))
			&& method.getParameterTypes().length == 0;
	}
410506
public static boolean isObjectMethod(Method method) {
        return OBJECT_METHOD.stream().filter(meta -> meta.equals(method)).limit(1).count() > 0;
    }
745164
public static boolean isMatch(Method methodA, Method methodB)
  {
    if (! methodA.getName().equals(methodB.getName()))
      return false;

    return isMatch(methodA.getParameterTypes(),
                   methodB.getParameterTypes());
  }
336793
private Collection<MethodMetadata<?, ?>> getMethodMetadataOfType(AnnotatedType annotatedType, Collection<AnnotatedMethod> annotatedMethods) {
        Collection<MethodMetadata<?, ?>> methodMetadataOfType = new ArrayList<>();
        // Collect the getter methods as they provide annotations holding meta
        // information also to be applied to setters
        for (AnnotatedMethod annotatedMethod : annotatedMethods) {
            MethodMetadata<?, ?> methodMetadata;
            ImplementedBy implementedBy = annotatedMethod.getAnnotation(ImplementedBy.class);
            ResultOf resultOf = annotatedMethod.getAnnotation(ResultOf.class);
            if (implementedBy != null) {
                methodMetadata = new ImplementedByMethodMetadata<>(annotatedMethod, implementedBy.value(),
                        metadataFactory.createImplementedByMetadata(annotatedMethod));
            } else if (resultOf != null) {
                methodMetadata = createResultOfMetadata(annotatedMethod, resultOf);
            } else if (annotatedMethod instanceof PropertyMethod) {
                PropertyMethod propertyMethod = (PropertyMethod) annotatedMethod;
                Transient transientAnnotation = propertyMethod.getAnnotationOfProperty(Transient.class);
                if (transientAnnotation != null) {
                    methodMetadata = new TransientPropertyMethodMetadata(propertyMethod);
                } else {
                    methodMetadata = createPropertyMethodMetadata(annotatedType, propertyMethod);
                }
            } else {
                methodMetadata = new UnsupportedOperationMethodMetadata((UserMethod) annotatedMethod);
            }
            methodMetadataOfType.add(methodMetadata);
        }
        return methodMetadataOfType;
    }
869351
public boolean readMetaDataIfNeeded() throws IOException {
    if (eofReached) {
      return false;
    }
    if (rawBlockOffset == 0) {
      try {
        metaDataConsumer.readMetaData(in, metaDataBlockSize);
        rawBlockOffset += metaDataBlockSize;
      } catch (EOFException e) {
        eofReached = true;
        return false;
      }
    }
    return true;
  }
607087
public static boolean isMethodOverridden(Method m, LinkedList<Class<?>> supers)
    {
        // Only check non-private methods for an override.
        int methodModifier = m.getModifiers();
        if (!Modifier.isPrivate(methodModifier))
        {
            // Not a private method, so we need to check if it is overridden.
            int startIndex = supers.indexOf(m.getDeclaringClass()) + 1;
            if (startIndex < supers.size())
            {
                String name = m.getName();
                Class<?>[] pTypes = m.getParameterTypes();
                for (ListIterator<Class<?>> lit = supers.listIterator(startIndex); lit.hasNext();)
                {
                    Class<?> subClass = lit.next();
                    try
                    {
                        subClass.getDeclaredMethod(name, pTypes);
                        return true;
                    } catch (NoSuchMethodException e)
                    {
                        //FFDCFilter.processException( e, "", "", m);
                        // This is normal, it just means the method was not overridden
                        // by a method in the current subclass being processed.
                    }
                }
            }
        }

        // The method is not overridden either because it is a private method,
        // or there is no subclass that overrides the method.
        return false;
    }
1208978
private function isAudited(ClassMetadata $cm)
    {
        if ($this->metadataFactory->isAudited($cm->name)) {
            return true;
        }

        if ($cm->isInheritanceTypeJoined() && $cm->rootEntityName == $cm->name) {
            foreach ($cm->subClasses as $subClass) {
                if ($this->metadataFactory->isAudited($subClass)) {
                    return true;
                }
            }
        }

        return false;
    }
589850
private static boolean isRelevantGetter(Method m) {
        return (m.getName().startsWith("get") || m.getName().startsWith("is"))
                && m.getParameterTypes().length == 0
                && ! (m.isBridge() || m.isSynthetic())
                && isDocumentType(m.getDeclaringClass())
                && !ReflectionUtils.getterOrFieldHasAnnotation(m, DynamoDBIgnore.class);
    }
719777
protected boolean isSetterMethod(Method method) {
        Matcher matcher = _setterRegex.matcher(method.getName());
        if (matcher.matches()) {

            if (Modifier.isStatic(method.getModifiers())) return false;
            if (!Modifier.isPublic(method.getModifiers())) return false;
            if (!Void.TYPE.equals(method.getReturnType())) return false;

            // method parameter checks
            Class[] params = method.getParameterTypes();
            if (params.length != 1) return false;
            if (TypeMappingsFactory.TYPE_UNKNOWN == _tmf.getTypeId(params[0])) return false;

            return true;
        }
        return false;
    }
1307304
boolean checkIntegrity () {
        if (headerType == null) return false;
        if (headerType == HeaderType.MODE_PARAMETER_HEADER_6 && longLba) return false;
        return true;
    }
888481
@edu.umd.cs.findbugs.annotations.SuppressFBWarnings(value = "EXS_EXCEPTION_SOFTENING_RETURN_FALSE", justification = "No other simple way to determine whether class exists")
    private boolean checkConfusedName(String methodOrVariableName, String signature) {
        try {
            String name = methodOrVariableName.toLowerCase(Locale.ENGLISH);
            if ((name.endsWith("map") || (name.endsWith("set") && !name.endsWith("toset")) || name.endsWith("list") || name.endsWith("queue"))
                    && signature.startsWith("Ljava/util/")) {
                String clsName = SignatureUtils.stripSignature(signature);
                JavaClass cls = Repository.lookupClass(clsName);
                if ((cls.implementationOf(mapInterface) && !name.endsWith("map")) || (cls.implementationOf(setInterface) && !name.endsWith("set"))
                        || ((cls.implementationOf(listInterface) || cls.implementationOf(queueInterface)) && !name.endsWith("list")
                                && !name.endsWith("queue"))) {
                    return true;
                }
            }
        } catch (ClassNotFoundException cnfe) {
            bugReporter.reportMissingClass(cnfe);
        }

        return false;
    }
425073
private boolean inMethodConfigs(String methodConfigs, String methodName) {
        String[] excludeMethodCollections = StringUtils.splitWithCommaOrSemicolon(methodConfigs);
        for (String excludeMethodName : excludeMethodCollections) {
            boolean exist = StringUtils.equals(excludeMethodName, methodName);
            if (exist) {
                return true;
            }
        }
        return false;
    }
1093377
@SuppressWarnings( "unchecked" )
    protected void processParametersOfMethodDeclaration( MethodDeclaration methodDeclaration,
                                                         MethodMetadata methodMetadata ) {
        for (SingleVariableDeclaration singleVariableDeclaration : (List<SingleVariableDeclaration>)methodDeclaration.parameters()) {
            Type type = singleVariableDeclaration.getType();

            if (type.isPrimitiveType()) {
                FieldMetadata primitiveFieldMetadata = processVariableDeclaration(singleVariableDeclaration, type);
                methodMetadata.getParameters().add(primitiveFieldMetadata);
            }
            if (type.isParameterizedType()) {
                FieldMetadata parameterizedTypeFieldMetadata = processVariableDeclaration(singleVariableDeclaration, type);
                methodMetadata.getParameters().add(parameterizedTypeFieldMetadata);
            }
            if (type.isQualifiedType()) {
                // TODO
            }
            if (type.isSimpleType()) {
                FieldMetadata simpleTypeFieldMetadata = processVariableDeclaration(singleVariableDeclaration, type);
                methodMetadata.getParameters().add(simpleTypeFieldMetadata);
            }
            if (type.isArrayType()) {
                FieldMetadata arrayTypeFieldMetadata = processVariableDeclaration(singleVariableDeclaration, type);
                methodMetadata.getParameters().add(arrayTypeFieldMetadata);
            }
            if (type.isWildcardType()) {
                // TODO
            }
        }

    }