/** * This method scans the supplied class for PrettyFaces annotations. The method must be called for * every class that should be scanner before finally calling {@link #build(PrettyConfigBuilder)}. * * @param clazz The class to scan */ public void processClass(final Class clazz) { // log class name on trace level if (log.isTraceEnabled()) { log.trace("Analyzing class: " + clazz.getName()); } try { // scan for PrettyAnnotation class // returns the mapping ID, if an annotation was found String[] classMappingIds = processClassMappingAnnotations(clazz); // scan for PrettyBean annotation processPrettyBeanAnnotation(clazz); // process annotations on public methods for (Method method : clazz.getMethods()) { processMethodAnnotations(method, classMappingIds); } // loop over fields to find URLQueryParameter annotations for (Field field : clazz.getDeclaredFields()) { processFieldAnnotations(field, classMappingIds); } } catch (NoClassDefFoundError e) { // reference to another class unknown to the classloader log.debug("Unable to process class '" + clazz.getName() + "': " + e.toString()); } }