Class JGrassRasterMapReader
- java.lang.Object
-
- org.hortonmachine.gears.io.grasslegacy.map.JGrassRasterMapReader
-
public class JGrassRasterMapReader extends Object
Creates aJGrassRasterMapReaderfollowing the builder pattern.This class makes it easier to create a reader for GRASS rasters.
- Since:
- 1.1.0
- Author:
- Andrea Antonello (www.hydrologis.com)
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classJGrassRasterMapReader.BuilderFromMapPathBuilder to createJGrassRasterMapReaderthrough the path of the Map.static classJGrassRasterMapReader.BuilderFromPathAndNamesBuilder to createJGrassRasterMapReaderthrough the path of the Location and the name of Mapset and Map.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclose()close the readerStringgetFullMapPath()RasterDatagetNextData()double[]getRange()This assures a range only after the data were read at least onceMapReadergetReader()booleanhasMoreData()booleanopen()Opens the raster map and does some first checking
-
-
-
Method Detail
-
open
public boolean open()
Opens the raster map and does some first checking
- Returns:
- true if everything went alright
-
hasMoreData
public boolean hasMoreData() throws IOException- Returns:
- true if more data are available
- Throws:
IOException
-
getNextData
public RasterData getNextData()
- Returns:
- a next unit of data from the reader
-
getRange
public double[] getRange()
This assures a range only after the data were read at least once- Returns:
- the range
-
getReader
public MapReader getReader()
- Returns:
- the reader that takes care of the raster reading.
-
close
public void close()
close the reader
-
getFullMapPath
public String getFullMapPath()
-
-