public void processAnnotations(DescriptorPolicy descriptorPolicy, ScoreDefinition scoreDefinition) {
        processPackAnnotation(descriptorPolicy);
        ArrayList<Method> potentiallyOverwritingMethodList = new ArrayList<>();
        // Iterate inherited members too (unlike for EntityDescriptor where each one is declared)
        // to make sure each one is registered
        for (Class<?> lineageClass : ConfigUtils.getAllAnnotatedLineageClasses(constraintConfigurationClass, ConstraintConfiguration.class)) {
            List<Member> memberList = ConfigUtils.getDeclaredMembers(lineageClass);
            for (Member member : memberList) {
                if (member instanceof Method && potentiallyOverwritingMethodList.stream().anyMatch(
                        m -> member.getName().equals(m.getName()) // Short cut to discard negatives faster
                                && ReflectionHelper.isMethodOverwritten((Method) member, m.getDeclaringClass()))) {
                    // Ignore member because it is an overwritten method
                    continue;
                }
                processParameterAnnotation(descriptorPolicy, member, scoreDefinition);
            }
            potentiallyOverwritingMethodList.ensureCapacity(potentiallyOverwritingMethodList.size() + memberList.size());
            memberList.stream().filter(member -> member instanceof Method)
                    .forEach(member -> potentiallyOverwritingMethodList.add((Method) member));
        }
        if (constraintWeightDescriptorMap.isEmpty()) {
            throw new IllegalStateException("The constraintConfigurationClass (" + constraintConfigurationClass
                    + ") must have at least 1 member with a "
                    + ConstraintWeight.class.getSimpleName() + " annotation.");
        }
    }
public void processAnnotations(DescriptorPolicy descriptorPolicy, ScoreDefinition scoreDefinition) {
        processPackAnnotation(descriptorPolicy);
        ArrayList<Method> potentiallyOverwritingMethodList = new ArrayList<>();
        
        
        for (Class<?> lineageClass : ConfigUtils.getAllAnnotatedLineageClasses(constraintConfigurationClass, ConstraintConfiguration.class)) {
            List<Member> memberList = ConfigUtils.getDeclaredMembers(lineageClass);
            for (Member member : memberList) {
                if (member instanceof Method && potentiallyOverwritingMethodList.stream().anyMatch(
                        m -> member.getName().equals(m.getName()) 
                                && ReflectionHelper.isMethodOverwritten((Method) member, m.getDeclaringClass()))) {
                    
                    continue;
                }
                processParameterAnnotation(descriptorPolicy, member, scoreDefinition);
            }
            potentiallyOverwritingMethodList.ensureCapacity(potentiallyOverwritingMethodList.size() + memberList.size());
            memberList.stream().filter(member -> member instanceof Method)
                    .forEach(member -> potentiallyOverwritingMethodList.add((Method) member));
        }
        if (constraintWeightDescriptorMap.isEmpty()) {
            throw new IllegalStateException("The constraintConfigurationClass (" + constraintConfigurationClass
                    + ") must have at least 1 member with a "
                    + ConstraintWeight.class.getSimpleName() + " annotation.");
        }
    }
public void processAnnotations ( DescriptorPolicy descriptorPolicy , ScoreDefinition scoreDefinition ) { processPackAnnotation ( descriptorPolicy ) ; ArrayList < Method > potentiallyOverwritingMethodList = new ArrayList <> ( ) ; // Iterate inherited members too (unlike for EntityDescriptor where each one is declared) // to make sure each one is registered for ( Class < ? > lineageClass : ConfigUtils . getAllAnnotatedLineageClasses ( constraintConfigurationClass , ConstraintConfiguration . class ) ) { List < Member > memberList = ConfigUtils . getDeclaredMembers ( lineageClass ) ; for ( Member member : memberList ) { if ( member instanceof Method && potentiallyOverwritingMethodList . stream ( ) . anyMatch ( m -> member . getName ( ) . equals ( m . getName ( ) ) // Short cut to discard negatives faster && ReflectionHelper . isMethodOverwritten ( ( Method ) member , m . getDeclaringClass ( ) ) ) ) { // Ignore member because it is an overwritten method continue ; } processParameterAnnotation ( descriptorPolicy , member , scoreDefinition ) ; } potentiallyOverwritingMethodList . ensureCapacity ( potentiallyOverwritingMethodList . size ( ) + memberList . size ( ) ) ; memberList . stream ( ) . filter ( member -> member instanceof Method ) . forEach ( member -> potentiallyOverwritingMethodList . add ( ( Method ) member ) ) ; } if ( constraintWeightDescriptorMap . isEmpty ( ) ) { throw new IllegalStateException ( "The constraintConfigurationClass (" + constraintConfigurationClass + ") must have at least 1 member with a " + ConstraintWeight . class . getSimpleName ( ) + " annotation." ) ; } }
************************************************************************
************************************************************************