Package org.opengis.coverage.grid

Examples of org.opengis.coverage.grid.GridCoverageWriter.dispose()


        } else {
            throw new ServiceException("Could not create a writer for the format Gtopo30!");
        }

        // freeing everything
        writer.dispose();
        this.sourceCoverage.dispose(false);
        this.sourceCoverage = null;
    }
}
View Full Code Here


                gzipOut.finish();
                gzipOut.flush();
            }

            // freeing everything
            writer.dispose();
            this.sourceCoverage.dispose(false);
            this.sourceCoverage = null;
        } catch (Exception e) {
            throw new WcsException(new StringBuffer("Problems Rendering Image").append(
                    e.getMessage()).toString(), e);
View Full Code Here

        GridCoverageWriter writer = format.getWriter(output);
        writer.write(sourceCoverage,
            (GeneralParameterValue[]) writerParams.values().toArray(new GeneralParameterValue[1]));

        writer.dispose();

        this.sourceCoverage.dispose(false);
        this.sourceCoverage = null;
    }
}
View Full Code Here

        // writing
        writer.write(sourceCoverage, new GeneralParameterValue[] {format});

        // freeing everything
        output.flush();
        writer.dispose();
        this.sourceCoverage.dispose(false);
        this.sourceCoverage = null;
    }
}
View Full Code Here

      writer.write(cropped, null);
    }catch (IOException e) {
    }
    finally{
      try{
        writer.dispose();
      }catch (Throwable e) {
      }
    }
    try{
      reader = new GeoTiffReader(writeFile, null);
View Full Code Here

        try {
            writer.write(cropped, null);
        } catch (IOException e) {
        } finally {
            try {
                writer.dispose();
            } catch (Throwable e) {
            }
        }
       
        // release things
View Full Code Here

    GeneralParameterValue[] gpv = {
        params.parameter("GRASS"),
        params.parameter(AbstractGridFormat.GEOTOOLS_WRITE_PARAMS
            .getName().toString()) };
    writer.write(gc1, gpv);
    writer.dispose();

    /** Step 3: Read the just written coverage */
    GridCoverageReader reader2 = new ArcGridReader(wf,hints);
    final GridCoverage2D gc2 = (GridCoverage2D) reader2.read(null);

View Full Code Here

    GeneralParameterValue[] gpv = {
        params.parameter("GRASS"),
        params.parameter(AbstractGridFormat.GEOTOOLS_WRITE_PARAMS
            .getName().toString()) };
    writer.write(gc1, gpv);
    writer.dispose();

    /** Step 3: Read the just written coverage */
    GridCoverageReader reader2 = new ArcGridReader(wf,hints);
    final GridCoverage2D gc2 = (GridCoverage2D) reader2.read(null);

View Full Code Here

        //write out raster to temp file
        File tmpFile = File.createTempFile(e.getTableName(), "raster");

        GridCoverageWriter writer = format.getWriter(tmpFile);
        writer.write(raster, null);
        writer.dispose();

        //create the raster table
        try {
            Connection cx = connPool.getConnection();
            try {
View Full Code Here

          // writing
          writer.write(sourceCoverage, null);
        }finally{
          try{
              // freeing everything
              writer.dispose();
          }catch (Throwable e) {
        // TODO: handle exception
      }
            this.sourceCoverage.dispose(false);
            this.sourceCoverage = null;
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.