source: josm/trunk/src/org/openstreetmap/josm/data/gpx/GpxConstants.java@ 10906

Last change on this file since 10906 was 10215, checked in by Don-vip, 8 years ago

findbugs - MS_MUTABLE_COLLECTION

  • Property svn:eol-style set to native
File size: 4.1 KB
Line 
1// License: GPL. For details, see LICENSE file.
2package org.openstreetmap.josm.data.gpx;
3
4import java.util.Arrays;
5import java.util.Collection;
6import java.util.Collections;
7import java.util.List;
8
9import org.openstreetmap.josm.Main;
10
11/**
12 * Constants for GPX handling.
13 */
14public interface GpxConstants {
15
16 /** GPS name of the element. This field will be transferred to and from the GPS.
17 * GPX does not place restrictions on the length of this field or the characters contained in it.
18 * It is up to the receiving application to validate the field before sending it to the GPS. */
19 String GPX_NAME = "name";
20
21 /** GPS element comment. Sent to GPS as comment. */
22 String GPX_CMT = "cmt";
23
24 /** Text description of the element. Holds additional information about the element intended for the user, not the GPS. */
25 String GPX_DESC = "desc";
26
27 /** Source of data. Included to give user some idea of reliability and accuracy of data. */
28 String GPX_SRC = "src";
29
30 String META_PREFIX = "meta.";
31 String META_AUTHOR_NAME = META_PREFIX + "author.name";
32 String META_AUTHOR_EMAIL = META_PREFIX + "author.email";
33 String META_AUTHOR_LINK = META_PREFIX + "author.link";
34 String META_COPYRIGHT_AUTHOR = META_PREFIX + "copyright.author";
35 String META_COPYRIGHT_LICENSE = META_PREFIX + "copyright.license";
36 String META_COPYRIGHT_YEAR = META_PREFIX + "copyright.year";
37 String META_DESC = META_PREFIX + "desc";
38 String META_KEYWORDS = META_PREFIX + "keywords";
39 String META_LINKS = META_PREFIX + "links";
40 String META_NAME = META_PREFIX + "name";
41 String META_TIME = META_PREFIX + "time";
42 String META_BOUNDS = META_PREFIX + "bounds";
43 String META_EXTENSIONS = META_PREFIX + "extensions";
44
45 String JOSM_EXTENSIONS_NAMESPACE_URI = Main.getXMLBase() + "/gpx-extensions-1.0";
46
47 /** Elevation (in meters) of the point. */
48 String PT_ELE = "ele";
49
50 /** Creation/modification timestamp for the point.
51 * Date and time in are in Univeral Coordinated Time (UTC), not local time!
52 * Conforms to ISO 8601 specification for date/time representation.
53 * Fractional seconds are allowed for millisecond timing in tracklogs. */
54 String PT_TIME = "time";
55
56 /** Magnetic variation (in degrees) at the point. 0.0 <= value < 360.0 */
57 String PT_MAGVAR = "magvar";
58
59 /** Height, in meters, of geoid (mean sea level) above WGS-84 earth ellipsoid. (NMEA GGA message) */
60 String PT_GEOIDHEIGHT = "geoidheight";
61
62 /** Text of GPS symbol name. For interchange with other programs, use the exact spelling of the symbol on the GPS, if known. */
63 String PT_SYM = "sym";
64
65 /** Type (textual classification) of element. */
66 String PT_TYPE = "type";
67
68 /** Type of GPS fix. none means GPS had no fix. Value comes from list: {'none'|'2d'|'3d'|'dgps'|'pps'} */
69 String PT_FIX = "fix";
70
71 /** Number of satellites used to calculate the GPS fix. (not number of satellites in view). */
72 String PT_SAT = "sat";
73
74 /** Horizontal dilution of precision. */
75 String PT_HDOP = "hdop";
76
77 /** Vertical dilution of precision. */
78 String PT_VDOP = "vdop";
79
80 /** Position dilution of precision. */
81 String PT_PDOP = "pdop";
82
83 /** Number of seconds since last DGPS update. */
84 String PT_AGEOFDGPSDATA = "ageofdgpsdata";
85
86 /** Represents a differential GPS station. 0 <= value <= 1023 */
87 String PT_DGPSID = "dgpsid";
88
89 /**
90 * Ordered list of all possible waypoint keys.
91 */
92 List<String> WPT_KEYS = Collections.unmodifiableList(Arrays.asList(PT_ELE, PT_TIME, PT_MAGVAR, PT_GEOIDHEIGHT,
93 GPX_NAME, GPX_CMT, GPX_DESC, GPX_SRC, META_LINKS, PT_SYM, PT_TYPE,
94 PT_FIX, PT_SAT, PT_HDOP, PT_VDOP, PT_PDOP, PT_AGEOFDGPSDATA, PT_DGPSID, META_EXTENSIONS));
95
96 /**
97 * Ordered list of all possible route and track keys.
98 */
99 List<String> RTE_TRK_KEYS = Collections.unmodifiableList(Arrays.asList(
100 GPX_NAME, GPX_CMT, GPX_DESC, GPX_SRC, META_LINKS, "number", PT_TYPE, META_EXTENSIONS));
101
102 /**
103 * Possible fix values.
104 */
105 Collection<String> FIX_VALUES = Collections.unmodifiableList(Arrays.asList("none", "2d", "3d", "dgps", "pps"));
106}
Note: See TracBrowser for help on using the repository browser.