question: public static InheritanceTree createFromClassList ( Collection < String > classNames ) throws IllegalArgumentException { if ( classNames == null || classNames . isEmpty ( ) ) { throw new IllegalArgumentException ( "No class name defined" ) ; } InheritanceTree inheritanceTree = new InheritanceTree ( ) ; for ( String className : classNames ) { if ( className == null ) { throw new IllegalArgumentException ( "Null class name" ) ; } analyzeClassName ( inheritanceTree , className ) ; } Set < String > classes = new HashSet < > ( inheritanceTree . getAllClasses ( ) ) ; for ( String className : classes ) { if ( ! classNames . contains ( className ) ) inheritanceTree . removeClass ( className ) ; } return inheritanceTree ; }
target:  Create inheritance tree only for the classes passed as parameter <p> Private classes will be ignored