Compiling Issues For Java 7 In NetBeans
-
23-09-2019 - |
문제
So I have Java 7 (64bit Windows build 84) and NetBeans 6.8. I want to use the new invokedynamic
stuff in Java 7 and compile from NetBeans but I can't figure out how to get NetBeans to run the program with the right options except when I build it (run fails, build works).
The code needs to be compiled with the option -XDinvokedynamic
and run with -XX:+UnlockExperimentalVMOptions -XX:+EnableMethodHandles -XX:+EnableInvokeDynamic
. So, in the Project Properties dialogue, I change the Additional Compiler Options in Build to include -XDinvokedynamic
but that only affects the build not when I click run.
I believe adding the -XX:+UnlockExperimentalVMOptions -XX:+EnableMethodHandles -XX:+EnableInvokeDynamic
options to the VM Options box in Run works correctly though (although I can't be sure).
So, simply how can I get NetBeans to use compile with -XDinvokedynamic
whether I'm building or just running it?
해결책
필터를 사용해야합니다.그렇게하기가 어렵지 않습니다. 많은 단계가 필요합니다.다음은 몇 가지 예입니다.
http://office.microsoft.com/en-us/infopath-help/filter-the-data-that-is-displayed-in-a-control-ha010024281.aspx
다른 팁
In each project's properties, in the compile part you can specify additional compile options like this one.