|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.gjt.rec.io.FilePath
Parses a classpath or sourcepath separated by the path seperator for the platform (typically either colon or semicolon) into a list of path elements, which can be folders, JAR files or ZIP files. When a path element does not exist, its type will be guessed. If the file name ends with ".zip" or ".jar", it will be guessed as a ZIP or a JAR respectively and a directory otherwise. Should the path element become available, its type will be inspected properly.
Nested Class Summary | |
static class |
FilePath.PathElement
Represents a single element of a FilePath. |
Field Summary | |
static String |
COPYRIGHT
|
static String |
LICENSE
|
static String |
REVISION
|
Constructor Summary | |
FilePath(String pathString)
Constructs a new FilePath from a particular path string but using the default element separator for the platform. |
|
FilePath(String pathString,
String elementSeperator)
Constructs a new FilePath from a particular path string and a particular path element separator. |
Method Summary | |
boolean |
equals(Object obj)
|
FilePath.PathElement |
get(int index)
Returns a particular element from this path. |
int |
hashCode()
|
int |
size()
Returns the number of elements in this path. |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final String COPYRIGHT
public static final String LICENSE
public static final String REVISION
Constructor Detail |
public FilePath(String pathString)
pathString
- the path string to be parsed
NullPointerException
- if (pathString) is nullpublic FilePath(String pathString, String elementSeperator)
pathString
- the path string to be parsedelementSeperator
- the character or characters that constitute a
delimiter between elements
NullPointerException
- if either argument is nullMethod Detail |
public int size()
public FilePath.PathElement get(int index)
index
- the index of the element to return
IndexOutOfBoundsException
- if index is out of bounds
(index < 0 || size() <=
index)public int hashCode()
hashCode
in class Object
public boolean equals(Object obj)
equals
in class Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |