|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.openstreetmap.josm.data.osm.visitor.AbstractVisitor
org.openstreetmap.josm.data.validation.Test
org.openstreetmap.josm.data.validation.tests.DuplicateRelation
public class DuplicateRelation
Tests if there are duplicate relations
Nested Class Summary | |
---|---|
private class |
DuplicateRelation.RelationMembers
|
private class |
DuplicateRelation.RelationPair
|
static class |
DuplicateRelation.RelMember
|
Field Summary | |
---|---|
protected static int |
DUPLICATE_RELATION
|
(package private) MultiMap<DuplicateRelation.RelationPair,OsmPrimitive> |
relations
MultiMap of all relations |
(package private) MultiMap<java.util.List<RelationMember>,OsmPrimitive> |
relations_nokeys
MultiMap of all relations, regardless of keys |
protected static int |
SAME_RELATION
|
Fields inherited from class org.openstreetmap.josm.data.validation.Test |
---|
checkBeforeUpload, checkEnabled, description, enabled, errors, isBeforeUpload, name, partialSelection, progressMonitor, testBeforeUpload |
Constructor Summary | |
---|---|
DuplicateRelation()
Constructor |
Method Summary | |
---|---|
void |
endTest()
Notification of the end of the test. |
Command |
fixError(TestError testError)
Fix the error by removing all but one instance of duplicate relations |
boolean |
isFixable(TestError testError)
Returns true if the given error can be fixed automatically |
void |
startTest(ProgressMonitor monitor)
Start the test using a given progress monitor |
void |
visit(Relation r)
Visiting call for relations. |
Methods inherited from class org.openstreetmap.josm.data.validation.Test |
---|
addGui, deletePrimitivesIfNeeded, getErrors, getName, initialize, isBuilding, isCanceled, ok, setBeforeUpload, setPartialSelection, testBeforeUpload, visit, visit, visit |
Methods inherited from class org.openstreetmap.josm.data.osm.visitor.AbstractVisitor |
---|
visit |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected static final int DUPLICATE_RELATION
protected static final int SAME_RELATION
MultiMap<DuplicateRelation.RelationPair,OsmPrimitive> relations
MultiMap<java.util.List<RelationMember>,OsmPrimitive> relations_nokeys
Constructor Detail |
---|
public DuplicateRelation()
Method Detail |
---|
public void startTest(ProgressMonitor monitor)
Test
startTest
in class Test
monitor
- the progress monitorpublic void endTest()
Test
If you override this method, don't forget to cleanup Test.progressMonitor
(most overrides call super.endTest()
to do this).
endTest
in class Test
public void visit(Relation r)
Visitor
visit
in interface Visitor
visit
in class Test
r
- The relation to inspect.public Command fixError(TestError testError)
fixError
in class Test
public boolean isFixable(TestError testError)
Test
isFixable
in class Test
testError
- The error to check if can be fixed
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |