Ignore:
Timestamp:
2015-02-17T14:05:54+01:00 (10 years ago)
Author:
malcolmh
Message:

coast/land processing

File:
1 edited

Legend:

Unmodified
Added
Removed
  • applications/editors/josm/plugins/seachart/src/s57/S57val.java

    r30992 r31014  
    1010package s57;
    1111
    12 import java.util.ArrayList;
    13 import java.util.EnumMap;
     12import java.util.*;
    1413
    1514import s57.S57att.*;
     
    12431242        }
    12441243
     1244        static class KeyVal {
     1245                Att key;
     1246                Object val;
     1247                KeyVal(Att k, Object v) {
     1248                        key = k;
     1249                        val = v;
     1250                }
     1251        }
     1252       
     1253        private static final HashMap<String, KeyVal> OSMtags = new HashMap<String, KeyVal>();
     1254        static {
     1255                OSMtags.put("wetland=tidalflat", new KeyVal(Att.DRVAL2, (double)0));
     1256        }
     1257       
     1258        public static AttVal OSMatt(String key, String val) {
     1259                KeyVal att = OSMtags.get(key + "=" + val);
     1260                if (att != null) {
     1261                        return new AttVal(att.key, Conv.F, att.val);
     1262                }
     1263                return new AttVal(Att.UNKATT, Conv.A, null);
     1264        }
     1265
    12451266}
Note: See TracChangeset for help on using the changeset viewer.