Ignore:
Timestamp:
2016-03-07T21:45:35+01:00 (4 years ago)
Author:
Don-vip
Message:

remove deprecated stuff, code cleanup, javadoc, unit tests

Location:
trunk/src/org/openstreetmap/josm/data/gpx
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/data/gpx/GpxTrack.java

    r8510 r9949  
    99/**
    1010 * Read-only gpx track. Implementations doesn't have to be immutable, but should always be thread safe.
    11  *
     11 * @since 444
    1212 */
    1313public interface GpxTrack extends IWithAttributes {
    1414
     15    /**
     16     * Returns the track segments.
     17     * @return the track segments
     18     */
    1519    Collection<GpxTrackSegment> getSegments();
    1620
     21    /**
     22     * Returns the track attributes.
     23     * @return the track attributes
     24     */
    1725    Map<String, Object> getAttributes();
    1826
     27    /**
     28     * Returns the track bounds.
     29     * @return the track bounds
     30     */
    1931    Bounds getBounds();
    2032
     33    /**
     34     * Returns the track length.
     35     * @return the track length
     36     */
    2137    double length();
    2238
    2339    /**
    24      *
     40     * Returns the number of times this track has been changed.
    2541     * @return Number of times this track has been changed. Always 0 for read-only tracks
    2642     */
  • trunk/src/org/openstreetmap/josm/data/gpx/GpxTrackSegment.java

    r8510 r9949  
    88/**
    99 * Read-only gpx track segments. Implementations doesn't have to be immutable, but should always be thread safe.
    10  *
     10 * @since 2907
    1111 */
    1212public interface GpxTrackSegment {
    1313
     14    /**
     15     * Returns the segment bounds.
     16     * @return the segment bounds
     17     */
    1418    Bounds getBounds();
    1519
     20    /**
     21     * Returns the segment waypoints.
     22     * @return the segment waypoints
     23     */
    1624    Collection<WayPoint> getWayPoints();
    1725
     26    /**
     27     * Returns the segment length.
     28     * @return the segment length
     29     */
    1830    double length();
    1931
    2032    /**
    21      *
     33     * Returns the number of times this track has been changed
    2234     * @return Number of times this track has been changed. Always 0 for read-only segments
    2335     */
  • trunk/src/org/openstreetmap/josm/data/gpx/ImmutableGpxTrack.java

    r8510 r9949  
    1111import org.openstreetmap.josm.data.Bounds;
    1212
     13/**
     14 * Immutable GPX track.
     15 * @since 2907
     16 */
    1317public class ImmutableGpxTrack extends WithAttributes implements GpxTrack {
    1418
     
    1721    private final Bounds bounds;
    1822
     23    /**
     24     * Constructs a new {@code ImmutableGpxTrack}.
     25     * @param trackSegs track segments
     26     * @param attributes track attributes
     27     */
    1928    public ImmutableGpxTrack(Collection<Collection<WayPoint>> trackSegs, Map<String, Object> attributes) {
    2029        List<GpxTrackSegment> newSegments = new ArrayList<>();
Note: See TracChangeset for help on using the changeset viewer.