|
Regain 2.1.0-STABLE API | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectnet.sf.regain.crawler.config.UrlMatcherResult
net.sf.regain.crawler.config.RegexUrlMatcher
public class RegexUrlMatcher
An UrlMatcher that matches URLs that match to a regular expression.
| Field Summary | |
|---|---|
private static org.apache.log4j.Logger |
mLog
The logger for this class. |
private java.util.regex.Pattern |
mUrlRegex
The regex a URL must match to in order to be matched by this matcher. |
private String |
mUrlRegexAsString
The regex as String. |
| Constructor Summary | |
|---|---|
RegexUrlMatcher(String regex,
boolean shouldBeParsed,
boolean shouldBeIndexed)
Creates a new instance of RegexUrlMatcher. |
|
| Method Summary | |
|---|---|
boolean |
matches(String url)
Checks whether a URL matches to the rules of this matcher. |
String |
toString()
Gets a String representation of this UrlMatcher. |
| Methods inherited from class net.sf.regain.crawler.config.UrlMatcherResult |
|---|
getShouldBeIndexed, getShouldBeParsed, setShouldBeIndexed, setShouldBeParsed |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
private static org.apache.log4j.Logger mLog
private String mUrlRegexAsString
private java.util.regex.Pattern mUrlRegex
| Constructor Detail |
|---|
public RegexUrlMatcher(String regex,
boolean shouldBeParsed,
boolean shouldBeIndexed)
throws RegainException
regex - The regular expression a URL must match to in order to be
matched by this matcher.
RegainException| Method Detail |
|---|
public boolean matches(String url)
matches in interface UrlMatchermatches in class UrlMatcherResulturl - The URL to check.
public String toString()
toString in class Object
|
Regain 2.1.0-STABLE API | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||