You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
<p>These are the release notes for the Java library for mapcodes.</p>
71
+
<p><b>IMPORTANT: This is a SNAPSHOT version of the repository which may change at any time. Needless to say, never depend on <<<SNAPSHOT</b>> versions if you can avoid it. In any case, never depend on them for your own non-<tt>SNAPSHOT</tt> releases.</p>
72
+
<divclass="section">
73
+
<h3>1.50.1<aname="a1.50.1"></a></h3>
74
+
<ul>
75
+
<li>To do.</li></ul></div>
76
+
<divclass="section">
77
+
<h3>1.50.0<aname="a1.50.0"></a></h3>
78
+
<ul>
79
+
<li>Major release. This version is not backwards compatible with mapcode 1.4x: is has dropped support for Antartica AT0-8 codes and has a changed (improved) way of dealing with the Greek alphabet.</li>
80
+
<li>Added 22-chararcter post-processing of all-digit mapcodes for the Greek alphabet.</li>
81
+
<li>Retired legacy aliases EAZ and SKM, AU-QL, AU-TS, AU-NI and AU-JB.</li>
82
+
<li>Retired legacy Antarctica claims AT0 through AT8.</li>
83
+
<li>Added convencience methods for <tt>MapcodeCodec</tt> to accept <tt>Point</tt> for all encode functions as well (not just <tt>latDeg</tt>, <tt>lonDeg</tt>).</li>
84
+
<li>Added alphabet support to convert mapcodes (both codes and territories) between <tt>Alphabet</tt>s.</li>
85
+
<li>Exceptions have been corrected and documented in code.</li>
86
+
<li>Allowed nullable values in <tt>MapcodeCodec</tt> encode and decode methods to assume reasonable defaults.</li>
87
+
<li>Microdegrees are no longer support publicly in <tt>Point</tt>. Only degrees.</li>
88
+
<li>Latitudes are limited to -90..90 and longitudes are wrapped to -180..180 (non inclusive).</li></ul></div>
89
+
<divclass="section">
90
+
<h3>1.42.3<aname="a1.42.3"></a></h3>
91
+
<ul>
92
+
<li>To be done.</li></ul></div>
93
+
<divclass="section">
94
+
<h3>1.42.2<aname="a1.42.2"></a></h3>
95
+
<ul>
96
+
<li>Upper- and lowercase mapcodes always allowed.</li></ul></div>
97
+
<divclass="section">
98
+
<h3>1.42.1<aname="a1.42.1"></a></h3>
99
+
<ul>
100
+
<li>Cleaned up source. Removed all pending IntelliJ IDEA inspection warnings and reformatted code using default IDEA code style to maintain consistent layout.</li>
101
+
<li>Add additional unit tests to check for correct handling of international mapcode handling.</li>
102
+
<li>Added safe constants for the maximum delta distance in meters for mapcode accuracy.</li></ul></div>
<p>You can find the release notes for this library at: <b><ahref="./ReleaseNotes.html">Release Notes</a></b></p></div>
107
107
<divclass="section">
108
108
<h2>Code Style Settings for IntelliJ IDEA<aname="Code_Style_Settings_for_IntelliJ_IDEA"></a></h2>
109
-
<p>The Java code uses the IntelliJ IDEA code style settings as specified in: <b><ahref="./IntelliJ.html">IntelliJ IDEA Code Style Settings</a></b>.</p></div>
109
+
<p>The Java code uses the default IntelliJ IDEA code style settings for Java.</p></div>
110
110
<divclass="section">
111
111
<h2>How To Build The Mapcode Library JAR File<aname="How_To_Build_The_Mapcode_Library_JAR_File"></a></h2>
112
112
<p>The sources for the Mapcode Library for Java contain everything to build the Mapcode JAR file as well as a significant number of unit tests to verify the correctness of the implementation against the reference C implementation.</p>
<p>This class represents mapcodes, which consist of a string of characters, digits and a decimal point and a territory specification. The territory specification is required for national (local) mapcodes, which are not globally unique.</p>
172
167
<p>The class also exposes methods to convert mapcodes to proper mapcode strings, usable for printing and it allows string-formatted mapcodes to be converted to <tt>Mapcode</tt> objects, where territory information is properly parsed and converted to a <tt>Territory</tt> enumeration value.</p>
173
168
<ul>
174
-
<li><tt>String getMapcode()</tt> returns the mapcode string which does not include territory information. You can also use <tt>getMapcodePrecision1()</tt> and <tt>getMapcodePrecision2()</tt> for more precision, but longer mapcodes.
169
+
<li><tt>String getCode()</tt> returns the mapcode string which does not include territory information. You can also use <tt>getCode(1)</tt> and <tt>getCode(2)</tt> for more precision, but longer mapcodes.
175
170
<ul>
176
-
<li>The default precision offered by <tt>getMapcode()</tt> is approximately 5m (maximum distance to latitude, longitude the mapcode decodes to). This corresponds to an area of 10m x 10m (100m2). These mapcodes include no additional precision digits.</li>
177
-
<li>The precision offered by <tt>getMapcodePrecision1()</tt> is approximately 1m. This corresponds to an area of 2m x 2m (4m2). These mapcodes include 1 additional precision digit.</li>
178
-
<li>The precision offered by <tt>getMapcodePrecision2()</tt> is approximately 0.16m. This corresponds to an area of 0.32m x 0.32m (0.1m2). These mapcodes include 2 additional precision digits.</li></ul></li>
171
+
<li>The default precision offered by <tt>getCode()</tt> is approximately 10m (maximum distance to latitude, longitude the mapcode decodes to). This corresponds to an area of 20m x 20m (400m2). These mapcodes include no additional precision digits.</li>
172
+
<li>The precision offered by <tt>getMapcodePrecision1()</tt> is approximately 2m. This corresponds to an area of 4m x 4m (16m2). These mapcodes include 1 additional precision digit.</li>
173
+
<li>The precision offered by <tt>getMapcodePrecision2()</tt> is approximately 0.40m. This corresponds to an area of 0.80m x 0.80m (0.64m2). These mapcodes include 2 additional precision digits.</li></ul></li>
179
174
<li><tt>Territory getTerritory()</tt> returns the territory information.</li>
180
-
<li><tt>StringasInternationFullname()</tt> returns mapcodes string with territory information, specified as a full country name.</li>
181
-
<li><tt>String asInternationISO()</tt> returns mapcodes string with territory information, specified as an ISO code name. Importanmt: This is returns the same result as <tt>toString()</tt>.</li></ul></div>
175
+
<li><tt>toString()</tt> and <tt>getCodeWithTerritory()</tt> return mapcodes string with territory information, specified as a ISO code.</li></ul></div>
<p>This class represents (latitude, longitude) locations. It offers methods to create locations using degrees or micro-degrees (which are degrees times 1.000.000).</p>
178
+
<p>This class represents (latitude, longitude) locations. It offers methods to create locations using degrees.</p>
185
179
<ul>
186
180
<li><tt>Point fromDeg(double latitude, double longitude)</tt> returns a <tt>Point</tt> for a given (latitude, longitude) pair. Note that:
187
181
<ul>
188
182
<li><b>latitudes</b> are always between <tt>-90</tt> and <tt>90</tt>, and</li>
189
-
<li><b>longitudes</b> are always between <tt>-180</tt> and <tt>180</tt>.</li></ul></li>
190
-
<li><tt>Point fromMicroDeg(int latitude, int longitude)</tt> is the same as <tt>fromDeg</tt> except the values are integers and are degerees times 1.000.000, so the ranges are:
191
-
<ul>
192
-
<li><b>latitudes</b> are always between <tt>-90000000</tt> and <tt>90000000</tt>, and</li>
193
-
<li><b>longitudes</b> are always between <tt>-180000000</tt> and <tt>180000000</tt>.</li></ul></li>
194
-
<li><tt>double getLat()</tt> and <tt>getLon()</tt> return the latitude and longitude respectively, in degrees.</li>
195
-
<li><tt>int getLatMicroDegrees()</tt> and <tt>getLonMicroDegrees()</tt> return the latitude and longitude respectively, in micro-degrees.</li></ul></div>
183
+
<li><b>longitudes</b> are always between <tt>-180</tt> and <tt>180</tt>;</li>
184
+
<li>Values outside these range are correctly limited (latitude) or wrapped (longitude) to these ranges.</li></ul></li>
185
+
<li><tt>double getLat()</tt> and <tt>getLon()</tt> return the latitude and longitude respectively, in degrees.</li></ul></div>
196
186
<divclass="section">
197
187
<h2>What Is A Mapcode?<aname="What_Is_A_Mapcode"></a></h2>
198
188
<p>A mapcode represents a location. Every location on Earth can be represented by a mapcode. Mapcodes were designed to be short, easy to recognise, remember and communicate. They are precise to a few meters, which is good enough for every-day use.</p></div>
0 commit comments