NetBeans 8


Is it possible to install jMonkey plugins in NB 8? I’m encountering a problem when SDK core dependency is not ok: “The plugin Java SE Projects is requested in implementation version 46.”. This issue is probably due to different versions of Java plugin of Java SE group which provided in different versions for NB 7.3.1 and NB 8.0.

I’m going for either full Java 8 support in jMonkey SDK or jMonkey plugins in NB 8. Since I cannot install latest plugins from invalid (8.0) update site in jMonkey SDK (7.3.1), I wanted to go in opposite direction, but then this issue has been encountered.

Any advice? I would rather not use two environments to work on one project if possible - for example SDK + InteliJ or SDK + NB 8.

Thank you,

No, you should generally not install the jME plugins in a NetBeans installation. To use JDK8 to develop and run projects, just reference your JDK8 in the “Tools->Platforms” settings page and set it as the used JDK for single projects, or if you want to start the whole SDK under Java8, you can configure the JDK path in the config file:

Thanks for quick response!

Code will obviously compile and run :slight_smile: - it was the first think which I have configured after installing SDK. Unfortunately,SDK will not provide IDE features (for new things from Java 8 ) like auto complete or syntax support, because it is a responsibility of Java:Java SE plugin’s, not compiler’s.

Anyway, I haven never been working with NetBeans, so I might not be right.

Yeah you don’t get auto-completion etc. for the Java8 language features but it still works fine and you can use these features if you know the syntax. Everything else works as always, so you don’t break current auto-completion and javadoc etc. features of the IDE

Hmm, I had to disable Java support plugin to make “false” compilation error disappear from editor. I have no language support at all now. Are you planning to release NB 8 based SDK?

The 3.1 release will be based on whatever is the current version of the base platform is at that point, yes. We don’t put out releases just because NB updated the base platform though.

Generally I’d suggest using new Java platform features basically only from the point on when the next release is out though… For example Android and iOS don’t support Java 8 features completely yet etc.

Edit: And btw, why don’t you just ignore the editor errors, the project should compile fine. Also a good check-back about what actual java 8 features you use.

I perfectly understand your approach. Thank you for info about lack of support from iOS - I wasn’t aware of it. Yup, I can ignore errors or disable them, but it’s worth to ask when you evaluate new things - especially when you are lucky enough to talk with a contributor.

If you absolutely have to get this to work you can try and compile and use the github version of the SDK, its based on NB Platform 8 (at the moment). Theres some known issues and things that are in flux like library set names, so the BasicGame template doesn’t work without reconfiguration. Plus the whole jME project format might change at some point, so at the moment thats only an option for the very adventurous.

I’ve found that much. I wonder if I can just change some manifest of core SDK plugin to require latest Java:Java SE plugin and build it from source. Latest Java:Java SE should not break your core plugin. Am I right? Just out of curiosity :slight_smile: . Thanks to that I’ll fool new NB and install core SDK which is required for other plugins :stuck_out_tongue: .

I guess the inter-dependencies of the java support plugin will require you to do more changes than that. Some APIs moved between plugins etc. in the NB platform and some things that were before defined in the layer.xml file now have to go to Annotations. Its probably less work to use the current github version and change the library names.

It has been awhile, and Java 8 is now the default download from Java’s website & I made the switch. I’d really like to get NetBeans 8 working with jME3. I’m using the github (my fork, anyway), and I notice netbeans 8 is included in it. Have any of you been able to get NetBeans 8 to work with jME3? How’d you go about it?

The development version of the SDK is based on NB8 as you said, it works as well including all plugins if thats what you mean. But the library names have changed, the BasicGame template doesn’t yet reflect that (its not yet 100% clear if the library names will change or not), among other small things. Simply using jME in NB8 was never a problem really…

That is promising to know it works. However, I get the same error Robert had in the first post, “Some Projects require Java SE Projects plugin to be installed … requested implementation 46”. It doesn’t let me click “next” to install the plugins. Do you know how I get around that?

You can’t install the current SDK plugins in NB8. You can use jME (the engine) in NB8 or compile the development version of the SDK.

OK. The compiled development version of the SDK will work with the jME3 plugins? I’m pretty sure I did build it (by doing a “gradelw clean build dist”), but I couldn’t find the SDK binaries to run…? Is there another set of commands I need to use to build the binaries or am I just missing them somewhere?

You need to build the SDK subproject (using ANT or NetBeans) using the zip (or any other deployment) target. Atm its just built from gradle (to check if it has issues) and none of the targets that create any zip or other distribution are called.

Unfortunately, I get an error when trying to compile the SDK on JDK8:

[ant:nb-javac] /home/phr00t/jme3_gitrw/jmonkeyengine/sdk/jme3-terrain-editor/src/com/jme3/gde/terraineditor/ warning: [cast] redundant cast to ProjectAssetManager
[ant:nb-javac] assetFolder = ((ProjectAssetManager)manager).getAssetFolderName();
[ant:nb-javac] ^
[ant:nb-javac] /home/phr00t/jme3_gitrw/jmonkeyengine/sdk/jme3-terrain-editor/src/com/jme3/gde/terraineditor/ error: cannot access LookupProvider
[ant:nb-javac] TerrainLodControl control = new TerrainLodControl(terrain, SceneApplication.getApplication().getCamera());
[ant:nb-javac] ^
[ant:nb-javac] class file for org.netbeans.spi.project.LookupProvider not found

FAILURE: Build failed with an exception.

  • Where:
    Build file ‘/home/phr00t/jme3_gitrw/jmonkeyengine/sdk/build.gradle’ line: 399

  • What went wrong:
    Execution failed for task ‘:sdk:buildSdk’.
    > The following error occurred while executing this line:
    /home/phr00t/jme3_gitrw/jmonkeyengine/netbeans/harness/suite.xml:187: The following error occurred while executing this line:
    /home/phr00t/jme3_gitrw/jmonkeyengine/netbeans/harness/common.xml:220: Compile failed; see the compiler error output for details.

  • Try:
    Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.

@phr00t said: Unfortunately, I get an error when trying to compile the SDK on JDK8:

Should be solved now.

1 Like
@normen said: Should be solved now.

Yay! OK, it did build. I used the command “gradlew clean build dist createZipDistribution”, and everything went fine. However, I still can’t seem to find where it put the binaries to run the built SDK. The ZIP only contains libraries, as far as I can tell. :confused:

As said, you have to create the distro from the ant build script of the SDK.