public static ClassPath createClassPath(String classPathString,String sysClassPathString,String extDirsString){
  Path path=new Path();
  if (sysClassPathString == null) {
    sysClassPathString=System.getProperty("sun.boot.class.path");
  }
  if (sysClassPathString != null) {
    path.addFiles(sysClassPathString);
  }
  path.expandJarClassPaths(true);
  if (extDirsString == null) {
    extDirsString=System.getProperty("java.ext.dirs");
  }
  if (extDirsString != null) {
    path.addDirectories(extDirsString);
  }
  path.emptyPathDefault(".");
  if (classPathString == null) {
    classPathString=System.getProperty("env.class.path");
    if (classPathString == null) {
      classPathString=".";
    }
  }
  path.addFiles(classPathString);
  return new ClassPath(path.toArray(new String[path.size()]));
}

public static ClassPath createClassPath ( String classPathString , String sysClassPathString , String extDirsString ) { Path path = new Path ( ) ; if ( sysClassPathString == null ) { sysClassPathString = System . getProperty ( "sun.boot.class.path" ) ; } if ( sysClassPathString != null ) { path . addFiles ( sysClassPathString ) ; } path . expandJarClassPaths ( true ) ; if ( extDirsString == null ) { extDirsString = System . getProperty ( "java.ext.dirs" ) ; } if ( extDirsString != null ) { path . addDirectories ( extDirsString ) ; } path . emptyPathDefault ( "." ) ; if ( classPathString == null ) { classPathString = System . getProperty ( "env.class.path" ) ; if ( classPathString == null ) { classPathString = "." ; } } path . addFiles ( classPathString ) ; return new ClassPath ( path . toArray ( new String [ path . size ( ) ] ) ) ; }
create a classpath object for rmic from the relevant command line options for class path , boot class path , and extension directories .
