- Timestamp:
- 2016-01-01T19:51:11+01:00 (9 years ago)
- Location:
- trunk/src/org/openstreetmap/josm
- Files:
-
- 53 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/actions/JoinAreasAction.java
r9087 r9243 196 196 private boolean lastWayReverse; 197 197 198 /** Constructor */ 198 /** Constructor 199 * @param ways available ways 200 */ 199 201 WayTraverser(Collection<WayInPolygon> ways) { 200 202 availableWays = new HashSet<>(ways); … … 260 262 /** 261 263 * Returns oriented angle (N1N2, N1N3) in range [0; 2*Math.PI[ 264 * @param N1 first node 265 * @param N2 second node 266 * @param N3 third node 262 267 * @return oriented angle (N1N2, N1N3) in range [0; 2*Math.PI[ 263 268 */ -
trunk/src/org/openstreetmap/josm/command/PurgeCommand.java
r9062 r9243 51 51 * - Each element of makeIncomplete must not be new and must have only 52 52 * referrers that are either a relation or included in toPurge. 53 * @param layer OSM data layer 54 * @param toPurge primitives to purge 55 * @param makeIncomplete primitives to make incomplete 53 56 */ 54 57 public PurgeCommand(OsmDataLayer layer, Collection<OsmPrimitive> toPurge, Collection<OsmPrimitive> makeIncomplete) { … … 142 145 * Sorts a collection of primitives such that for each object 143 146 * its referrers come later in the sorted collection. 147 * @param sel collection of primitives to sort 144 148 * @return sorted list 145 149 */ -
trunk/src/org/openstreetmap/josm/command/RotateCommand.java
r9067 r9243 35 35 * Creates a RotateCommand. 36 36 * Assign the initial object set, compute pivot point and inital rotation angle. 37 * @param objects objects to fetch nodes from 38 * @param currentEN cuurent eats/north 37 39 */ 38 40 public RotateCommand(Collection<OsmPrimitive> objects, EastNorth currentEN) { … … 48 50 /** 49 51 * Get angle between the horizontal axis and the line formed by the pivot and given point. 52 * @param currentEN cuurent eats/north 50 53 * @return angle between the horizontal axis and the line formed by the pivot and given point 51 54 **/ -
trunk/src/org/openstreetmap/josm/command/ScaleCommand.java
r9067 r9243 31 31 * Computation of pivot point is done by the same rules that are used in 32 32 * the "align nodes in circle" action. 33 * @param objects objects to fetch nodes from 34 * @param currentEN cuurent eats/north 33 35 */ 34 36 public ScaleCommand(Collection<OsmPrimitive> objects, EastNorth currentEN) { -
trunk/src/org/openstreetmap/josm/command/TransformNodesCommand.java
r8931 r9243 46 46 * Creates a TransformNodesObject. 47 47 * Find out the impacted nodes and store their initial state. 48 * @param objects objects to fetch nodes from 48 49 */ 49 50 public TransformNodesCommand(Collection<OsmPrimitive> objects) { -
trunk/src/org/openstreetmap/josm/data/Bounds.java
r8846 r9243 79 79 /** 80 80 * Construct bounds out of two points. Coords will be rounded. 81 * @param min min lat/lon 82 * @param max max lat/lon 81 83 */ 82 84 public Bounds(LatLon min, LatLon max) { … … 88 90 } 89 91 92 /** 93 * Constructs bounds out a single point. 94 * @param b lat/lon 95 */ 90 96 public Bounds(LatLon b) { 91 97 this(b, true); … … 360 366 * The two bounds intersect? Compared to java Shape.intersects, if does not use 361 367 * the interior but the closure. (">=" instead of ">") 368 * @param b other bounds 369 * @return {@code true} if the two bounds intersect 362 370 */ 363 371 public boolean intersects(Bounds b) { -
trunk/src/org/openstreetmap/josm/data/CustomConfigurator.java
r9067 r9243 702 702 /** 703 703 * substitute ${expression} = expression evaluated by JavaScript 704 * @param s string 705 * @return evaluation result 704 706 */ 705 707 private String evalVars(String s) { 706 Pattern p = Pattern.compile("\\$\\{([^\\}]*)\\}"); 707 Matcher mr = p.matcher(s); 708 Matcher mr = Pattern.compile("\\$\\{([^\\}]*)\\}").matcher(s); 708 709 StringBuffer sb = new StringBuffer(); 709 710 while (mr.find()) { … … 810 811 811 812 /** 812 * Delete items from @param mainpref collections that match items from @param fragment collections 813 */ 813 * Delete items from {@code mainpref} collections that match items from {@code fragment} collections. 814 * @param fragment preferences 815 * @param mainpref main preferences 816 */ 814 817 private static void deletePreferenceValues(Preferences fragment, Preferences mainpref) { 815 818 -
trunk/src/org/openstreetmap/josm/data/Preferences.java
r9224 r9243 822 822 * @param value the value of the setting. Can be null or "" which both removes 823 823 * the key-value entry. 824 * @return true, if something has changed (i.e. value is different than before)824 * @return {@code true}, if something has changed (i.e. value is different than before) 825 825 */ 826 826 public boolean put(final String key, String value) { … … 1178 1178 * @param setting the value of the setting. In case it is null, the key-value 1179 1179 * entry will be removed. 1180 * @return true, if something has changed (i.e. value is different than before)1180 * @return {@code true}, if something has changed (i.e. value is different than before) 1181 1181 */ 1182 1182 public boolean putSetting(final String key, Setting<?> setting) { … … 1247 1247 } 1248 1248 1249 /** 1250 * Put a collection. 1251 * @param key key 1252 * @param value value 1253 * @return {@code true}, if something has changed (i.e. value is different than before) 1254 */ 1249 1255 public boolean putCollection(String key, Collection<String> value) { 1250 1256 return putSetting(key, value == null ? null : ListSetting.create(value)); … … 1253 1259 /** 1254 1260 * Saves at most {@code maxsize} items of collection {@code val}. 1261 * @param key key 1262 * @param maxsize max number of items to save 1263 * @param val value 1264 * @return {@code true}, if something has changed (i.e. value is different than before) 1255 1265 */ 1256 1266 public boolean putCollectionBounded(String key, int maxsize, Collection<String> val) { … … 1268 1278 * Used to read a 2-dimensional array of strings from the preference file. 1269 1279 * If not a single entry could be found, <code>def</code> is returned. 1280 * @param key preference key 1281 * @param def default array value 1282 * @return array value 1270 1283 */ 1271 1284 @SuppressWarnings({ "unchecked", "rawtypes" }) … … 1280 1293 } 1281 1294 1295 /** 1296 * Put an array. 1297 * @param key key 1298 * @param value value 1299 * @return {@code true}, if something has changed (i.e. value is different than before) 1300 */ 1282 1301 public boolean putArray(String key, Collection<Collection<String>> value) { 1283 1302 return putSetting(key, value == null ? null : ListListSetting.create(value)); … … 1333 1352 /** 1334 1353 * same as above, but returns def if nothing was found 1354 * @param key main preference key 1355 * @param def default value 1356 * @param klass The struct class 1357 * @return a list of objects of type T or {@code def} if nothing was found 1335 1358 */ 1336 1359 public <T> List<T> getListOfStructs(String key, Collection<T> def, Class<T> klass) { -
trunk/src/org/openstreetmap/josm/data/ProjectionBounds.java
r8927 r9243 13 13 public class ProjectionBounds { 14 14 /** 15 * The minimum and maximum coordinates.15 * The minimum east coordinate. 16 16 */ 17 public double minEast, minNorth, maxEast, maxNorth; 17 public double minEast; 18 /** 19 * The minimum north coordinate. 20 */ 21 public double minNorth; 22 /** 23 * The maximum east coordinate. 24 */ 25 public double maxEast; 26 /** 27 * The minimum north coordinate. 28 */ 29 public double maxNorth; 18 30 19 31 /** 20 32 * Construct bounds out of two points. 33 * @param min min east/north 34 * @param max max east/north 21 35 */ 22 36 public ProjectionBounds(EastNorth min, EastNorth max) { … … 27 41 } 28 42 43 /** 44 * Construct bounds out of a single point. 45 * @param p east/north 46 */ 29 47 public ProjectionBounds(EastNorth p) { 30 48 this.minEast = this.maxEast = p.east(); … … 32 50 } 33 51 52 /** 53 * Construct bounds out of a center point and east/north dimensions. 54 * @param center center east/north 55 * @param east east dimension 56 * @param north north dimension 57 */ 34 58 public ProjectionBounds(EastNorth center, double east, double north) { 35 59 this.minEast = center.east()-east/2.0; … … 39 63 } 40 64 65 /** 66 * Construct bounds out of two points. 67 * @param minEast min east 68 * @param minNorth min north 69 * @param maxEast max east 70 * @param maxNorth max north 71 */ 41 72 public ProjectionBounds(double minEast, double minNorth, double maxEast, double maxNorth) { 42 73 this.minEast = minEast; … … 46 77 } 47 78 79 /** 80 * Extends bounds to include point {@code e}. 81 * @param e east/north to include 82 */ 48 83 public void extend(EastNorth e) { 49 84 if (e.east() < minEast) { … … 61 96 } 62 97 98 /** 99 * Returns the center east/north. 100 * @return the center east/north 101 */ 63 102 public EastNorth getCenter() { 64 103 return new EastNorth((minEast + maxEast) / 2.0, (minNorth + maxNorth) / 2.0); … … 73 112 * The two bounds intersect? Compared to java Shape.intersects, if does not use 74 113 * the interior but the closure. (">=" instead of ">") 114 * @param b projection bounds 115 * @return {@code true} if the two bounds intersect 75 116 */ 76 117 public boolean intersects(ProjectionBounds b) { … … 81 122 } 82 123 124 /** 125 * Returns the min east/north. 126 * @return the min east/north 127 */ 83 128 public EastNorth getMin() { 84 129 return new EastNorth(minEast, minNorth); 85 130 } 86 131 132 /** 133 * Returns the max east/north. 134 * @return the max east/north 135 */ 87 136 public EastNorth getMax() { 88 137 return new EastNorth(maxEast, maxNorth); -
trunk/src/org/openstreetmap/josm/data/coor/EastNorth.java
r8906 r9243 156 156 /** 157 157 * Compares two EastNorth values 158 * @param other other east.north 159 * @param e epsilon 158 160 * 159 * @return true if "x" and "y" values are within 1E-6of each other161 * @return true if "x" and "y" values are within epsilon {@code e} of each other 160 162 */ 161 163 public boolean equalsEpsilon(EastNorth other, double e) { -
trunk/src/org/openstreetmap/josm/data/coor/LatLon.java
r8846 r9243 115 115 * For example, a value of -181 will return +179, a value of +181 will return -179. 116 116 * @param value A longitude value not restricted to the [-180,+180] range. 117 * @return a valid OSM longitude [-180,+180] 117 118 */ 118 119 public static double toIntervalLon(double value) { … … 237 238 238 239 /** 240 * @param other other lat/lon 239 241 * @return <code>true</code> if the other point has almost the same lat/lon 240 * values, only differing by no more than 241 * 1 / {@link #MAX_SERVER_PRECISION MAX_SERVER_PRECISION}. 242 * values, only differing by no more than 1 / {@link #MAX_SERVER_PRECISION MAX_SERVER_PRECISION}. 242 243 */ 243 244 public boolean equalsEpsilon(LatLon other) { … … 247 248 248 249 /** 249 * @return <code>true</code>, if the coordinate is outside the world, compared250 * by using lat/lon.250 * Determines if this lat/lon is outside of the world 251 * @return <code>true</code>, if the coordinate is outside the world, compared by using lat/lon. 251 252 */ 252 253 public boolean isOutSideWorld() { … … 257 258 258 259 /** 260 * Determines if this lat/lon is within the given bounding box. 261 * @param b bounding box 259 262 * @return <code>true</code> if this is within the given bounding box. 260 263 */ … … 330 333 /** 331 334 * Returns this lat/lon pair in human-readable format separated by {@code separator}. 335 * @param separator values separator 332 336 * @return String in the format {@code "1.23456[separator]2.34567"} 333 337 */ … … 376 380 377 381 /** 378 * Returns the value rounded to OSM precisions, i.e. to 379 * LatLon.MAX_SERVER_PRECISION382 * Returns the value rounded to OSM precisions, i.e. to {@link LatLon#MAX_SERVER_PRECISION}. 383 * @param value lat/lon value 380 384 * 381 385 * @return rounded value … … 388 392 * Returns the value rounded to OSM precision. This function is now the same as 389 393 * {@link #roundToOsmPrecision(double)}, since the rounding error has been fixed. 394 * @param value lat/lon value 390 395 * 391 396 * @return rounded value -
trunk/src/org/openstreetmap/josm/data/osm/AbstractPrimitive.java
r8840 r9243 449 449 * If set to true, this object is incomplete, which means only the id 450 450 * and type is known (type is the objects instance class) 451 * @param incomplete incomplete flag value 451 452 */ 452 453 protected void setIncomplete(boolean incomplete) { … … 649 650 /** 650 651 * Returns true if the {@code key} corresponds to an OSM true value. 652 * @param key OSM key 653 * @return {@code true} if the {@code key} corresponds to an OSM true value 651 654 * @see OsmUtils#isTrue(String) 652 655 */ … … 657 660 /** 658 661 * Returns true if the {@code key} corresponds to an OSM false value. 662 * @param key OSM key 663 * @return {@code true} if the {@code key} corresponds to an OSM false value 659 664 * @see OsmUtils#isFalse(String) 660 665 */ … … 725 730 /** 726 731 * What to do, when the tags have changed by one of the tag-changing methods. 732 * @param originalKeys original tags 727 733 */ 728 734 protected abstract void keysChangedImpl(Map<String, String> originalKeys); -
trunk/src/org/openstreetmap/josm/data/osm/BBox.java
r8510 r9243 114 114 /** 115 115 * Extends this bbox to include the point (x, y) 116 * @param x X coordinate 117 * @param y Y coordinate 116 118 */ 117 119 public final void add(double x, double y) { … … 146 148 147 149 /** 148 * Tests, weather the bbox b lies completely inside 149 * this bbox. 150 * Tests, whether the bbox {@code b} lies completely inside this bbox. 151 * @param b bounding box 152 * @return {@code true} if {@code b} lies completely inside this bbox 150 153 */ 151 154 public boolean bounds(BBox b) { … … 159 162 160 163 /** 161 * Tests, weather the Point c lies within the bbox. 164 * Tests, whether the Point {@code c} lies within the bbox. 165 * @param c point 166 * @return {@code true} if {@code c} lies within the bbox 162 167 */ 163 168 public boolean bounds(LatLon c) { … … 171 176 172 177 /** 173 * Tests, w eather two BBoxes intersect as an area.178 * Tests, whether two BBoxes intersect as an area. 174 179 * I.e. whether there exists a point that lies in both of them. 180 * @param b other bounding box 181 * @return {@code true} if this bbox intersects with the other 175 182 */ 176 183 public boolean intersects(BBox b) { -
trunk/src/org/openstreetmap/josm/data/osm/Hash.java
r8512 r9243 10 10 * For use cases, see {@link Storage}. 11 11 * @author nenik 12 * @param <K> type for hashCode and first equals parameter 13 * @param <T> type for second equals parameter 12 14 */ 13 15 public interface Hash<K, T> { -
trunk/src/org/openstreetmap/josm/data/osm/MultipolygonBuilder.java
r9087 r9243 47 47 * Constructs a new {@code JoinedPolygon} from given list of ways. 48 48 * @param ways The ways used to build joined polygon 49 * @param reversed list of reversed states 49 50 */ 50 51 public JoinedPolygon(List<Way> ways, List<Boolean> reversed) { … … 94 95 */ 95 96 static class PolygonLevel { 96 public final int level; // nesting level, even for outer, odd for inner polygons.97 public final int level; // nesting level, even for outer, odd for inner polygons. 97 98 public final JoinedPolygon outerWay; 98 99 … … 298 299 /** 299 300 * Collects outer way and corresponding inner ways from all boundaries. 301 * @param boundaryWays boundary ways 300 302 * @return the outermostWay, or {@code null} if intersection found. 301 303 */ … … 354 356 /** 355 357 * Collects outer way and corresponding inner ways from all boundaries. 358 * @param level nesting level 359 * @param boundaryWays boundary ways 356 360 * @return the outermostWay, or {@code null} if intersection found. 357 361 */ -
trunk/src/org/openstreetmap/josm/data/osm/Node.java
r8993 r9243 109 109 /** 110 110 * To be used only by Dataset.reindexNode 111 * @param coor lat/lon 112 * @param eastNorth east/north 111 113 */ 112 114 protected void setCoorInternal(LatLon coor, EastNorth eastNorth) { … … 354 356 * Tests whether {@code this} node is connected to {@code otherNode} via at most {@code hops} nodes 355 357 * matching the {@code predicate} (which may be {@code null} to consider all nodes). 358 * @param otherNodes other nodes 359 * @param hops number of hops 360 * @param predicate predicate to match 361 * @return {@code true} if {@code this} node mets the conditions 356 362 */ 357 363 public boolean isConnectedTo(final Collection<Node> otherNodes, final int hops, Predicate<Node> predicate) { -
trunk/src/org/openstreetmap/josm/data/osm/OsmPrimitive.java
r8901 r9243 477 477 /** 478 478 * Remove the disabled flag from the primitive. 479 * Afterwards, the primitive is displayed normally and can be selected 480 * again.479 * Afterwards, the primitive is displayed normally and can be selected again. 480 * @return {@code true} if a change occurred 481 481 */ 482 482 public boolean unsetDisabledState() { … … 493 493 /** 494 494 * Set binary property used internally by the filter mechanism. 495 * @param isExplicit new "disabled type" flag value 495 496 */ 496 497 public void setDisabledType(boolean isExplicit) { … … 500 501 /** 501 502 * Set binary property used internally by the filter mechanism. 503 * @param isExplicit new "hidden type" flag value 502 504 */ 503 505 public void setHiddenType(boolean isExplicit) { … … 506 508 507 509 /** 508 * Replies true, if this primitive is disabled. (E.g. a filter 509 * applies)510 * Replies true, if this primitive is disabled. (E.g. a filter applies) 511 * @return {@code true} if this object has the "disabled" flag enabled 510 512 */ 511 513 public boolean isDisabled() { … … 514 516 515 517 /** 516 * Replies true, if this primitive is disabled and marked as 517 * completely hidden on the map.518 * Replies true, if this primitive is disabled and marked as completely hidden on the map. 519 * @return {@code true} if this object has both the "disabled" and "hide if disabled" flags enabled 518 520 */ 519 521 public boolean isDisabledAndHidden() { … … 523 525 /** 524 526 * Get binary property used internally by the filter mechanism. 527 * @return {@code true} if this object has the "hidden type" flag enabled 525 528 */ 526 529 public boolean getHiddenType() { … … 530 533 /** 531 534 * Get binary property used internally by the filter mechanism. 535 * @return {@code true} if this object has the "disabled type" flag enabled 532 536 */ 533 537 public boolean getDisabledType() { … … 535 539 } 536 540 541 /** 542 * Determines if this object is selectable. 543 * @return {@code true} if this object is selectable 544 */ 537 545 public boolean isSelectable() { 538 546 return (flags & (FLAG_DELETED + FLAG_INCOMPLETE + FLAG_DISABLED + FLAG_HIDE_IF_DISABLED)) == 0; 539 547 } 540 548 549 /** 550 * Determines if this object is drawable. 551 * @return {@code true} if this object is drawable 552 */ 541 553 public boolean isDrawable() { 542 554 return (flags & (FLAG_DELETED + FLAG_INCOMPLETE + FLAG_HIDE_IF_DISABLED)) == 0; … … 764 776 /** 765 777 * Returns {@link #getKeys()} for which {@code key} does not fulfill {@link #isUninterestingKey}. 778 * @return list of interesting tags 766 779 */ 767 780 public Map<String, String> getInterestingTags() { … … 883 896 /** 884 897 * true if this object has direction dependent tags (e.g. oneway) 898 * @return {@code true} if this object has direction dependent tags 885 899 */ 886 900 public boolean hasDirectionKeys() { … … 888 902 } 889 903 904 /** 905 * true if this object has the "reversed diretion" flag enabled 906 * @return {@code true} if this object has the "reversed diretion" flag enabled 907 */ 890 908 public boolean reversedDirection() { 891 909 return (flags & FLAG_DIRECTION_REVERSED) != 0; … … 1082 1100 Return true, if this primitive is referred by at least n ways 1083 1101 @param n Minimal number of ways to return true. Must be positive 1102 * @return {@code true} if this primitive is referred by at least n ways 1084 1103 */ 1085 1104 public final boolean isReferredByWays(int n) { … … 1117 1136 * Get and write all attributes from the parameter. Does not fire any listener, so 1118 1137 * use this only in the data initializing phase 1138 * @param other other primitive 1119 1139 */ 1120 1140 public void cloneFrom(OsmPrimitive other) { … … 1325 1345 /** 1326 1346 * Replies the display name of a primitive formatted by <code>formatter</code> 1347 * @param formatter formatter to use 1327 1348 * 1328 1349 * @return the display name … … 1362 1383 /** 1363 1384 * Replies the set of referring relations 1385 * @param primitives primitives to fetch relations from 1364 1386 * 1365 1387 * @return the set of referring relations -
trunk/src/org/openstreetmap/josm/data/osm/QuadBuckets.java
r8846 r9243 17 17 * 18 18 * This class is (no longer) thread safe. 19 * 19 * @param <T> type of primitives 20 * @since 2165 20 21 */ 21 22 public class QuadBuckets<T extends OsmPrimitive> implements Collection<T> { … … 85 86 /** 86 87 * Constructor for root node 88 * @param buckets quadbuckets 87 89 */ 88 90 QBLevel(final QuadBuckets<T> buckets) { -
trunk/src/org/openstreetmap/josm/data/osm/Relation.java
r8510 r9243 349 349 * Obtains all members with member.member == primitive 350 350 * @param primitives the primitives to check for 351 * @return all relation members for the given primitives 351 352 */ 352 353 public Collection<RelationMember> getMembersFor(final Collection<? extends OsmPrimitive> primitives) { -
trunk/src/org/openstreetmap/josm/data/osm/Storage.java
r9067 r9243 68 68 * 69 69 * @author nenik 70 * @param <T> type of stored objects 70 71 */ 71 72 public class Storage<T> extends AbstractSet<T> { … … 104 105 /** 105 106 * Constructs a new {@code Storage} with given capacity. 107 * @param capacity capacity 106 108 */ 107 109 public Storage(int capacity) { … … 266 268 /** 267 269 * Additional mixing of hash 270 * @param h hash 271 * @return new hash 268 272 */ 269 273 private static int rehash(int h) { … … 273 277 /** 274 278 * Finds a bucket for given key. 279 * @param ha hash function 275 280 * 276 281 * @param key The key to compare -
trunk/src/org/openstreetmap/josm/data/osm/User.java
r8840 r9243 189 189 } 190 190 191 /** private constructor, only called from get method. */ 191 /** 192 * Private constructor, only called from get method. 193 * @param uid user id 194 * @param name user name 195 */ 192 196 private User(long uid, String name) { 193 197 this.uid = uid; -
trunk/src/org/openstreetmap/josm/data/osm/Way.java
r8870 r9243 80 80 /** 81 81 * Prevent directly following identical nodes in ways. 82 * @param nodes list of nodes 83 * @return {@code nodes} with consecutive identical nodes removed 82 84 */ 83 85 private static List<Node> removeDouble(List<Node> nodes) { -
trunk/src/org/openstreetmap/josm/data/osm/WaySegment.java
r8990 r9243 48 48 /** 49 49 * Determines and returns the way segment for the given way and node pair. 50 * @param way way 51 * @param first first node 52 * @param second second node 53 * @return way segment 50 54 * @throws IllegalArgumentException if the node pair is not part of way 51 55 */ -
trunk/src/org/openstreetmap/josm/data/osm/visitor/paint/LineClip.java
r8836 r9243 59 59 * Cohen–Sutherland algorithm. 60 60 * See <a href="https://en.wikipedia.org/wiki/Cohen%E2%80%93Sutherland_algorithm">Wikipedia article</a> 61 * @param x1 X coordinate of first point 62 * @param y1 Y coordinate of first point 63 * @param x2 X coordinate of second point 64 * @param y2 Y coordinate of second point 65 * @param xmin minimal X coordinate 66 * @param ymin minimal Y coordinate 67 * @param xmax maximal X coordinate 68 * @param ymax maximal Y coordinate 61 69 * @return true, if line is visible in the given clip region 62 70 */ … … 114 122 /** 115 123 * The outcode of the point. 116 * We cannot use Rectangle.outcode since it does not work with long ints. 124 * We cannot use {@link Rectangle#outcode} since it does not work with long ints. 125 * @param x X coordinate 126 * @param y Y coordinate 127 * @param xmin minimal X coordinate 128 * @param ymin minimal Y coordinate 129 * @param xmax maximal X coordinate 130 * @param ymax maximal Y coordinate 131 * @return outcode 117 132 */ 118 133 private static int computeOutCode(long x, long y, long xmin, long ymin, long xmax, long ymax) { -
trunk/src/org/openstreetmap/josm/data/osm/visitor/paint/MapRendererFactory.java
r9067 r9243 258 258 /** 259 259 * <p>Creates an instance of the currently active renderer.</p> 260 * @param g Graphics 261 * @param viewport Navigatable component 262 * @param isInactiveMode {@code true} if the paint visitor shall render OSM objects such that they look inactive 260 263 * @return an instance of the currently active renderer 261 264 * -
trunk/src/org/openstreetmap/josm/data/osm/visitor/paint/StyledMapRenderer.java
r9102 r9243 1004 1004 * highlights a given point by drawing a rounded rectangle around it. Give the 1005 1005 * size of the object you want to be highlighted, width is added automatically. 1006 * @param p point 1007 * @param size highlight size 1006 1008 */ 1007 1009 private void drawPointHighlight(Point p, int size) { -
trunk/src/org/openstreetmap/josm/data/osm/visitor/paint/WireframeMapRenderer.java
r9067 r9243 222 222 * @param c Third value 223 223 * @param d Fourth value 224 * @return maximumof {@code a}, {@code b}, {@code c}, {@code d} 224 225 */ 225 226 private static int max(int a, int b, int c, int d) { -
trunk/src/org/openstreetmap/josm/data/projection/Ellipsoid.java
r9132 r9243 266 266 * Returns isometric latitude of phi on given first eccentricity (e) 267 267 * @param phi The local latitude (radians). 268 * @param e first eccentricity 268 269 * @return isometric latitude of phi on first eccentricity (e) 269 270 */ … … 286 287 287 288 /** 288 * Returns geographic latitude of isometric latitude of first eccentricity (e) 289 * and epsilon precision 290 * @return geographic latitude of isometric latitude of first eccentricity (e) 291 * and epsilon precision 289 * Returns geographic latitude of isometric latitude of first eccentricity (e) and epsilon precision 290 * @param latIso isometric latitude 291 * @param e first eccentricity 292 * @param epsilon epsilon precision 293 * @return geographic latitude of isometric latitude of first eccentricity (e) and epsilon precision 292 294 */ 293 295 public double latitude(double latIso, double e, double epsilon) { -
trunk/src/org/openstreetmap/josm/data/projection/datum/Datum.java
r7402 r9243 30 30 31 31 /** 32 * Convert lat/lon from this datum to WGS84 datum. 32 * Convert lat/lon from this datum to {@link Ellipsoid#WGS84} datum. 33 * @param ll original lat/lon in this datum 34 * @return lat/lon converted to WGS84 33 35 */ 34 36 LatLon toWGS84(LatLon ll); 35 37 36 38 /** 37 * Convert lat/lon from WGS84 to this datum. 39 * Convert lat/lon from {@link Ellipsoid#WGS84} to this datum. 40 * @param ll original lat/lon in WGS84 41 * @return converted lat/lon in this datum 38 42 */ 39 43 LatLon fromWGS84(LatLon ll); 40 41 44 } -
trunk/src/org/openstreetmap/josm/data/projection/proj/LambertConformalConic.java
r9124 r9243 130 130 /** 131 131 * auxiliary function t 132 * @param lat_rad latitude in radians 133 * @return result 132 134 */ 133 135 protected double t(double lat_rad) { … … 138 140 /** 139 141 * auxiliary function m 142 * @param lat_rad latitude in radians 143 * @return result 140 144 */ 141 145 protected double m(double lat_rad) { -
trunk/src/org/openstreetmap/josm/data/validation/tests/MapCSSTagChecker.java
r9070 r9243 163 163 /** 164 164 * Evaluates given object as {@link Expression} or {@link String} on the matched {@link OsmPrimitive} and {@code matchingSelector}. 165 * @param obj object to evaluate ({@link Expression} or {@link String}) 166 * @param p OSM primitive 167 * @param matchingSelector matching selector 168 * @return result string 165 169 */ 166 170 private static String evaluateObject(final Object obj, final OsmPrimitive p, final Selector matchingSelector) { … … 178 182 /** 179 183 * Creates a fixing command which executes a {@link ChangePropertyCommand} on the specified tag. 184 * @param obj object to evaluate ({@link Expression} or {@link String}) 185 * @return created fix command 180 186 */ 181 187 static FixCommand fixAdd(final Object obj) { … … 193 199 } 194 200 }; 195 196 201 } 197 202 198 203 /** 199 204 * Creates a fixing command which executes a {@link ChangePropertyCommand} to delete the specified key. 205 * @param obj object to evaluate ({@link Expression} or {@link String}) 206 * @return created fix command 200 207 */ 201 208 static FixCommand fixRemove(final Object obj) { … … 217 224 /** 218 225 * Creates a fixing command which executes a {@link ChangePropertyKeyCommand} on the specified keys. 226 * @param oldKey old key 227 * @param newKey new key 228 * @return created fix command 219 229 */ 220 230 static FixCommand fixChangeKey(final String oldKey, final String newKey) { … … 416 426 * Determines the {@code index}-th key/value/tag (depending on {@code type}) of the 417 427 * {@link org.openstreetmap.josm.gui.mappaint.mapcss.Selector.GeneralSelector}. 428 * @param matchingSelector matching selector 429 * @param index index 430 * @param type selector type ("key", "value" or "tag") 431 * @param p OSM primitive 432 * @return argument value, can be {@code null} 418 433 */ 419 434 static String determineArgument(Selector.GeneralSelector matchingSelector, int index, String type, OsmPrimitive p) { … … 447 462 * Replaces occurrences of <code>{i.key}</code>, <code>{i.value}</code>, <code>{i.tag}</code> in {@code s} by the corresponding 448 463 * key/value/tag of the {@code index}-th {@link Condition} of {@code matchingSelector}. 464 * @param matchingSelector matching selector 465 * @param s any string 466 * @param p OSM primitive 467 * @return string with arguments inserted 449 468 */ 450 469 static String insertArguments(Selector matchingSelector, String s, OsmPrimitive p) { … … 494 513 /** 495 514 * Constructs a (localized) message for this deprecation check. 515 * @param p OSM primitive 496 516 * 497 517 * @return a message … … 513 533 /** 514 534 * Constructs a (localized) description for this deprecation check. 535 * @param p OSM primitive 515 536 * 516 537 * @return a description (possibly with alternative suggestions) … … 530 551 * where any placeholders are replaced by values of the matched selector. 531 552 * 553 * @param matchingSelector matching selector 554 * @param p OSM primitive 532 555 * @return a description (possibly with alternative suggestions) 533 556 */ -
trunk/src/org/openstreetmap/josm/gui/IconToggleButton.java
r8840 r9243 31 31 /** 32 32 * Construct the toggle button with the given action. 33 * @param action associated action 33 34 */ 34 35 public IconToggleButton(Action action) { … … 38 39 /** 39 40 * Construct the toggle button with the given action. 41 * @param action associated action 42 * @param isExpert {@code true} if it's reserved to expert mode 40 43 */ 41 44 public IconToggleButton(Action action, boolean isExpert) { -
trunk/src/org/openstreetmap/josm/gui/MainMenu.java
r9204 r9243 573 573 } 574 574 575 /** finds the correct insertion index for a given group and adds separators if necessary */ 575 /** 576 * Finds the correct insertion index for a given group and adds separators if necessary 577 * @param menu menu 578 * @param group group number 579 * @return correct insertion index 580 */ 576 581 private static int getInsertionIndexForGroup(JMenu menu, int group) { 577 582 if (group < 0) -
trunk/src/org/openstreetmap/josm/gui/MapFrame.java
r9078 r9243 330 330 * Call this to add new toggle dialogs to the left button-list 331 331 * @param dlg The toggle dialog. It must not be in the list already. 332 * @param isExpert {@code true} if it's reserved to expert mode 332 333 * @return button allowing to toggle the dialog 333 334 */ … … 631 632 /** 632 633 * Remove panel from top of MapView by class 634 * @param type type of panel 633 635 */ 634 636 public void removeTopPanel(Class<?> type) { … … 644 646 } 645 647 646 /* 648 /** 647 649 * Find panel on top of MapView by class 650 * @param type type of panel 651 * @return found panel 648 652 */ 649 653 public <T> T getTopPanel(Class<T> type) { … … 658 662 659 663 /** 660 * Add component @param c on top of MapView 664 * Add component {@code c} on top of MapView 665 * @param c component 661 666 */ 662 667 public void addTopPanel(Component c) { … … 670 675 */ 671 676 public interface MapModeChangeListener { 677 /** 678 * Trigerred when map mode changes. 679 * @param oldMapMode old map mode 680 * @param newMapMode new map mode 681 */ 672 682 void mapModeChange(MapMode oldMapMode, MapMode newMapMode); 673 683 } -
trunk/src/org/openstreetmap/josm/gui/MapView.java
r9198 r9243 465 465 * <li>otherwise, the top most layer of any type becomes active</li> 466 466 * </ul> 467 * @param layersList lit of layers 467 468 * 468 469 * @return the next active data layer -
trunk/src/org/openstreetmap/josm/gui/NavigatableComponent.java
r9123 r9243 208 208 /** 209 209 * Get the distance in meter that correspond to 100 px on screen. 210 * 210 * 211 211 * @return the distance in meter that correspond to 100 px on screen 212 212 */ … … 217 217 /** 218 218 * Get the distance in meter that correspond to 100 px on screen. 219 * 219 * 220 220 * @param alwaysPositive if true, makes sure the return value is always 221 221 * > 0. (Two points 100 px apart can appear to be identical if the user … … 498 498 499 499 /** 500 * Create a thread that moves the viewport to the given center in an 501 * animated fashion.500 * Create a thread that moves the viewport to the given center in an animated fashion. 501 * @param newCenter new east/north center 502 502 */ 503 503 public void smoothScrollTo(EastNorth newCenter) { … … 583 583 /** 584 584 * Set the new dimension to the view. 585 * @param box box to zoom to 585 586 */ 586 587 public void zoomTo(BoundingXYVisitor box) { … … 662 663 663 664 /** 664 * The *result* does not depend on the current map selection state, 665 * neither does the result *order*. 665 * The *result* does not depend on the current map selection state, neither does the result *order*. 666 666 * It solely depends on the distance to point p. 667 * 668 * @ return a sorted map with the keys representing the distance of669 * their associated nodes to point p.670 * /671 private Map<Double, List<Node>> getNearestNodesImpl(Point p,672 667 * @param p point 668 * @param predicate predicate to match 669 * 670 * @return a sorted map with the keys representing the distance of their associated nodes to point p. 671 */ 672 private Map<Double, List<Node>> getNearestNodesImpl(Point p, Predicate<OsmPrimitive> predicate) { 673 673 Map<Double, List<Node>> nearestMap = new TreeMap<>(); 674 674 DataSet ds = getCurrentDataSet(); … … 768 768 * as the true nearest node is returned. 769 769 * 770 * If no such node is found either, the true nearest 771 * node to p is returned. 770 * If no such node is found either, the true nearest node to p is returned. 772 771 * 773 772 * Finally, if a node is not found at all, null is returned. … … 776 775 * @param predicate this parameter imposes a condition on the returned object, e.g. 777 776 * give the nearest node that is tagged. 778 * 779 * @return A node within snap-distance to point p,780 * 777 * @param useSelected make search depend on selection 778 * 779 * @return A node within snap-distance to point p, that is chosen by the algorithm described. 781 780 */ 782 781 public final Node getNearestNode(Point p, Predicate<OsmPrimitive> predicate, boolean useSelected) { … … 795 794 * as the true nearest node is returned. 796 795 * 797 * If no such node is found either, the true nearest 798 * node to p is returned. 796 * If no such node is found either, the true nearest node to p is returned. 799 797 * 800 798 * Finally, if a node is not found at all, null is returned. … … 803 801 * @param predicate this parameter imposes a condition on the returned object, e.g. 804 802 * give the nearest node that is tagged. 803 * @param useSelected make search depend on selection 805 804 * @param preferredRefs primitives, whose nodes we prefer 806 805 * 807 * @return A node within snap-distance to point p, 808 * that is chosen by the algorithm described. 806 * @return A node within snap-distance to point p, that is chosen by the algorithm described. 809 807 * @since 6065 810 808 */ … … 872 870 873 871 /** 874 * The *result* does not depend on the current map selection state, 875 * neither does the result *order*. 872 * The *result* does not depend on the current map selection state, neither does the result *order*. 876 873 * It solely depends on the distance to point p. 874 * @param p the screen point 875 * @param predicate this parameter imposes a condition on the returned object, e.g. 876 * give the nearest node that is tagged. 877 877 * 878 878 * @return a sorted map with the keys representing the perpendicular 879 879 * distance of their associated way segments to point p. 880 880 */ 881 private Map<Double, List<WaySegment>> getNearestWaySegmentsImpl(Point p, 882 Predicate<OsmPrimitive> predicate) { 881 private Map<Double, List<WaySegment>> getNearestWaySegmentsImpl(Point p, Predicate<OsmPrimitive> predicate) { 883 882 Map<Double, List<WaySegment>> nearestMap = new TreeMap<>(); 884 883 DataSet ds = getCurrentDataSet(); … … 1414 1413 /** 1415 1414 * Set new cursor. 1415 * @param cursor The new cursor to use. 1416 * @param reference A reference object that can be passed to the next set/reset calls to identify the caller. 1416 1417 */ 1417 1418 public void setNewCursor(Cursor cursor, Object reference) { … … 1419 1420 } 1420 1421 1422 /** 1423 * Set new cursor. 1424 * @param cursor the type of predefined cursor 1425 * @param reference A reference object that can be passed to the next set/reset calls to identify the caller. 1426 */ 1421 1427 public void setNewCursor(int cursor, Object reference) { 1422 1428 setNewCursor(Cursor.getPredefinedCursor(cursor), reference); … … 1425 1431 /** 1426 1432 * Remove the new cursor and reset to previous 1433 * @param reference Cursor reference 1427 1434 */ 1428 1435 public void resetCursor(Object reference) { -
trunk/src/org/openstreetmap/josm/gui/SplashScreen.java
r8958 r9243 389 389 /** 390 390 * Sets the tasks to displayed. A HTML formatted list is expected. 391 * @param tasks HTML formatted list of tasks 391 392 */ 392 393 public void setTasks(String tasks) { -
trunk/src/org/openstreetmap/josm/gui/bbox/SlippyMapControler.java
r9078 r9243 64 64 /** 65 65 * Constructs a new {@code SlippyMapControler}. 66 * @param navComp navigatable component 67 * @param contentPane content pane 66 68 */ 67 69 public SlippyMapControler(SlippyMapBBoxChooser navComp, JPanel contentPane) { -
trunk/src/org/openstreetmap/josm/gui/conflict/pair/nodes/NodeListTableCellRenderer.java
r8855 r9243 49 49 /** 50 50 * render a node 51 * @param model 51 * @param model the model 52 52 * @param node the node 53 * @param row the row 53 54 * @param isSelected true, if the current row is selected 54 55 */ -
trunk/src/org/openstreetmap/josm/gui/conflict/pair/properties/PropertiesMergeModel.java
r8510 r9243 101 101 /** 102 102 * replies true if the current decision for the coordinate conflict is <code>decision</code> 103 * @param decision conflict resolution decision 103 104 * 104 105 * @return true if the current decision for the coordinate conflict is <code>decision</code>; … … 111 112 /** 112 113 * replies true if the current decision for the deleted state conflict is <code>decision</code> 114 * @param decision conflict resolution decision 113 115 * 114 116 * @return true if the current decision for the deleted state conflict is <code>decision</code>; -
trunk/src/org/openstreetmap/josm/gui/conflict/tags/MultiValueCellRenderer.java
r9078 r9243 109 109 /** 110 110 * Sets the text of the tooltip for both renderers, this (the JLabel) and the combobox renderer. 111 * @param decision conflict resolution decision 111 112 */ 112 113 protected void renderToolTipText(MultiValueResolutionDecision decision) { -
trunk/src/org/openstreetmap/josm/gui/dialogs/CommandStackDialog.java
r9078 r9243 322 322 * Recursively adds child commands. 323 323 * @param c the command 324 * @param idx index 324 325 * @return the resulting node 325 326 */ -
trunk/src/org/openstreetmap/josm/gui/dialogs/properties/PresetListPanel.java
r8864 r9243 34 34 * Updates the preset list based on the {@code tags} and {@code types}, 35 35 * and associates an interaction with (matching) presets via {@code presetHandler}. 36 * @param types collection of tagging presets types 37 * @param tags colelction of tags 38 * @param presetHandler tagging preset handler 36 39 */ 37 40 public void updatePresets(final Collection<TaggingPresetType> types, final Map<String, String> tags, -
trunk/src/org/openstreetmap/josm/gui/dialogs/validator/ValidatorTreePanel.java
r8840 r9243 349 349 * Selects all errors related to the specified {@code primitives}, i.e. where {@link TestError#getPrimitives()} 350 350 * returns a primitive present in {@code primitives}. 351 * @param primitives collection of primitives 351 352 */ 352 353 public void selectRelatedErrors(final Collection<OsmPrimitive> primitives) { -
trunk/src/org/openstreetmap/josm/gui/download/DownloadSelection.java
r8512 r9243 8 8 /** 9 9 * Add the GUI elements to the dialog. 10 * @param gui download dialog 10 11 */ 11 12 void addGui(DownloadDialog gui); -
trunk/src/org/openstreetmap/josm/gui/layer/geoimage/CorrelateGpxWithImages.java
r9078 r9243 1144 1144 * Match a list of photos to a gpx track with a given offset. 1145 1145 * All images need a exifTime attribute and the List must be sorted according to these times. 1146 * @param images images to match 1147 * @param selectedGpx selected GPX data 1148 * @param offset offset 1149 * @return number of matched points 1146 1150 */ 1147 1151 private int matchGpxTrack(List<ImageEntry> images, GpxData selectedGpx, long offset) { -
trunk/src/org/openstreetmap/josm/gui/layer/geoimage/GeoImageLayer.java
r9078 r9243 598 598 * 599 599 * If successful, fills in the LatLon and EastNorth attributes of passed in image 600 * @param e image entry 600 601 */ 601 602 private static void extractExif(ImageEntry e) { -
trunk/src/org/openstreetmap/josm/gui/layer/geoimage/ImageEntry.java
r8840 r9243 51 51 52 52 /** 53 * getter methods that refer to the temporary value 53 * Returns the cached temporary position value. 54 * @return the cached temporary position value 54 55 */ 55 56 public CachedLatLon getPos() { … … 59 60 } 60 61 62 /** 63 * Returns the cached temporary speed value. 64 * @return the cached temporary speed value 65 */ 61 66 public Double getSpeed() { 62 67 if (tmp != null) … … 65 70 } 66 71 72 /** 73 * Returns the cached temporary elevation value. 74 * @return the cached temporary elevation value 75 */ 67 76 public Double getElevation() { 68 77 if (tmp != null) … … 71 80 } 72 81 82 /** 83 * Returns the cached temporary GPS time value. 84 * @return the cached temporary GPS time value 85 */ 73 86 public Date getGpsTime() { 74 87 if (tmp != null) … … 87 100 88 101 /** 89 * other getter methods 102 * Returns associated file. 103 * @return associated file 90 104 */ 91 105 public File getFile() { … … 93 107 } 94 108 109 /** 110 * Returns EXIF orientation 111 * @return EXIF orientation 112 */ 95 113 public Integer getExifOrientation() { 96 114 return exifOrientation; 97 115 } 98 116 117 /** 118 * Returns EXIF time 119 * @return EXIF time 120 */ 99 121 public Date getExifTime() { 100 122 return getDefensiveDate(exifTime); … … 147 169 148 170 /** 149 * setter methods 171 * Sets the position. 172 * @param pos cached position 150 173 */ 151 174 public void setPos(CachedLatLon pos) { … … 153 176 } 154 177 178 /** 179 * Sets the position. 180 * @param pos position (will be cached) 181 */ 155 182 public void setPos(LatLon pos) { 156 this.pos = new CachedLatLon(pos); 157 } 158 183 setPos(new CachedLatLon(pos)); 184 } 185 186 /** 187 * Sets the speed. 188 * @param speed speed 189 */ 159 190 public void setSpeed(Double speed) { 160 191 this.speed = speed; 161 192 } 162 193 194 /** 195 * Sets the elevation. 196 * @param elevation elevation 197 */ 163 198 public void setElevation(Double elevation) { 164 199 this.elevation = elevation; 165 200 } 166 201 202 /** 203 * Sets associated file. 204 * @param file associated file 205 */ 167 206 public void setFile(File file) { 168 207 this.file = file; 169 208 } 170 209 210 /** 211 * Sets EXIF orientation. 212 * @param exifOrientation EXIF orientation 213 */ 171 214 public void setExifOrientation(Integer exifOrientation) { 172 215 this.exifOrientation = exifOrientation; 173 216 } 174 217 218 /** 219 * Sets EXIF time. 220 * @param exifTime EXIF time 221 */ 175 222 public void setExifTime(Date exifTime) { 176 223 this.exifTime = getDefensiveDate(exifTime); … … 245 292 /** 246 293 * If it has been tagged i.e. matched to a gpx track or retrieved lat/lon from exif 294 * @return {@code true} if it has been tagged 247 295 */ 248 296 public boolean isTagged() { -
trunk/src/org/openstreetmap/josm/gui/layer/gpx/ChooseTrackVisibilityAction.java
r9078 r9243 108 108 109 109 /** 110 * gathers all available data for the tracks and returns them as array of arrays 111 * in the expected column order */ 110 * Gathers all available data for the tracks and returns them as array of arrays 111 * in the expected column order. 112 * @return table data 113 */ 112 114 private Object[][] buildTableContents() { 113 115 Object[][] tracks = new Object[layer.data.tracks.size()][5]; … … 128 130 /** 129 131 * Builds an non-editable table whose 5th column will open a browser when double clicked. 130 * The table will fill its parent. */ 132 * The table will fill its parent. 133 * @param content table data 134 * @return non-editable table 135 */ 131 136 private JTable buildTable(Object[][] content) { 132 137 final String[] headers = {tr("Name"), tr("Description"), tr("Timespan"), tr("Length"), tr("URL")}; -
trunk/src/org/openstreetmap/josm/gui/layer/gpx/DateFilterPanel.java
r9078 r9243 37 37 * Create the panel to filter tracks on GPX layer @param layer by date 38 38 * Preferences will be stored in @param preferencePrefix 39 * If @param enabled = true, the the panel is created as active and filtering occurs immediately. 39 * If @param enabled = true, then the panel is created as active and filtering occurs immediately. 40 * @param layer GPX layer 41 * @param preferencePrefix preference prefix 42 * @param enabled panel initial enabled state 40 43 */ 41 44 public DateFilterPanel(GpxLayer layer, String preferencePrefix, boolean enabled) { -
trunk/src/org/openstreetmap/josm/gui/layer/gpx/ImportAudioAction.java
r8870 r9243 126 126 * timestamp on the wav file (e) (in future) voice recognised markers in the sound recording (f) 127 127 * a single marker at the beginning of the track 128 * @param wavFile : the file to be associated with the markers in the new marker layer 129 * @param markers : keeps track of warning messages to avoid repeated warnings 128 * @param wavFile the file to be associated with the markers in the new marker layer 129 * @param ml marker layer 130 * @param firstStartTime first start time in milliseconds, used for (d) 131 * @param markers keeps track of warning messages to avoid repeated warnings 130 132 */ 131 133 private void importAudio(File wavFile, MarkerLayer ml, double firstStartTime, Markers markers) { -
trunk/src/org/openstreetmap/josm/gui/mappaint/xml/XmlStyleSource.java
r9239 r9243 186 186 * This is useful for multipolygon relations and outer ways of untagged 187 187 * multipolygon relations. 188 * @param p helper 189 * @param scale scale 190 * @param mc multi cascade 188 191 */ 189 192 private void get(OsmPrimitive primitive, boolean closed, WayPrototypesRecord p, Double scale, MultiCascade mc) { -
trunk/src/org/openstreetmap/josm/io/OsmWriter.java
r9231 r9243 49 49 * Do not call this directly. Use {@link OsmWriterFactory} instead. 50 50 * @param out print writer 51 * @param osmConform if {@code true}, prevents modification attributes to be written to the common part 51 52 * @param version OSM API version (0.6) 52 53 */
Note:
See TracChangeset
for help on using the changeset viewer.