SKMaps.jar FileNotFoundException

时间:2016-05-22 18:57:27

标签: java android skmaps

我正在尝试为我的Android项目初始化SKMaps库,并且我不断收到导致应用崩溃的FileNotFound异常。这是堆栈跟踪:

05-22 11:33:39.631 17610-17639/com.fedorparetsky.parcare W/System.err: java.io.FileNotFoundException: [Ljava.io.File;@3681ebc4/SKMaps/SKMaps.zip: open failed: ENOENT (No such file or directory)
05-22 11:33:39.632 17610-17639/com.fedorparetsky.parcare W/System.err:     at libcore.io.IoBridge.open(IoBridge.java:456)
05-22 11:33:39.632 17610-17639/com.fedorparetsky.parcare W/System.err:     at java.io.FileOutputStream.<init>(FileOutputStream.java:87)
05-22 11:33:39.632 17610-17639/com.fedorparetsky.parcare W/System.err:     at java.io.FileOutputStream.<init>(FileOutputStream.java:72)
05-22 11:33:39.632 17610-17639/com.fedorparetsky.parcare W/System.err:     at com.skobbler.ngx.SKPrepareMapTextureThread.a(SourceFile:160)
05-22 11:33:39.632 17610-17639/com.fedorparetsky.parcare W/System.err:     at com.skobbler.ngx.SKPrepareMapTextureThread.a(SourceFile:126)
05-22 11:33:39.632 17610-17639/com.fedorparetsky.parcare W/System.err:     at com.skobbler.ngx.SKPrepareMapTextureThread.run(SourceFile:85)
05-22 11:33:39.632 17610-17639/com.fedorparetsky.parcare W/System.err: Caused by: android.system.ErrnoException: open failed: ENOENT (No such file or directory)
05-22 11:33:39.632 17610-17639/com.fedorparetsky.parcare W/System.err:     at libcore.io.Posix.open(Native Method)
05-22 11:33:39.632 17610-17639/com.fedorparetsky.parcare W/System.err:     at libcore.io.BlockGuardOs.open(BlockGuardOs.java:186)
05-22 11:33:39.632 17610-17639/com.fedorparetsky.parcare W/System.err:     at libcore.io.IoBridge.open(IoBridge.java:442)
05-22 11:33:39.632 17610-17639/com.fedorparetsky.parcare W/System.err:  ... 5 more

我需要确定/确认将项目中的所有文件正确放入哪里以及这行代码是否正确加载.zip文件:

final SKPrepareMapTextureThread prepThread = new SKPrepareMapTextureThread(this, this.getApplicationContext().getExternalFilesDirs(null).toString() + "/" + "SKMaps/", "SKMaps.zip", this);

我没有通过它在API指南中说明的gradle任务执行此操作,而是将jar添加到构建路径,然后假设使用SKMaps.zip文件准备地图。

0 个答案:

没有答案