Update bbox
This commit is contained in:
parent
fdb4e1721e
commit
7c9352f903
2 changed files with 18 additions and 4 deletions
|
@ -364,7 +364,7 @@ public class OsmandRegions {
|
|||
quadTree = new QuadTree<String>(new QuadRect(0, 0, Integer.MAX_VALUE, Integer.MAX_VALUE),
|
||||
8, 0.55f);
|
||||
final ResultMatcher<BinaryMapDataObject> resultMatcher = new ResultMatcher<BinaryMapDataObject>() {
|
||||
int c = 0;
|
||||
// int c = 0;
|
||||
@Override
|
||||
public boolean publish(BinaryMapDataObject object) {
|
||||
if (object.getPointsLength() < 1) {
|
||||
|
@ -372,9 +372,9 @@ public class OsmandRegions {
|
|||
}
|
||||
initTypes(object);
|
||||
String nm = object.getNameByType(downloadNameType);
|
||||
if(nm != null) {
|
||||
System.out.println((c++) +" " + nm);
|
||||
}
|
||||
// if(nm != null) {
|
||||
// System.out.println((c++) +" " + nm);
|
||||
// }
|
||||
if (!countriesByDownloadName.containsKey(nm)) {
|
||||
LinkedList<BinaryMapDataObject> ls = new LinkedList<BinaryMapDataObject>();
|
||||
countriesByDownloadName.put(nm, ls);
|
||||
|
|
|
@ -5,6 +5,7 @@ import java.io.Closeable;
|
|||
import java.io.EOFException;
|
||||
import java.io.File;
|
||||
import java.io.FileInputStream;
|
||||
import java.io.FileOutputStream;
|
||||
import java.io.IOException;
|
||||
import java.io.InputStream;
|
||||
import java.io.OutputStream;
|
||||
|
@ -212,6 +213,19 @@ public class Algorithms {
|
|||
}
|
||||
|
||||
|
||||
public static void fileCopy(File src, File dst) throws IOException {
|
||||
FileOutputStream fout = new FileOutputStream(dst);
|
||||
try {
|
||||
FileInputStream fin = new FileInputStream(src);
|
||||
try {
|
||||
Algorithms.streamCopy(fin, fout);
|
||||
} finally {
|
||||
fin.close();
|
||||
}
|
||||
} finally {
|
||||
fout.close();
|
||||
}
|
||||
}
|
||||
public static void streamCopy(InputStream in, OutputStream out) throws IOException{
|
||||
byte[] b = new byte[BUFFER_SIZE];
|
||||
int read;
|
||||
|
|
Loading…
Reference in a new issue