Package org.openstreetmap.josm.actions
Class UploadSelectionAction.UploadHullBuilder
java.lang.Object
org.openstreetmap.josm.actions.UploadSelectionAction.UploadHullBuilder
- All Implemented Interfaces:
OsmPrimitiveVisitor
- Enclosing class:
- UploadSelectionAction
Computes the collection of primitives to upload, given a collection of candidate
primitives.
Some of the candidates are excluded, i.e. if they aren't modified.
Other primitives are added. A typical case is a primitive which is new and and
which is referred by a modified relation. In order to upload the relation the
new primitive has to be uploaded as well, even if it isn't included in the
list of candidate primitives.
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild(Collection<OsmPrimitive> base) Builds the "hull" of primitives to be uploaded given a base collection of osm primitives.voidVisiting call for points.voidVisiting call for relations.voidVisiting call for lines.
-
Field Details
-
hull
-
-
Constructor Details
-
UploadHullBuilder
-
-
Method Details
-
visit
Description copied from interface:OsmPrimitiveVisitorVisiting call for points.- Specified by:
visitin interfaceOsmPrimitiveVisitor- Parameters:
n- The node to inspect.
-
visit
Description copied from interface:OsmPrimitiveVisitorVisiting call for lines.- Specified by:
visitin interfaceOsmPrimitiveVisitor- Parameters:
w- The way to inspect.
-
visit
Description copied from interface:OsmPrimitiveVisitorVisiting call for relations.- Specified by:
visitin interfaceOsmPrimitiveVisitor- Parameters:
r- The relation to inspect.
-
build
Builds the "hull" of primitives to be uploaded given a base collection of osm primitives.- Parameters:
base- the base collection. Must not be null.- Returns:
- the "hull"
- Throws:
IllegalArgumentException- if base is null
-