public abstract class ClassFilter extends Object
| Modifier and Type | Class and Description |
|---|---|
static class |
ClassFilter.ClassFilterException
Class for propagating exceptions in
ClassFilter. |
| Modifier and Type | Field and Description |
|---|---|
static ClassFilter |
DEFAULT
A set of sensible default filtering rules to apply,
unless the context guarantees the trust between two channels.
|
static String |
FILE_OVERRIDE_LOCATION_PROPERTY
Property to set to override the blacklist used by {
DEFAULT with a different set. |
static ClassFilter |
NONE
No filtering whatsoever.
|
| Constructor and Description |
|---|
ClassFilter() |
| Modifier and Type | Method and Description |
|---|---|
static void |
appendDefaultFilter(Pattern filter)
Adds an additional exclusion to
DEFAULT. |
Class |
check(Class c) |
String |
check(String name) |
protected boolean |
isBlacklisted(Class c) |
protected boolean |
isBlacklisted(String name) |
public static final String FILE_OVERRIDE_LOCATION_PROPERTY
DEFAULT with a different set.
The location should point to a a file containing regular expressions (one per line) of classes to blacklist.
If this property is set but the file can not be read the default blacklist will be used.public static final ClassFilter DEFAULT
public static final ClassFilter NONE
protected boolean isBlacklisted(String name)
protected boolean isBlacklisted(Class c)
public static void appendDefaultFilter(Pattern filter) throws ClassFilter.ClassFilterException
DEFAULT.
Does nothing if the default list has already been customized via FILE_OVERRIDE_LOCATION_PROPERTY.
This API is not supposed to be used anywhere outside Jenkins core, calls for other sources may be rejected later.filter - a regular expression for Class.getName() which, if matched according to Matcher.matches(), will blacklist the classClassFilter.ClassFilterException - Filter pattern cannot be applied.
It means either unexpected processing error or rejection by the internal logic.Copyright © 2004–2017. All rights reserved.