refactor: PbfTileDataSource -> UrlTileDataSource

This commit is contained in:
Hannes Janetzek
2014-01-19 23:23:16 +01:00
parent 77088b84ad
commit 9ed4bb6ec5
9 changed files with 34 additions and 24 deletions

View File

@@ -76,9 +76,9 @@ public class LwHttp {
mHttpRequest.abort();
}
private PbfTileDataSource mDataSource;
private UrlTileDataSource mDataSource;
public boolean sendRequest(Tile tile, PbfTileDataSource dataSource) throws IOException {
public boolean sendRequest(Tile tile, UrlTileDataSource dataSource) throws IOException {
mDataSource = dataSource;
byte[] request = mRequestBuffer;

View File

@@ -21,6 +21,7 @@ import org.oscim.tiling.MapTile;
import org.oscim.tiling.source.ITileCache;
import org.oscim.tiling.source.ITileDataSink;
import org.oscim.tiling.source.ITileDataSource;
import org.oscim.tiling.source.ITileDecoder;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
@@ -28,13 +29,13 @@ import org.slf4j.LoggerFactory;
*
*
*/
public abstract class PbfTileDataSource implements ITileDataSource {
static final Logger log = LoggerFactory.getLogger(PbfTileDataSource.class);
public abstract class UrlTileDataSource implements ITileDataSource {
static final Logger log = LoggerFactory.getLogger(UrlTileDataSource.class);
protected LwHttp mConn;
protected final PbfDecoder mTileDecoder;
protected final ITileDecoder mTileDecoder;
public PbfTileDataSource(PbfDecoder tileDecoder, ITileCache cache) {
public UrlTileDataSource(ITileDecoder tileDecoder, ITileCache cache) {
mTileDecoder = tileDecoder;
}