|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.apache.maven.plugin.war.util.PathSet
Set of file's paths.
The class extends functionality of a "normal" set of strings by a process of the paths normalization. All paths are converted to unix form (slashes) and they don't start with starting /.
| Constructor Summary | |
PathSet()
Creates an empty paths set |
|
PathSet(java.util.Collection paths)
Creates paths set and normalizate and adds all 'paths'. |
|
PathSet(java.lang.String[] paths)
Creates paths set and normalizate and adds all 'paths'. |
|
| Method Summary | |
void |
add(java.lang.String path)
Normalizes and adds given path to the set. |
void |
addAll(java.util.Collection paths)
Normalizes and adds given paths (collection of strings) to the set. |
void |
addAll(java.util.Collection paths,
java.lang.String prefix)
Normalizes and adds given paths (collection of strings) to the set. |
void |
addAll(PathSet paths)
Adds given paths to the set. |
void |
addAll(PathSet paths,
java.lang.String prefix)
Adds given paths to the set. |
void |
addAll(java.lang.String[] paths)
Normalizes and adds given paths to the set. |
void |
addAll(java.lang.String[] paths,
java.lang.String prefix)
Normalizes and adds given paths to the set. |
void |
addAllFilesInDirectory(java.io.File directory,
java.lang.String prefix)
Adds to the set all files in the given directory |
void |
addPrefix(java.lang.String prefix)
Adds given prefix to all paths in the set. |
boolean |
contains(java.lang.String path)
Checks if the set constains given path. |
java.util.Iterator |
iterator()
Returns iterator of normalized paths (strings) |
protected java.lang.String |
normalizeFilePath(java.lang.String path)
The method normalizes the path. |
static java.lang.String |
normalizeFilePathStatic(java.lang.String path)
The method normalizes the path. |
int |
size()
Returns count of the paths in the set |
static java.lang.String |
trimTrailingSlashes(java.lang.String str)
The method deletes all trailing slashes from the given string |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public PathSet()
public PathSet(java.util.Collection paths)
paths - to be addedpublic PathSet(java.lang.String[] paths)
paths - to be added| Method Detail |
protected java.lang.String normalizeFilePath(java.lang.String path)
path - to normalization
public void add(java.lang.String path)
path - to be added
public void addAll(java.util.Collection paths,
java.lang.String prefix)
paths - - collection of strings to be addedprefix - added to all given paths
public void addAll(java.lang.String[] paths,
java.lang.String prefix)
paths - to be addedprefix - added to all given paths
public void addAll(PathSet paths,
java.lang.String prefix)
paths - to be addedprefix - added to all given pathspublic void addAll(java.util.Collection paths)
paths - - collection of strings to be addedpublic void addAll(java.lang.String[] paths)
paths - to be addedpublic void addAll(PathSet paths)
paths - to be addedpublic boolean contains(java.lang.String path)
path - we are looking for in the set.
public java.util.Iterator iterator()
public void addPrefix(java.lang.String prefix)
prefix - to be added to all itemspublic int size()
public void addAllFilesInDirectory(java.io.File directory,
java.lang.String prefix)
directory - that will be searched for file's paths to addprefix - to be added to all found filespublic static java.lang.String normalizeFilePathStatic(java.lang.String path)
path - to normalization
public static java.lang.String trimTrailingSlashes(java.lang.String str)
str - a string
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||