Package org.jboss.shrinkwrap.api
Class Filters
- java.lang.Object
-
- org.jboss.shrinkwrap.api.Filters
-
public final class Filters extends java.lang.ObjectFactory class for the creation of newFilterinstances. Filter instances using this shorthand class will be created using theClassLoaderassociated with the defaultDomain'sConfiguration.- Version:
- $Revision: $
-
-
Field Summary
Fields Modifier and Type Field Description private static java.lang.StringIMPL_CLASS_NAME_EXCLUDE_PATHSprivate static java.lang.StringIMPL_CLASS_NAME_EXCLUDE_REGEXP_PATHSprivate static java.lang.StringIMPL_CLASS_NAME_INCLUDE_ALL_PATHSprivate static java.lang.StringIMPL_CLASS_NAME_INCLUDE_PATHSprivate static java.lang.StringIMPL_CLASS_NAME_INCLUDE_REGEXP_PATHS
-
Constructor Summary
Constructors Modifier Constructor Description privateFilters()No instantiation
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description private static Filter<ArchivePath>createRegExpFilter(java.lang.String regExpFilterImplName, java.lang.Class<?>... classes)private static Filter<ArchivePath>createRegExpFilter(java.lang.String filterClassName, java.lang.Package... packages)static Filter<ArchivePath>exclude(java.lang.Class<?>... classes)Filterthat excludes listedClass.static Filter<ArchivePath>exclude(java.lang.Package... packages)Filterthat includes listedPackage.static Filter<ArchivePath>exclude(java.lang.String regexp)static Filter<ArchivePath>excludePaths(java.lang.String... paths)Filterthat exclude allArchivePaths that match the given List of paths.static Filter<ArchivePath>excludePaths(java.util.Collection<java.lang.String> paths)Filterthat exclude allArchivePaths that match the given List of paths.private static Filter<ArchivePath>getFilterInstance(java.lang.String filterClassName, java.lang.Class<?>[] ctorTypes, java.lang.Object[] ctorArguments)Creates a newFilterinstance using the given impl class name, constructor arguments and typestatic Filter<ArchivePath>include(java.lang.Class<?>... classes)Filterthat includes listedClass.static Filter<ArchivePath>include(java.lang.Package... packages)Filterthat excludes listedPackage.static Filter<ArchivePath>include(java.lang.String regexp)static Filter<ArchivePath>includeAll()Filterthat includes allArchivePaths.static Filter<ArchivePath>includePaths(java.lang.String... paths)Filerthat include allArchivePaths that match the given List of paths..static Filter<ArchivePath>includePaths(java.util.Collection<java.lang.String> paths)Filerthat include allArchivePaths that match the given List of paths..
-
-
-
Field Detail
-
IMPL_CLASS_NAME_INCLUDE_ALL_PATHS
private static final java.lang.String IMPL_CLASS_NAME_INCLUDE_ALL_PATHS
- See Also:
- Constant Field Values
-
IMPL_CLASS_NAME_INCLUDE_REGEXP_PATHS
private static final java.lang.String IMPL_CLASS_NAME_INCLUDE_REGEXP_PATHS
- See Also:
- Constant Field Values
-
IMPL_CLASS_NAME_EXCLUDE_REGEXP_PATHS
private static final java.lang.String IMPL_CLASS_NAME_EXCLUDE_REGEXP_PATHS
- See Also:
- Constant Field Values
-
IMPL_CLASS_NAME_INCLUDE_PATHS
private static final java.lang.String IMPL_CLASS_NAME_INCLUDE_PATHS
- See Also:
- Constant Field Values
-
IMPL_CLASS_NAME_EXCLUDE_PATHS
private static final java.lang.String IMPL_CLASS_NAME_EXCLUDE_PATHS
- See Also:
- Constant Field Values
-
-
Method Detail
-
includeAll
public static Filter<ArchivePath> includeAll()
Filterthat includes allArchivePaths. Only meant to be used internally.- Returns:
- A
Filterthat always return true
-
include
public static Filter<ArchivePath> include(java.lang.String regexp)
- Parameters:
regexp- The expression to include- Returns:
- A Regular Expression based include
Filter
-
exclude
public static Filter<ArchivePath> exclude(java.lang.String regexp)
- Parameters:
regexp- The expression to exclude- Returns:
- A Regular Expression based exclude
Filter
-
includePaths
public static Filter<ArchivePath> includePaths(java.lang.String... paths)
Filerthat include allArchivePaths that match the given List of paths..- Parameters:
paths- The paths to included- Returns:
- A Path list based include
Filter
-
includePaths
public static Filter<ArchivePath> includePaths(java.util.Collection<java.lang.String> paths)
Filerthat include allArchivePaths that match the given List of paths..- Parameters:
paths- The paths to included- Returns:
- A Path list based include
Filter
-
excludePaths
public static Filter<ArchivePath> excludePaths(java.lang.String... paths)
Filterthat exclude allArchivePaths that match the given List of paths.- Parameters:
paths- The paths to exclude- Returns:
- A Path list based exclude
Filter
-
excludePaths
public static Filter<ArchivePath> excludePaths(java.util.Collection<java.lang.String> paths)
Filterthat exclude allArchivePaths that match the given List of paths.- Parameters:
paths- The paths to exclude- Returns:
- A Path list based exclude
Filter
-
exclude
public static Filter<ArchivePath> exclude(java.lang.Package... packages)
Filterthat includes listedPackage.- Parameters:
packages- To be included- Returns:
-
include
public static Filter<ArchivePath> include(java.lang.Package... packages)
Filterthat excludes listedPackage.- Parameters:
packages- To be excluded- Returns:
-
createRegExpFilter
private static Filter<ArchivePath> createRegExpFilter(java.lang.String filterClassName, java.lang.Package... packages)
-
include
public static Filter<ArchivePath> include(java.lang.Class<?>... classes)
Filterthat includes listedClass.- Parameters:
classes- To be included- Returns:
-
exclude
public static Filter<ArchivePath> exclude(java.lang.Class<?>... classes)
Filterthat excludes listedClass.- Parameters:
classes- To be excluded- Returns:
-
createRegExpFilter
private static Filter<ArchivePath> createRegExpFilter(java.lang.String regExpFilterImplName, java.lang.Class<?>... classes)
-
getFilterInstance
private static Filter<ArchivePath> getFilterInstance(java.lang.String filterClassName, java.lang.Class<?>[] ctorTypes, java.lang.Object[] ctorArguments)
Creates a newFilterinstance using the given impl class name, constructor arguments and type- Parameters:
filterClassName-ctorTypes-ctorArguments-- Returns:
-
-