public class Classpath extends Object
| Modifier and Type | Class and Description | 
|---|---|
| static class  | Classpath.SessionRepresents a session of  Classpath. | 
| Constructor and Description | 
|---|
| Classpath() | 
| Modifier and Type | Method and Description | 
|---|---|
| Classpath | add(Path entry,
   boolean mandatory)Adds an entry into this classpath. | 
| Classpath | addEntries(Path directory,
          boolean mandatory)Adds entries in the given directory into this classpath. | 
| void | exec(ClassLoader base,
    String className,
    String... args)Executes the given main class. | 
| Classpath.Session | session(ClassLoader base)Returns a new classpath session. | 
| String | toString() | 
public Classpath add(Path entry, boolean mandatory)
entry - the target file or directorymandatory - true if it is mandatory, otherwise falseIllegalStateException - if the mandatory entry is not foundpublic Classpath addEntries(Path directory, boolean mandatory)
directory - the target directorymandatory - true if it is mandatory, otherwise falseIllegalStateException - if the mandatory directory is not foundpublic void exec(ClassLoader base, String className, String... args)
base - the base class loaderclassName - the main class nameargs - the program argumentsIllegalStateException - if error occurred while running main classpublic Classpath.Session session(ClassLoader base)
base - the base class loaderCopyright © 2011–2019 Asakusa Framework Team. All rights reserved.