@Test @Category(UnitTest.class) public void testGetWritableSize() throws Exception { LongRectangle tiles = new LongRectangle(Integer.MIN_VALUE, Integer.MIN_VALUE, Integer.MAX_VALUE, Integer.MAX_VALUE); KVIterator<TileIdWritable, MrGeoRaster> iter = reader.get(tiles); while (iter.hasNext()) { RasterWritable writable = RasterWritable.toWritable(iter.currentValue()); Assert.assertEquals("Unexpected size: ", writable.getSize(), reader.getWritableSize(writable)); return; } Assert.fail("Didn't retrieve any rasters"); }
protected int getWritableSize(RasterWritable val) { return val.getSize(); }
HdfsMrsImageReader extends MrsImageReader { protected int getWritableSize(RasterWritable val) { return val.getSize(); } }
HdfsMrsImageReader extends MrsImageReader { protected int getWritableSize(RasterWritable val) { return val.getSize(); } @SuppressFBWarnings(value = "PATH_TRAVERSAL_IN", justification = "check will only be used for reading valid MrsPyramids")  HdfsMrsImageReader(HdfsMrsImageDataProvider provider,
    MrsPyramidReaderContext context); }
HdfsMrsImageReader extends MrsImageReader { protected int getWritableSize(RasterWritable val) { return val.getSize(); } @SuppressFBWarnings(value = "PATH_TRAVERSAL_IN", justification = "check will only be used for reading valid MrsPyramids")  HdfsMrsImageReader(HdfsMrsImageDataProvider provider,
    MrsPyramidReaderContext context); @Override int getZoomlevel(); @Override int getTileSize(); KVIterator<TileIdWritable, MrGeoRaster> get(LongRectangle tileBounds); KVIterator<TileIdWritable, MrGeoRaster> get(TileIdWritable startKey,
    TileIdWritable endKey); @Override boolean canBeCached(); @Override long calculateTileCount(); @Override void close(); @Override boolean exists(TileIdWritable key); @Override KVIterator<TileIdWritable, MrGeoRaster> get(); @SuppressWarnings({"unchecked", "squid:S1166"}) // Exception caught and handled @Override MrGeoRaster get(TileIdWritable key); @Override KVIterator<Bounds, MrGeoRaster> get(Bounds bounds); int getMaxPartitions(); int getPartitionIndex(TileIdWritable key); @SuppressWarnings("squid:S1166") // Exception caught and handled @SuppressFBWarnings(value = "BC_UNCONFIRMED_CAST_OF_RETURN_VALUE", justification = "We _are_ checking!") MapFileReaderWrapper getReaderWrapper(int partitionIndex); }
HdfsMrsImageReader extends MrsImageReader { protected int getWritableSize(RasterWritable val) { return val.getSize(); } @SuppressFBWarnings(value = "PATH_TRAVERSAL_IN", justification = "check will only be used for reading valid MrsPyramids")  HdfsMrsImageReader(HdfsMrsImageDataProvider provider,
    MrsPyramidReaderContext context); @Override int getZoomlevel(); @Override int getTileSize(); KVIterator<TileIdWritable, MrGeoRaster> get(LongRectangle tileBounds); KVIterator<TileIdWritable, MrGeoRaster> get(TileIdWritable startKey,
    TileIdWritable endKey); @Override boolean canBeCached(); @Override long calculateTileCount(); @Override void close(); @Override boolean exists(TileIdWritable key); @Override KVIterator<TileIdWritable, MrGeoRaster> get(); @SuppressWarnings({"unchecked", "squid:S1166"}) // Exception caught and handled @Override MrGeoRaster get(TileIdWritable key); @Override KVIterator<Bounds, MrGeoRaster> get(Bounds bounds); int getMaxPartitions(); int getPartitionIndex(TileIdWritable key); @SuppressWarnings("squid:S1166") // Exception caught and handled @SuppressFBWarnings(value = "BC_UNCONFIRMED_CAST_OF_RETURN_VALUE", justification = "We _are_ checking!") MapFileReaderWrapper getReaderWrapper(int partitionIndex);  }