private static class PrimitiveTagTransferPaster.TagPasteSupport extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
private PrimitiveTagTransferData |
data |
private java.util.Collection<? extends IPrimitive> |
selection |
private java.util.List<Tag> |
tags |
Constructor and Description |
---|
TagPasteSupport(PrimitiveTagTransferData data,
java.util.Collection<? extends IPrimitive> selection)
Constructs a new
TagPasteSupport . |
Modifier and Type | Method and Description |
---|---|
protected void |
buildTags(TagCollection tc) |
protected boolean |
canPasteFromHeterogeneousSourceWithoutConflict()
Replies true if this a heterogeneous source can be pasted without conflict to targets
|
java.util.List<Tag> |
execute()
Performs the paste operation.
|
protected java.util.Map<OsmPrimitiveType,java.lang.Integer> |
getTargetStatistics() |
protected boolean |
hasTargetPrimitives(OsmPrimitiveType type)
Replies true if there is at least one primitive of type
type
is in the target collection |
protected void |
pasteFromHeterogeneousSource()
Pastes the tags in the current selection of the paste buffer to a set of target primitives.
|
protected void |
pasteFromHomogeneousSource()
Pastes the tags from a homogeneous source (the selection consisting
of one type of
OsmPrimitive s only). |
java.lang.String |
toString() |
private final PrimitiveTagTransferData data
private final java.util.Collection<? extends IPrimitive> selection
TagPasteSupport(PrimitiveTagTransferData data, java.util.Collection<? extends IPrimitive> selection)
TagPasteSupport
.data
- source tags to pasteselection
- target primitivesprotected void pasteFromHomogeneousSource()
OsmPrimitive
s only).
Tags from a homogeneous source can be pasted to a heterogeneous target. All target primitives,
regardless of their type, receive the same tags.protected boolean canPasteFromHeterogeneousSourceWithoutConflict()
protected void pasteFromHeterogeneousSource()
protected java.util.Map<OsmPrimitiveType,java.lang.Integer> getTargetStatistics()
protected boolean hasTargetPrimitives(OsmPrimitiveType type)
type
is in the target collectiontype
- the type to look fortype
in the collection
selection
protected void buildTags(TagCollection tc)
public java.lang.String toString()
toString
in class java.lang.Object