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

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


      try {
        sink.initialize(Collections.<String, Object>emptyMap());
        if (publishBound) {
          sink.process(new BoundContainer(bound));
        }
        sink.process(new NodeContainer(createNode()));
        sink.complete();
      } finally {
        sink.release();
      }
    }
View Full Code Here


    sources = new ArrayList<ReleasableIterator<EntityContainer>>();
   
    sources.add(new UpcastIterator<EntityContainer, BoundContainer>(
        new BoundContainerIterator(new ReleasableAdaptorForIterator<Bound>(bounds.iterator()))));
    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())));
   
View Full Code Here

    resultSets.add(
        new UpcastIterator<EntityContainer, BoundContainer>(
            new BoundContainerIterator(new ReleasableAdaptorForIterator<Bound>(bounds.iterator()))));
    resultSets.add(
        new UpcastIterator<EntityContainer, NodeContainer>(
            new NodeContainerIterator(nodeDao.iterate("bbox_"))));
    resultSets.add(
        new UpcastIterator<EntityContainer, WayContainer>(
            new WayContainerIterator(wayDao.iterate("bbox_"))));
    resultSets.add(
        new UpcastIterator<EntityContainer, RelationContainer>(
View Full Code Here

    sources = new ArrayList<ReleasableIterator<EntityContainer>>();
   
    sources.add(new UpcastIterator<EntityContainer, BoundContainer>(
        new BoundContainerIterator(new ReleasableAdaptorForIterator<Bound>(bounds.iterator()))));
    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())));
   
View Full Code Here

      resultSets.add(
          new UpcastIterator<EntityContainer, BoundContainer>(
              new BoundContainerIterator(new ReleasableAdaptorForIterator<Bound>(bounds.iterator()))));
      resultSets.add(
          new UpcastIterator<EntityContainer, NodeContainer>(
              new NodeContainerIterator(new NodeReader(dbCtx, "box_node_list"))));
      resultSets.add(
          new UpcastIterator<EntityContainer, WayContainer>(
              new WayContainerIterator(new WayReader(dbCtx, "box_way_list"))));
      resultSets.add(
          new UpcastIterator<EntityContainer, RelationContainer>(
View Full Code Here

          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

                        getUser(info), info.getChangeset(), tags), nodes);
            } else {
                tmp = new Relation(new CommonEntityData(id, NOVERSION, NODATE, OsmUser.NONE,
                        NOCHANGESET, tags), nodes);
            }
            sink.process(new RelationContainer(tmp));
        }
    }
View Full Code Here

   
    testRelation = new Relation(new CommonEntityData(3456, 0, new Date(), new OsmUser(12, "OsmosisTest"), 0));
    testRelation.getMembers().add(new RelationMember(1234, EntityType.Node, "role1"));
    testRelation.getTags().add(new Tag("test_key1", "test_value1"));
   
    testOsmWriter.process(new RelationContainer(testRelation));
    // Nothing to assert; just expect no exception
  }
View Full Code Here

TOP

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

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.