Added toString() methods for better debugging of ignore rules

Change-Id: Ie31687faa2df47ecaacace2504c3b4e93f1ea809
Signed-off-by: Andrey Loskutov <loskutov@gmx.de>
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
This commit is contained in:
Andrey Loskutov 2014-07-30 10:38:53 +02:00 committed by Matthias Sohn
parent 7ff1e0d8f5
commit 0307123e5a
3 changed files with 15 additions and 0 deletions

View File

@ -57,4 +57,9 @@ protected final boolean matches(final char c) {
return c == expectedCharacter; return c == expectedCharacter;
} }
@Override
public String toString() {
return String.valueOf(expectedCharacter);
}
} }

View File

@ -56,4 +56,9 @@ final class RestrictedWildCardHead extends AbstractHead {
protected final boolean matches(final char c) { protected final boolean matches(final char c) {
return c != excludedCharacter; return c != excludedCharacter;
} }
@Override
public String toString() {
return isStar() ? "*" : "?"; //$NON-NLS-1$ //$NON-NLS-2$
}
} }

View File

@ -255,4 +255,9 @@ private boolean doesMatchDirectoryExpectations(boolean isDirectory, int segmentI
// We are checking the last part of the segment for which isDirectory has to be considered. // We are checking the last part of the segment for which isDirectory has to be considered.
return !dirOnly || isDirectory; return !dirOnly || isDirectory;
} }
@Override
public String toString() {
return pattern;
}
} }