Ignore:
Timestamp:
2017-09-04T23:45:49+02:00 (8 years ago)
Author:
Don-vip
Message:

see #13036 - deprecate Command() default constructor, fix unit tests and java warnings

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/command/MoveCommand.java

    r12348 r12726  
    99import java.util.LinkedList;
    1010import java.util.List;
     11import java.util.NoSuchElementException;
    1112import java.util.Objects;
    1213
     
    8485    /**
    8586     * Constructs a new {@code MoveCommand} and assign the initial object set and movement vector.
    86      * @param objects The primitives to move
     87     * @param objects The primitives to move. Must neither be null nor empty. Objects must belong to a data set
    8788     * @param x X difference movement. Coordinates are in northern/eastern
    8889     * @param y Y difference movement. Coordinates are in northern/eastern
     90     * @throws NullPointerException if objects is null or contain null item
     91     * @throws NoSuchElementException if objects is empty
    8992     */
    9093    public MoveCommand(Collection<OsmPrimitive> objects, double x, double y) {
     94        super(objects.iterator().next().getDataSet());
    9195        startEN = null;
    9296        saveCheckpoint(); // (0,0) displacement will be saved
Note: See TracChangeset for help on using the changeset viewer.