Package org.geotools.data.directory

Examples of org.geotools.data.directory.DirectoryDataStore.createSchema()


       
        SimpleFeatureTypeBuilder tb = new SimpleFeatureTypeBuilder();
        tb.setName("foo");
        tb.add("geom", Polygon.class);
        tb.add("bar", Integer.class);
        ds.createSchema(tb.buildFeatureType());
       
        SimpleFeatureType ft = ds.getSchema("foo");
        assertNotNull(ft);
       
        //clean up
View Full Code Here


        ShapefileDataStoreFactory shpFactory = new ShapefileDataStoreFactory();
        DirectoryDataStore dir = new DirectoryDataStore(mosaic.getFile(),
            new ShapefileDataStoreFactory.ShpFileStoreFactory(shpFactory, new HashMap()));

        try {
           dir.createSchema(typeBuilder.buildFeatureType());

           FeatureWriter<SimpleFeatureType, SimpleFeature> w =
                   dir.getFeatureWriterAppend(mosaic.getName(), Transaction.AUTO_COMMIT);

           try {
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.