Esempio n. 1
0
 @Test
 public void testVectorData() throws TransformException, FactoryException {
   SimpleFeatureType pinType = Placemark.createPinFeatureType();
   SimpleFeatureType gcpType = Placemark.createGcpFeatureType();
   SimpleFeatureType unknownType = PlacemarkDescriptorRegistryTest.createYetUnknownFeatureType();
   testVectorData(new VectorDataNode("Pins", pinType), "Pins", pinType);
   testVectorData(new VectorDataNode("GCPs", gcpType), "GCPs", gcpType);
   testVectorData(new VectorDataNode("Imported", unknownType), "Imported", unknownType);
 }
Esempio n. 2
0
  @Test
  public void testVectorDataGroup() throws TransformException, FactoryException {
    Product p = new Product("p", "pt", 512, 512);
    assertEquals(2, p.getVectorDataGroup().getNodeCount());

    SimpleFeatureType pinType = Placemark.createPinFeatureType();
    SimpleFeatureType gcpType = Placemark.createGcpFeatureType();

    p.getVectorDataGroup().add(new VectorDataNode("My Pins", pinType));
    p.getVectorDataGroup().add(new VectorDataNode("My GCPs", gcpType));
    assertEquals(4, p.getVectorDataGroup().getNodeCount());

    testVectorData(p, "My Pins", pinType);
    testVectorData(p, "My GCPs", gcpType);
  }