public boolean exists ( String className ) { if ( this . classLoader != null ) { if ( exists ( className , this . classLoader ) ) { LOG . debug ( "class {} found using class specific class loader" , className ) ; return true ; } return false ; } if ( existsWithDefaultClassLoader ( className ) ) { LOG . debug ( "class {} found using default class loader" , className ) ; return true ; } if ( exists ( className , Thread . currentThread ( ) . getContextClassLoader ( ) ) ) { LOG . debug ( "class {} found using class loader of current thread" , className ) ; return true ; } if ( exists ( className , getClass ( ) . getClassLoader ( ) ) ) { LOG . debug ( "class {} found using class loader of current class" , className ) ; return true ; } return false ; }
Test if the class name is defined in the classpath .