Class InstrumentationAwareReflectionUtils


  • public final class InstrumentationAwareReflectionUtils
    extends Object
    • Constructor Detail

      • InstrumentationAwareReflectionUtils

        public InstrumentationAwareReflectionUtils()
    • Method Detail

      • getAllNonSyntheticFieldsList

        public static List<Field> getAllNonSyntheticFieldsList​(Class<?> cls)
        Gets all non synthetic fields of the given class and its parents (if any). Frameworks like jacoco add synthetic fields for internal usage. This method can be used instead of FieldUtils.getAllFieldsList to avoid clashes with such fields
        Parameters:
        cls - the Class to query
        Returns:
        an array of Fields (possibly empty).
        Throws:
        IllegalArgumentException - if the class is null