public class PackagePath extends java.lang.Object implements java.util.Comparator<PackagePath>
Constructor and Description |
---|
PackagePath(java.lang.String path)
Constructor.
|
PackagePath(java.lang.String path,
java.util.Set<java.lang.String> excludedClasses)
Constructor.
|
PackagePath(java.lang.String path,
java.lang.String... excludedClasses)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
int |
compare(PackagePath o1,
PackagePath o2) |
static java.util.Set<PackagePath> |
createPackagePaths(java.util.Set<java.lang.String> paths)
Creates a set of package paths from a Set of paths as strings.
|
static java.util.Set<PackagePath> |
createPackagePaths(java.util.Set<java.lang.String> paths,
java.util.Set<java.lang.String> excludedClasses)
Creates a set of package paths from a Set of paths as strings.
|
static java.util.Set<PackagePath> |
createPackagePathsFromArray(java.util.Set<java.lang.String> excludedClasses,
java.lang.String... paths)
Creates a set of package paths from an array.
|
static java.util.Set<PackagePath> |
createPackagePathsFromArray(java.lang.String... paths)
Creates a set of package paths from an array.
|
boolean |
equals(java.lang.Object obj) |
void |
excludeClass(java.lang.String classpath)
Excludes a class fropm the package.
|
java.util.Set<java.lang.String> |
getExcludedClasses()
Return the Set fo excluded classes.
|
java.lang.String |
getPackageName()
The package name
|
java.lang.String |
getPath()
The package path.
|
int |
hashCode() |
boolean |
isExcludingClass(java.lang.String classpath)
Return true if a class is excluded.
|
boolean |
isPackageName()
Return true if if represents a package.
|
java.lang.String |
toString() |
public PackagePath(java.lang.String path)
path
- the pathpublic PackagePath(java.lang.String path, java.lang.String... excludedClasses)
path
- the pathexcludedClasses
- a list of classes excluded from the packagepublic PackagePath(java.lang.String path, java.util.Set<java.lang.String> excludedClasses)
path
- the pathexcludedClasses
- a set of classes excluded from the packagepublic static java.util.Set<PackagePath> createPackagePathsFromArray(java.lang.String... paths)
paths
- the arraypublic static java.util.Set<PackagePath> createPackagePaths(java.util.Set<java.lang.String> paths)
paths
- the Set of pathspublic static java.util.Set<PackagePath> createPackagePathsFromArray(java.util.Set<java.lang.String> excludedClasses, java.lang.String... paths)
excludedClasses
- a set of excluded classespaths
- the arraypublic static java.util.Set<PackagePath> createPackagePaths(java.util.Set<java.lang.String> paths, java.util.Set<java.lang.String> excludedClasses)
paths
- the Set of pathsexcludedClasses
- a set of excluded classespublic java.lang.String getPath()
public java.lang.String getPackageName()
public boolean isPackageName()
public void excludeClass(java.lang.String classpath)
classpath
- the class classpathpublic java.util.Set<java.lang.String> getExcludedClasses()
public boolean isExcludingClass(java.lang.String classpath)
classpath
- the class classpathpublic java.lang.String toString()
toString
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public boolean equals(java.lang.Object obj)
equals
in interface java.util.Comparator<PackagePath>
equals
in class java.lang.Object
public int compare(PackagePath o1, PackagePath o2)
compare
in interface java.util.Comparator<PackagePath>
Copyright © 2016-2023 Herve Girod. All Rights Reserved. Documentation and source under the LGPL licence