Examples of OSMTag


Examples of org.opentripplanner.openstreetmap.model.OSMTag

                node = node.getNextSibling();
                continue;
            }
            Element child = (Element) node;
            if (child.getTagName().equals("tag")) {
                OSMTag tag = new OSMTag();
                String key = child.getAttribute("k");
                tag.setK(key.intern());
                String value = child.getAttribute("v");
                if (key.equals("name") || key.equals("highway")) {
                    value = value.intern();
                }
                tag.setV(value);
                osm.addTag(tag);
            }
            node = node.getNextSibling();
        }
    }
View Full Code Here

Examples of org.opentripplanner.openstreetmap.model.OSMTag

            if (relation.hasTag("name")) {
                if (way.hasTag("otp:route_name")) {
                    way.addTag("otp:route_name",
                            addUniqueName(way.getTag("otp:route_name"), relation.getTag("name")));
                } else {
                    way.addTag(new OSMTag("otp:route_name", relation.getTag("name")));
                }
            }
            if (relation.hasTag("ref")) {
                if (way.hasTag("otp:route_ref")) {
                    way.addTag("otp:route_ref",
                            addUniqueName(way.getTag("otp:route_ref"), relation.getTag("ref")));
                } else {
                    way.addTag(new OSMTag("otp:route_ref", relation.getTag("ref")));
                }
            }
        }
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.