public class MapCSSTagChecker extends Test.TagTest
| Modifier and Type | Class and Description |
|---|---|
static class |
MapCSSTagChecker.GroupedMapCSSRule
A grouped MapCSSRule with multiple selectors for a single declaration.
|
(package private) static class |
MapCSSTagChecker.MapCSSTagCheckerAndRule |
(package private) static class |
MapCSSTagChecker.TagCheck |
Test.TagTest| Modifier and Type | Field and Description |
|---|---|
(package private) MultiMap<java.lang.String,MapCSSTagChecker.TagCheck> |
checks |
static java.lang.String |
ENTRIES_PREF_KEY
The preference key for tag checker source entries.
|
checkBeforeUpload, checkEnabled, description, enabled, errors, isBeforeUpload, name, partialSelection, progressMonitor, startTime, testBeforeUpload| Constructor and Description |
|---|
MapCSSTagChecker()
Constructs a new
MapCSSTagChecker. |
| Modifier and Type | Method and Description |
|---|---|
void |
addMapCSS(java.lang.String url)
Adds a new MapCSS config file from the given URL.
|
void |
check(OsmPrimitive p)
Visiting call for primitives.
|
java.util.Set<java.lang.String> |
checkAsserts(java.util.Collection<MapCSSTagChecker.TagCheck> schecks)
Checks that rule assertions are met for the given set of TagChecks.
|
boolean |
equals(java.lang.Object obj) |
java.util.Collection<TestError> |
getErrorsForPrimitive(OsmPrimitive p,
boolean includeOtherSeverity)
|
private static java.util.Collection<TestError> |
getErrorsForPrimitive(OsmPrimitive p,
boolean includeOtherSeverity,
java.util.Collection<java.util.Set<MapCSSTagChecker.TagCheck>> checksCol) |
int |
hashCode() |
void |
initialize()
Initializes any global data used this tester.
|
visit, visit, visitaddGui, deletePrimitivesIfNeeded, endTest, fixError, getErrors, getName, isBuilding, isCanceled, isFixable, isPrimitiveUsable, ok, setBeforeUpload, setPartialSelection, startTest, testBeforeUpload, visitvisitpublic static final java.lang.String ENTRIES_PREF_KEY
final MultiMap<java.lang.String,MapCSSTagChecker.TagCheck> checks
public MapCSSTagChecker()
MapCSSTagChecker.public java.util.Collection<TestError> getErrorsForPrimitive(OsmPrimitive p, boolean includeOtherSeverity)
p - The OSM primitiveincludeOtherSeverity - if true, errors of severity Severity.OTHER (info) will also be returnedprivate static java.util.Collection<TestError> getErrorsForPrimitive(OsmPrimitive p, boolean includeOtherSeverity, java.util.Collection<java.util.Set<MapCSSTagChecker.TagCheck>> checksCol)
public void check(OsmPrimitive p)
check in class Test.TagTestp - The primitive to inspect.public void addMapCSS(java.lang.String url) throws ParseException, java.io.IOException
url - The unique URL of the MapCSS config fileParseException - if the config file does not match MapCSS syntaxjava.io.IOException - if any I/O error occurspublic void initialize() throws java.lang.Exception
Testinitialize in class Testjava.lang.Exception - When cannot initialize the testpublic java.util.Set<java.lang.String> checkAsserts(java.util.Collection<MapCSSTagChecker.TagCheck> schecks)
schecks - The TagChecks for which assertions have to be checked