Changeset 6142 in josm for trunk/src/org/openstreetmap/josm/data/Preferences.java
- Timestamp:
- 2013-08-11T21:23:19+02:00 (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/data/Preferences.java
r6087 r6142 1288 1288 changed = putListOfStructs(key, setting.getValue()); 1289 1289 } 1290 } ;1290 } 1291 1291 PutVisitor putVisitor = new PutVisitor(); 1292 1292 value.visit(putVisitor); … … 1669 1669 } 1670 1670 1671 public static boolean isEqual(Setting a, Settingb) {1671 public static boolean isEqual(Setting<?> a, Setting<?> b) { 1672 1672 if (a==null && b==null) return true; 1673 1673 if (a==null) return false; … … 1678 1678 return (a.getValue().equals(b.getValue())); 1679 1679 if (a instanceof ListSetting) { 1680 @SuppressWarnings("unchecked") Collection<String> aValue = (Collection ) a.getValue();1681 @SuppressWarnings("unchecked") Collection<String> bValue = (Collection ) b.getValue();1680 @SuppressWarnings("unchecked") Collection<String> aValue = (Collection<String>) a.getValue(); 1681 @SuppressWarnings("unchecked") Collection<String> bValue = (Collection<String>) b.getValue(); 1682 1682 return equalCollection(aValue, bValue); 1683 1683 } 1684 1684 if (a instanceof ListListSetting) { 1685 @SuppressWarnings("unchecked") Collection<Collection<String>> aValue = (Collection ) a.getValue();1686 @SuppressWarnings("unchecked") Collection<List<String>> bValue = (Collection ) b.getValue();1685 @SuppressWarnings("unchecked") Collection<Collection<String>> aValue = (Collection<Collection<String>>) a.getValue(); 1686 @SuppressWarnings("unchecked") Collection<List<String>> bValue = (Collection<List<String>>) b.getValue(); 1687 1687 return equalArray(aValue, bValue); 1688 1688 } 1689 1689 if (a instanceof MapListSetting) { 1690 @SuppressWarnings("unchecked") Collection<Map<String, String>> aValue = (Collection ) a.getValue();1691 @SuppressWarnings("unchecked") Collection<Map<String, String>> bValue = (Collection ) b.getValue();1690 @SuppressWarnings("unchecked") Collection<Map<String, String>> aValue = (Collection<Map<String, String>>) a.getValue(); 1691 @SuppressWarnings("unchecked") Collection<Map<String, String>> bValue = (Collection<Map<String, String>>) b.getValue(); 1692 1692 return equalListOfStructs(aValue, bValue); 1693 1693 }
Note:
See TracChangeset
for help on using the changeset viewer.