Package org.openstreetmap.osmosis.core.container.v0_6

Examples of org.openstreetmap.osmosis.core.container.v0_6.RelationContainerIterator


          if (reader.getLocalName().equals(ELEMENT_NAME_NODE)) {
            sink.process(new NodeContainer(readNode()));
          } else if (reader.getLocalName().equals(ELEMENT_NAME_WAY)) {
            sink.process(new WayContainer(readWay()));
          } else if (reader.getLocalName().equals(ELEMENT_NAME_RELATION)) {
            sink.process(new RelationContainer(readRelation()));
          } else {
            readUnknownElement();
          }
        }
View Full Code Here


      buildRelationMembers(osmRelation, relation.getMemidsList(), relation.getRolesSidList(),
          relation.getTypesList(), fieldDecoder);

      // Add the bound object to the results.
      decodedEntities.add(new RelationContainer(osmRelation));
    }
  }
View Full Code Here

 
  /**
   * {@inheritDoc}
   */
  public void end() {
    getSink().process(new RelationContainer(relation));
  }
View Full Code Here

  /**
   * {@inheritDoc}
   */
  @Override
  protected EntityContainerFactory<Relation> getContainerFactory() {
    return new RelationContainerFactory();
  }
View Full Code Here

    sources.add(new UpcastIterator<EntityContainer, NodeContainer>(
        new NodeContainerIterator(nodeDao.iterate())));
    sources.add(new UpcastIterator<EntityContainer, WayContainer>(
        new WayContainerIterator(wayDao.iterate())));
    sources.add(new UpcastIterator<EntityContainer, RelationContainer>(
        new RelationContainerIterator(relationDao.iterate())));
   
    return new MultipleSourceIterator<EntityContainer>(sources);
  }
View Full Code Here

    resultSets.add(
        new UpcastIterator<EntityContainer, WayContainer>(
            new WayContainerIterator(wayDao.iterate("bbox_"))));
    resultSets.add(
        new UpcastIterator<EntityContainer, RelationContainer>(
            new RelationContainerIterator(relationDao.iterate("bbox_"))));
   
    // Merge all readers into a single result iterator and return.     
    return new MultipleSourceIterator<EntityContainer>(resultSets);
  }
View Full Code Here

    sources.add(new UpcastIterator<EntityContainer, NodeContainer>(
        new NodeContainerIterator(nodeDao.iterate())));
    sources.add(new UpcastIterator<EntityContainer, WayContainer>(
        new WayContainerIterator(wayDao.iterate())));
    sources.add(new UpcastIterator<EntityContainer, RelationContainer>(
        new RelationContainerIterator(relationDao.iterate())));
   
    return new MultipleSourceIterator<EntityContainer>(sources);
  }
View Full Code Here

      resultSets.add(
          new UpcastIterator<EntityContainer, WayContainer>(
              new WayContainerIterator(new WayReader(dbCtx, "box_way_list"))));
      resultSets.add(
          new UpcastIterator<EntityContainer, RelationContainer>(
              new RelationContainerIterator(new RelationReader(dbCtx, "box_relation_list"))));
     
      // Merge all readers into a single result iterator and return.     
      return new MultipleSourceIterator<EntityContainer>(resultSets);
     
    } catch (SQLException e) {
View Full Code Here

    sources.add(
        new UpcastIterator<EntityContainer, WayContainer>(
            new WayContainerIterator(wayManager.iterate())));
    sources.add(
        new UpcastIterator<EntityContainer, RelationContainer>(
            new RelationContainerIterator(relationManager.iterate())));
   
    return new MultipleSourceIterator<EntityContainer>(sources);
  }
View Full Code Here

                Entity entity = converter.toEntity(feature, id);
                EntityContainer container;
                if (entity instanceof Node) {
                    container = new NodeContainer((Node) entity);
                } else {
                    container = new WayContainer((Way) entity);
                }

                ChangeAction action = diff.changeType().equals(ChangeType.ADDED) ? ChangeAction.Create
                        : diff.changeType().equals(ChangeType.MODIFIED) ? ChangeAction.Modify
                                : ChangeAction.Delete;
View Full Code Here

TOP

Related Classes of org.openstreetmap.osmosis.core.container.v0_6.RelationContainerIterator

Copyright © 2018 www.massapicom. 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.