Changeset 19335 in osm
- Timestamp:
- 2010-01-09T15:03:13+01:00 (15 years ago)
- Location:
- applications/editors/josm/plugins/validator
- Files:
-
- 1 added
- 11 edited
Legend:
- Unmodified
- Added
- Removed
-
applications/editors/josm/plugins/validator/.settings/org.eclipse.jdt.ui.prefs
r10662 r19335 1 # Sun Sep 07 16:57:55 CEST 20081 #Fri Jan 08 08:06:27 CET 2010 2 2 eclipse.preferences.version=1 3 editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true 3 4 formatter_profile=_JOSM 4 5 formatter_settings_version=11 6 sp_cleanup.add_default_serial_version_id=true 7 sp_cleanup.add_generated_serial_version_id=false 8 sp_cleanup.add_missing_annotations=true 9 sp_cleanup.add_missing_deprecated_annotations=true 10 sp_cleanup.add_missing_methods=false 11 sp_cleanup.add_missing_nls_tags=false 12 sp_cleanup.add_missing_override_annotations=false 13 sp_cleanup.add_serial_version_id=false 14 sp_cleanup.always_use_blocks=true 15 sp_cleanup.always_use_parentheses_in_expressions=false 16 sp_cleanup.always_use_this_for_non_static_field_access=false 17 sp_cleanup.always_use_this_for_non_static_method_access=false 18 sp_cleanup.convert_to_enhanced_for_loop=false 19 sp_cleanup.correct_indentation=false 20 sp_cleanup.format_source_code=false 21 sp_cleanup.format_source_code_changes_only=false 22 sp_cleanup.make_local_variable_final=false 23 sp_cleanup.make_parameters_final=false 24 sp_cleanup.make_private_fields_final=true 25 sp_cleanup.make_type_abstract_if_missing_method=false 26 sp_cleanup.make_variable_declarations_final=false 27 sp_cleanup.never_use_blocks=false 28 sp_cleanup.never_use_parentheses_in_expressions=true 29 sp_cleanup.on_save_use_additional_actions=true 30 sp_cleanup.organize_imports=true 31 sp_cleanup.qualify_static_field_accesses_with_declaring_class=false 32 sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true 33 sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true 34 sp_cleanup.qualify_static_member_accesses_with_declaring_class=false 35 sp_cleanup.qualify_static_method_accesses_with_declaring_class=false 36 sp_cleanup.remove_private_constructors=true 37 sp_cleanup.remove_trailing_whitespaces=true 38 sp_cleanup.remove_trailing_whitespaces_all=true 39 sp_cleanup.remove_trailing_whitespaces_ignore_empty=false 40 sp_cleanup.remove_unnecessary_casts=true 41 sp_cleanup.remove_unnecessary_nls_tags=false 42 sp_cleanup.remove_unused_imports=false 43 sp_cleanup.remove_unused_local_variables=false 44 sp_cleanup.remove_unused_private_fields=true 45 sp_cleanup.remove_unused_private_members=false 46 sp_cleanup.remove_unused_private_methods=true 47 sp_cleanup.remove_unused_private_types=true 48 sp_cleanup.sort_members=false 49 sp_cleanup.sort_members_all=false 50 sp_cleanup.use_blocks=false 51 sp_cleanup.use_blocks_only_for_return_and_throw=false 52 sp_cleanup.use_parentheses_in_expressions=false 53 sp_cleanup.use_this_for_non_static_field_access=false 54 sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true 55 sp_cleanup.use_this_for_non_static_method_access=false 56 sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true -
applications/editors/josm/plugins/validator/build.xml
r19304 r19335 27 27 --> 28 28 <property name="commit.message" value="Update to JOSM 2748" /> 29 <property name="plugin.main.version" value="27 48" />29 <property name="plugin.main.version" value="2788" /> 30 30 31 31 -
applications/editors/josm/plugins/validator/src/org/openstreetmap/josm/plugins/validator/GridLayer.java
r18593 r19335 138 138 * Visitor that highlights all cells the selected primitives go through 139 139 */ 140 class HighlightCellVisitor extends AbstractVisitor 140 static class HighlightCellVisitor extends AbstractVisitor 141 141 { 142 142 /** The MapView */ -
applications/editors/josm/plugins/validator/src/org/openstreetmap/josm/plugins/validator/OSMValidatorPlugin.java
r19224 r19335 39 39 import org.openstreetmap.josm.plugins.validator.tests.DuplicateWay; 40 40 import org.openstreetmap.josm.plugins.validator.tests.DuplicatedWayNodes; 41 import org.openstreetmap.josm.plugins.validator.tests.MultipolygonTest; 41 42 import org.openstreetmap.josm.plugins.validator.tests.NameMismatch; 42 43 import org.openstreetmap.josm.plugins.validator.tests.NodesWithSameName; … … 80 81 /** 81 82 * All available tests 82 * TODO: is there any way to find out automa gically all available tests?83 * TODO: is there any way to find out automatically all available tests? 83 84 */ 84 85 @SuppressWarnings("unchecked") … … 99 100 DuplicateWay.class, // ID 1401 .. 1499 100 101 NameMismatch.class, // ID 1501 .. 1599 102 MultipolygonTest.class, // ID 1601 .. 1699 101 103 }; 102 104 … … 134 136 } 135 137 } catch (final FileNotFoundException e) { 138 // Ignore 136 139 } catch (final IOException e) { 137 140 e.printStackTrace(); … … 157 160 158 161 private ValidateUploadHook uploadHook; 159 162 160 163 @Override 161 164 public void mapFrameInitialized(MapFrame oldFrame, MapFrame newFrame) { … … 166 169 if (Main.pref.hasKey(PreferenceEditor.PREF_DEBUG + ".grid")) 167 170 Main.main.addLayer(new GridLayer(tr("Grid"))); 168 MapView.addLayerChangeListener(this); 171 MapView.addLayerChangeListener(this); 169 172 } else 170 173 MapView.removeLayerChangeListener(this); … … 273 276 } catch (InvocationTargetException ite) { 274 277 ite.getCause().printStackTrace(); 275 JOptionPane.showMessageDialog(Main.parent, 278 JOptionPane.showMessageDialog(Main.parent, 276 279 tr("Error initializing test {0}:\n {1}", test.getClass() 277 280 .getSimpleName(), ite.getCause().getMessage()), … … 280 283 } catch (Exception e) { 281 284 e.printStackTrace(); 282 JOptionPane.showMessageDialog(Main.parent, 285 JOptionPane.showMessageDialog(Main.parent, 283 286 tr("Error initializing test {0}:\n {1}", test.getClass() 284 287 .getSimpleName(), e), -
applications/editors/josm/plugins/validator/src/org/openstreetmap/josm/plugins/validator/Test.java
r18928 r19335 3 3 import static org.openstreetmap.josm.tools.I18n.tr; 4 4 5 import java.awt.GridBagConstraints; 5 6 import java.util.ArrayList; 6 7 import java.util.Collection; … … 32 33 { 33 34 /** Name of the test */ 34 protected String name; 35 protected final String name; 35 36 36 37 /** Description of the test */ 37 protected String description; 38 protected final String description; 38 39 39 40 /** Whether this test is enabled. Enabled by default */ … … 77 78 public Test(String name) 78 79 { 79 this .name = name;80 this(name, null); 80 81 } 81 82 … … 162 163 163 164 GBC a = GBC.eol(); 164 a.anchor = G BC.EAST;165 a.anchor = GridBagConstraints.EAST; 165 166 checkBeforeUpload = new JCheckBox(); 166 167 checkBeforeUpload.setSelected(testBeforeUpload); -
applications/editors/josm/plugins/validator/src/org/openstreetmap/josm/plugins/validator/ValidatorDialog.java
r19226 r19335 438 438 if (!Main.pref.getBoolean(PreferenceEditor.PREF_FILTER_BY_SELECTION, false)) 439 439 return; 440 if (newSelection == null || newSelection.size() == 0)440 if (newSelection.isEmpty()) 441 441 tree.setFilter(null); 442 442 HashSet<OsmPrimitive> filter = new HashSet<OsmPrimitive>(newSelection); -
applications/editors/josm/plugins/validator/src/org/openstreetmap/josm/plugins/validator/tests/CrossingWays.java
r18344 r19335 166 166 * @author frsantos 167 167 */ 168 private class ExtendedSegment 168 private static class ExtendedSegment 169 169 { 170 170 public Node n1, n2; -
applications/editors/josm/plugins/validator/src/org/openstreetmap/josm/plugins/validator/tests/DuplicateWay.java
r18092 r19335 28 28 { 29 29 30 private class WayPair { 30 private static class WayPair { 31 31 public List<LatLon> coor; 32 32 public Map<String, String> keys; -
applications/editors/josm/plugins/validator/src/org/openstreetmap/josm/plugins/validator/tests/TagChecker.java
r19229 r19335 886 886 protected static int TAG_CHECK_INFO = 1270; 887 887 888 private class CheckerElement { 888 private static class CheckerElement { 889 889 public Object tag; 890 890 public Object value; -
applications/editors/josm/plugins/validator/src/org/openstreetmap/josm/plugins/validator/tests/UnconnectedWays.java
r18848 r19335 226 226 // return !w.containsNode(n) 227 227 // && line.ptSegDist(n.getEastNorth().east(), n.getEastNorth().north()) < dist; 228 if (w == null) 228 if (w == null) { 229 229 Main.debug("way null"); 230 return false; 231 } 230 232 if (w.containsNode(n)) 231 233 return false; -
applications/editors/josm/plugins/validator/src/org/openstreetmap/josm/plugins/validator/util/Entities.java
r13497 r19335 341 341 if (firstAmp < 0) 342 342 return str; 343 String res = new String(str.substring(0, firstAmp));343 String res = str.substring(0, firstAmp); 344 344 int len = str.length(); 345 345 for (int i = firstAmp; i < len; i++) {
Note:
See TracChangeset
for help on using the changeset viewer.