Changeset 29074 in osm for applications/editors/josm/plugins/smed2/src
- Timestamp:
- 2012-12-14T15:35:19+01:00 (12 years ago)
- Location:
- applications/editors/josm/plugins/smed2/src
- Files:
-
- 10 added
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
applications/editors/josm/plugins/smed2/src/panels/PanelMain.java
r28938 r29074 13 13 14 14 import smed2.Smed2Action; 15 16 import S57.S57dat;17 15 18 16 public class PanelMain extends JPanel { -
applications/editors/josm/plugins/smed2/src/s57/S57dat.java
r28938 r29074 1 package S57;1 package s57; 2 2 3 3 import static org.openstreetmap.josm.tools.I18n.tr; … … 20 20 import smed2.Smed2Action; 21 21 22 import S57.S57obj;23 import S57.S57att;24 import S57.S57val;22 import s57.S57obj; 23 import s57.S57att; 24 import s57.S57val; 25 25 26 26 public class S57dat extends JPanel { -
applications/editors/josm/plugins/smed2/src/s57/S57val.java
r29049 r29074 20 20 static class S57key { 21 21 Conv conv; 22 EnumMap map;23 S57key(Conv c, EnumMap m) {22 EnumMap<?, ?> map; 23 S57key(Conv c, EnumMap<?, ?> m) { 24 24 conv = c; map = m; 25 25 } … … 1096 1096 1097 1097 public static Integer encodeValue(String val, Att att) { // Convert OSeaM attribute value string to S57 attribute value 1098 EnumMap map = keys.get(att).map;1098 EnumMap<?, ?> map = keys.get(att).map; 1099 1099 for (Object item : map.keySet()) { 1100 1100 if (((S57enum)map.get(item)).val.equals(val)) … … 1111 1111 return (String)attval.val; 1112 1112 case E: 1113 return (String)((EnumMap )attval.val).get(attval.att);1113 return (String)((EnumMap<?, ?>)attval.val).get(attval.att); 1114 1114 case L: 1115 1115 String str = ""; 1116 for (Object item : (ArrayList )attval.val) {1116 for (Object item : (ArrayList<?>)attval.val) { 1117 1117 if (!str.isEmpty()) str += ";"; 1118 1118 str += keys.get(attval.att).map.get(item); … … 1127 1127 } 1128 1128 1129 public static Enum enumValue(String val, Att att) { // Convert OSeaM attribute value string to OSeaM enumeration1130 EnumMap map = keys.get(att).map;1131 Enum unkn = null;1129 public static Enum<?> enumValue(String val, Att att) { // Convert OSeaM attribute value string to OSeaM enumeration 1130 EnumMap<?, ?> map = keys.get(att).map; 1131 Enum<?> unkn = null; 1132 1132 for (Object item : map.keySet()) { 1133 if (unkn == null) unkn = (Enum )item;1133 if (unkn == null) unkn = (Enum<?>)item; 1134 1134 if (((S57enum)map.get(item)).val.equals(val)) 1135 return (Enum )item;1135 return (Enum<?>)item; 1136 1136 } 1137 1137 return unkn; -
applications/editors/josm/plugins/smed2/src/smed2/Smed2Action.java
r28938 r29074 1 1 package smed2; 2 2 3 import java.awt.Dialog;4 3 import java.awt.Dimension; 5 4 import java.awt.event.ActionEvent; … … 15 14 import org.openstreetmap.josm.Main; 16 15 17 import S57.S57dat;16 import s57.S57dat; 18 17 19 18 import panels.PanelMain;
Note:
See TracChangeset
for help on using the changeset viewer.