Class PatternURLFilter
- java.lang.Object
-
- org.codehaus.mojo.jaxb2.shared.filters.AbstractFilter<T>
-
- org.codehaus.mojo.jaxb2.shared.filters.pattern.AbstractPatternFilter<java.net.URL>
-
- org.codehaus.mojo.jaxb2.shared.filters.pattern.PatternURLFilter
-
- All Implemented Interfaces:
Filter<java.net.URL>
public class PatternURLFilter extends AbstractPatternFilter<java.net.URL>
AbstractPatternFilter matching the string of URLs with to a set of Regular expressions.- Since:
- 2.0
-
-
Field Summary
Fields Modifier and Type Field Description static StringConverter<java.net.URL>
NORMALIZED_URL_CONVERTER
Converter returning each URL'stoString()
form, after normalizing it, using the algorithmtoConvert.toURI().normalize().toURL().toString();
-
Fields inherited from class org.codehaus.mojo.jaxb2.shared.filters.AbstractFilter
log, TOSTRING_INDENT
-
-
Constructor Summary
Constructors Constructor Description PatternURLFilter(boolean processNullValues, java.lang.String patternPrefix, java.util.List<java.lang.String> patterns, StringConverter<java.net.URL> converter, boolean acceptCandidateOnPatternMatch)
Compound constructor creating an ExclusionRegularExpressionURLFilter from the supplied parameters.PatternURLFilter(java.util.List<java.lang.String> patternStrings)
Creates a new ExclusionRegularExpressionURLFilter using the supplied patternStrings which are matched against each full - normalized - URL.
-
Method Summary
-
Methods inherited from class org.codehaus.mojo.jaxb2.shared.filters.pattern.AbstractPatternFilter
convert, convert, onCandidate, onInitialize, setAcceptCandidateOnPatternMatch, setConverter, setPatternPrefix, setPatterns, toString
-
Methods inherited from class org.codehaus.mojo.jaxb2.shared.filters.AbstractFilter
accept, addDelayedLogMessage, initialize, isInitialized, onNullCandidate, setProcessNullValues, validateDiSetterCalledBeforeInitialization
-
-
-
-
Field Detail
-
NORMALIZED_URL_CONVERTER
public static final StringConverter<java.net.URL> NORMALIZED_URL_CONVERTER
Converter returning each URL'stoString()
form, after normalizing it, using the algorithmtoConvert.toURI().normalize().toURL().toString();
-
-
Constructor Detail
-
PatternURLFilter
public PatternURLFilter(java.util.List<java.lang.String> patternStrings)
Creates a new ExclusionRegularExpressionURLFilter using the supplied patternStrings which are matched against each full - normalized - URL. TheNORMALIZED_URL_CONVERTER
is used to convert URLs to strings.- Parameters:
patternStrings
- The list of patternStrings to be used as regular expression matchers against the normalized URLs.- See Also:
NORMALIZED_URL_CONVERTER
,AbstractPatternFilter.convert(java.util.List, String)
-
PatternURLFilter
public PatternURLFilter(boolean processNullValues, java.lang.String patternPrefix, java.util.List<java.lang.String> patterns, StringConverter<java.net.URL> converter, boolean acceptCandidateOnPatternMatch)
Compound constructor creating an ExclusionRegularExpressionURLFilter from the supplied parameters.- Parameters:
processNullValues
- iftrue
, this ExclusionRegularExpressionURLFilter process null candidate values.patternPrefix
- a prefix to be prepended to any patterns submitted to this PatternURLFilter.patterns
- The non-null list of Patters which should be applied within this ExclusionRegularExpressionURLFilter. A candidate of type T should only be accepted by this ExclusionRegularExpressionURLFilter if all supplied patterns matchAtLeastOnce the candidate.converter
- The StringConverter used to convert T-type objects to Strings which should be matched by all supplied Patterns to T-object candidates.acceptCandidateOnPatternMatch
- iftrue
, this ExclusionRegularExpressionURLFilter will matchAtLeastOnce candidate objects that match at least one of the supplied patterns. iffalse
, this ExclusionRegularExpressionURLFilter will noFilterMatches candidates that match at least one of the supplied patterns.
-
-