public static void findClasspathOrder(final ClassLoader classLoader, final ClasspathOrder classpathOrder,
            final ScanSpec scanSpec, final LogNode log) {
        Object smartClassPath;
        final Object appLoader = ReflectionUtils.getFieldVal(classLoader, "appLoader", false);
        if (appLoader != null) {
            smartClassPath = ReflectionUtils.getFieldVal(appLoader, "smartClassPath", false);
        } else {
            smartClassPath = ReflectionUtils.getFieldVal(classLoader, "smartClassPath", false);
        }
        if (smartClassPath != null) {
            final List<?> classPathElements = (List<?>) ReflectionUtils.getFieldVal(smartClassPath, "classPath",
                    false);
            if (classPathElements != null) {
                for (final Object classpath : classPathElements) {
                    final String path = getPath(classpath);
                    if (path != null && path.length() > 0) {
                        classpathOrder.addClasspathEntry(path, classLoader, scanSpec, log);
                    }
                }
            }
        }
    }
public static void findClasspathOrder ( final ClassLoader classLoader , final ClasspathOrder classpathOrder , final ScanSpec scanSpec , final LogNode log ) { Object smartClassPath ; final Object appLoader = ReflectionUtils . getFieldVal ( classLoader , "appLoader" , false ) ; if ( appLoader != null ) { smartClassPath = ReflectionUtils . getFieldVal ( appLoader , "smartClassPath" , false ) ; } else { smartClassPath = ReflectionUtils . getFieldVal ( classLoader , "smartClassPath" , false ) ; } if ( smartClassPath != null ) { final List < ? > classPathElements = ( List < ? > ) ReflectionUtils . getFieldVal ( smartClassPath , "classPath" , false ) ; if ( classPathElements != null ) { for ( final Object classpath : classPathElements ) { final String path = getPath ( classpath ) ; if ( path != null && path . length ( ) > 0 ) { classpathOrder . addClasspathEntry ( path , classLoader , scanSpec , log ) ; } } } } }
Find the classpath entries for the associated {@link ClassLoader}.

@param classLoader
the {@link ClassLoader} to find the classpath entries order for.
@param classpathOrder
a {@link ClasspathOrder} object to update.
@param scanSpec
the {@link ScanSpec}.
@param log
the log.