Changeset 7864 in josm for trunk/src/org/openstreetmap/josm/tools
- Timestamp:
- 2014-12-20T22:43:20+01:00 (9 years ago)
- Location:
- trunk/src/org/openstreetmap/josm/tools
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/tools/ExifReader.java
r7592 r7864 175 175 176 176 if (Double.isNaN(deg) && Double.isNaN(min) && Double.isNaN(sec)) 177 throw new IllegalArgumentException( );177 throw new IllegalArgumentException("deg, min and sec are NaN"); 178 178 179 179 value = (Double.isNaN(deg) ? 0 : deg + (Double.isNaN(min) ? 0 : (min / 60)) + (Double.isNaN(sec) ? 0 : (sec / 3600))); -
trunk/src/org/openstreetmap/josm/tools/Geometry.java
r7828 r7864 329 329 CheckParameterUtil.ensureValidCoordinates(p4, "p4"); 330 330 331 if (!p1.isValid()) throw new IllegalArgumentException( );331 if (!p1.isValid()) throw new IllegalArgumentException(p1+" is invalid"); 332 332 333 333 // Basically, the formula from wikipedia is used: -
trunk/src/org/openstreetmap/josm/tools/ImageResource.java
r7731 r7864 81 81 public ImageIcon getImageIcon(Dimension dim) { 82 82 if (dim.width < -1 || dim.width == 0 || dim.height < -1 || dim.height == 0) 83 throw new IllegalArgumentException( );83 throw new IllegalArgumentException(dim+" is invalid"); 84 84 Image img = imgCache.get(dim); 85 85 if (img != null) { … … 123 123 public ImageIcon getImageIconBounded(Dimension maxSize) { 124 124 if (maxSize.width < -1 || maxSize.width == 0 || maxSize.height < -1 || maxSize.height == 0) 125 throw new IllegalArgumentException( );125 throw new IllegalArgumentException(maxSize+" is invalid"); 126 126 float realWidth; 127 127 float realHeight; -
trunk/src/org/openstreetmap/josm/tools/Utils.java
r7835 r7864 189 189 public static int mod(int a, int n) { 190 190 if (n <= 0) 191 throw new IllegalArgumentException( );191 throw new IllegalArgumentException("n must be <= 0 but is "+n); 192 192 int res = a % n; 193 193 if (res < 0) { … … 206 206 */ 207 207 public static String join(String sep, Collection<?> values) { 208 if (sep == null) 209 throw new IllegalArgumentException(); 208 CheckParameterUtil.ensureParameterNotNull(sep, "sep"); 210 209 if (values == null) 211 210 return null;
Note:
See TracChangeset
for help on using the changeset viewer.