我想在我的MIDlet中实现AES加密,为此,我向项目添加了Bouncy城堡库(J2ME版本)。 IDE没有显示错误,但是在尝试构建时出现错误:
...\nbproject\build-impl.xml:357:
java.lang.NullPointerException
at org.netbeans.modules.j2me.common.ant.LibletUtils.getJarManifestAttributes(LibletUtils.java:70)
at org.netbeans.modules.j2me.common.ant.ExtractTask.execute(ExtractTask.java:110)
at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:292)
at sun.reflect.GeneratedMethodAccessor308.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
at org.apache.tools.ant.Task.perform(Task.java:348)
at org.apache.tools.ant.Target.execute(Target.java:435)
at org.apache.tools.ant.Target.performTasks(Target.java:456)
at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1393)
at org.apache.tools.ant.Project.executeTarget(Project.java:1364)
at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41)
at org.apache.tools.ant.Project.executeTargets(Project.java:1248)
at org.apache.tools.ant.module.bridge.impl.BridgeImpl.run(BridgeImpl.java:286)
at org.apache.tools.ant.module.run.TargetExecutor.run(TargetExecutor.java:555)
at org.netbeans.core.execution.RunClassThread.run(RunClassThread.java:153)
我正在使用Netbeans 8.02,MIDlet平台类型为CLDC。我尝试了多个版本的充气城堡:
-119
-145
-160
但是我在所有这些中都得到了相同的错误。某些教程说,使用附加参数进行最高级别的混淆可以有所帮助,但没有帮助。