Browse Source

Search Nodes in addition to DenseNodes

Johannes Hofmann 7 years ago
parent
commit
f478fc1e07
1 changed files with 8 additions and 1 deletions
  1. 8
    1
      src/main.rs

+ 8
- 1
src/main.rs View File

@@ -255,7 +255,14 @@ fn run() -> Result<(), Box<Error>> {
255 255
             // Increment the counter by one for each way.
256 256
             reader.for_each(|element| {
257 257
                 match element {
258
-                    osmpbf::Element::Node(_) => {},
258
+                    osmpbf::Element::Node(node) => {
259
+                        for (_key, val) in node.tags() {
260
+                            if re.is_match(val) {
261
+                                marker_tx.send((node.lat(), node.lon())).unwrap();
262
+                                proxy.wakeup().unwrap();
263
+                            }
264
+                        }
265
+                    },
259 266
                     osmpbf::Element::DenseNode(dnode) => {
260 267
                         for (_key, val) in dnode.tags() {
261 268
                             if re.is_match(val) {