Changeset 12186 in josm


Ignore:
Timestamp:
2017-05-15T22:40:54+02:00 (13 days ago)
Author:
michael2402
Message:

See #14794: Add javadoc for all gpx classes.

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

Legend:

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

    r10215 r12186  
    88
    99import org.openstreetmap.josm.Main;
     10import org.openstreetmap.josm.data.Bounds;
    1011
    1112/**
     
    2829    String GPX_SRC = "src";
    2930
     31    /**
     32     * Prefix used for all meta values.
     33     */
    3034    String META_PREFIX = "meta.";
     35    /**
     36     * A constant for the metadata hash map: the author name of the file
     37     * @see GpxData#get(String)
     38     */
    3139    String META_AUTHOR_NAME = META_PREFIX + "author.name";
     40    /**
     41     * A constant for the metadata hash map: the author email of the file
     42     * @see GpxData#get(String)
     43     */
    3244    String META_AUTHOR_EMAIL = META_PREFIX + "author.email";
     45    /**
     46     * A constant for the metadata hash map: a link to a page about the author
     47     * @see GpxData#get(String)
     48     */
    3349    String META_AUTHOR_LINK = META_PREFIX + "author.link";
     50    /**
     51     * A constant for the metadata hash map: the author field for the copyright information in the gpx file
     52     * @see GpxData#get(String)
     53     */
    3454    String META_COPYRIGHT_AUTHOR = META_PREFIX + "copyright.author";
     55    /**
     56     * A constant for the metadata hash map: the license of the file
     57     * @see GpxData#get(String)
     58     */
    3559    String META_COPYRIGHT_LICENSE = META_PREFIX + "copyright.license";
     60    /**
     61     * A constant for the metadata hash map: the year of the license for the file
     62     * @see GpxData#get(String)
     63     */
    3664    String META_COPYRIGHT_YEAR = META_PREFIX + "copyright.year";
     65    /**
     66     * A constant for the metadata hash map: a description of the file
     67     * @see GpxData#get(String)
     68     */
    3769    String META_DESC = META_PREFIX + "desc";
     70    /**
     71     * A constant for the metadata hash map: the keywords of the file
     72     * @see GpxData#get(String)
     73     */
    3874    String META_KEYWORDS = META_PREFIX + "keywords";
     75    /**
     76     * A constant for the metadata hash map: the links. They are stored as list of {@link GpxLink} objects
     77     * @see GpxData#get(String)
     78     */
    3979    String META_LINKS = META_PREFIX + "links";
     80    /**
     81     * A constant for the metadata hash map: the name of the file (stored in the file, not the one on the disk)
     82     * @see GpxData#get(String)
     83     */
    4084    String META_NAME = META_PREFIX + "name";
     85    /**
     86     * A constant for the metadata hash map: the time as string
     87     * @see GpxData#get(String)
     88     */
    4189    String META_TIME = META_PREFIX + "time";
     90    /**
     91     * A constant for the metadata hash map: the bounding box. This is a {@link Bounds} object
     92     * @see GpxData#getMetaBounds()
     93     */
    4294    String META_BOUNDS = META_PREFIX + "bounds";
     95    /**
     96     * A constant for the metadata hash map: the extension data. This is a {@link Extensions} object
     97     * @see GpxData#addExtension(String, String)
     98     * @see GpxData#get(String)
     99     */
    43100    String META_EXTENSIONS = META_PREFIX + "extensions";
    44101
     102    /**
     103     * A namespace for josm GPX extensions
     104     */
    45105    String JOSM_EXTENSIONS_NAMESPACE_URI = Main.getXMLBase() + "/gpx-extensions-1.0";
    46106
  • trunk/src/org/openstreetmap/josm/data/gpx/GpxData.java

    r12165 r12186  
    3434public class GpxData extends WithAttributes implements Data {
    3535
     36    /**
     37     * The disk file this layer is stored in, if it is a local layer. May be <code>null</code>.
     38     */
    3639    public File storageFile;
     40    /**
     41     * A boolean flag indicating if the data was read from the OSM server.
     42     */
    3743    public boolean fromServer;
    3844
    39     /** Creator (usually software) */
     45    /**
     46     * Creator metadata for this file (usually software)
     47     */
    4048    public String creator;
    4149
     50    /**
     51     * A list of tracks this file consists of
     52     */
    4253    private final ArrayList<GpxTrack> privateTracks = new ArrayList<>();
     54    /**
     55     * GXP routes in this file
     56     */
    4357    private final ArrayList<GpxRoute> privateRoutes = new ArrayList<>();
     58    /**
     59     * Addidionaly waypoints for this file.
     60     */
    4461    private final ArrayList<WayPoint> privateWaypoints = new ArrayList<>();
    4562    private final GpxTrackChangeListener proxy = e -> fireInvalidate();
  • trunk/src/org/openstreetmap/josm/data/gpx/GpxRoute.java

    r10906 r12186  
    55import java.util.LinkedList;
    66
     7/**
     8 * A route is a part of a GPX file containing of multiple GPX points.
     9 */
    710public class GpxRoute extends WithAttributes {
     11    /**
     12     * The points this route consists of. Should not be changed after creation.
     13     * <p>
     14     * This collection is ordered.
     15     */
    816    public Collection<WayPoint> routePoints = new LinkedList<>();
    917
  • trunk/src/org/openstreetmap/josm/data/gpx/ImmutableGpxTrackSegment.java

    r11553 r12186  
    99import org.openstreetmap.josm.data.Bounds;
    1010
     11/**
     12 * A gpx track segment consisting of multiple waypoints, that cannot be changed.
     13 */
    1114public class ImmutableGpxTrackSegment implements GpxTrackSegment {
    1215
     
    5962    @Override
    6063    public Collection<WayPoint> getWayPoints() {
    61         return wayPoints;
     64        return Collections.unmodifiableList(wayPoints);
    6265    }
    6366
  • trunk/src/org/openstreetmap/josm/data/gpx/WayPoint.java

    r12169 r12186  
    2828     */
    2929    public double time;
     30    /**
     31     * The color to draw the segment before this point in
     32     * @see #drawLine
     33     */
    3034    public Color customColoring;
     35    /**
     36     * <code>true</code> indicates that the line before this point should be drawn
     37     */
    3138    public boolean drawLine;
     39    /**
     40     * The direction of the line before this point. Used as cache to speed up drawing. Should not be relied on.
     41     */
    3242    public int dir;
    3343
Note: See TracChangeset for help on using the changeset viewer.