This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Summary: | NullPointerException at java.io.File.<init> | ||
---|---|---|---|
Product: | xml | Reporter: | alibaba88 |
Component: | JAXB | Assignee: | Svata Dedic <sdedic> |
Status: | NEW --- | ||
Severity: | normal | CC: | alibaba88 |
Priority: | P3 | ||
Version: | 8.1 | ||
Hardware: | All | ||
OS: | All | ||
Issue Type: | DEFECT | Exception Reporter: | 226221 |
Attachments: | stacktrace |
Description
alibaba88
2016-09-14 06:46:08 UTC
Created attachment 162042 [details]
stacktrace
I now also tried using the JAXB wizard pointing out the xsd file via a url path. It gives the exact same error. The error occurs immidiately after clicking "finish" in the JABXB wizard. Then its impossible to change the filepath using the wizard, it ignores all changes when clicking finish. I also cleared all changes and opened the project in NetBeans 8.02 and tried to create the JAXB binding there which gave exactly the same error. When selecting "Regenerate java code" on the "JAXB Bindings" in the ide, the log says: ant -f C:\\Users\\andlil\\Desktop\\DeskDocs\\NetBeansProjects\\eCommerceWSProxyTop\\eCommerceWSProxyNB jaxb-code-generation xjc-typedef-target: jaxb-code-generation: failure in the XJC task. Use the Ant -verbose switch for more details C:\Users\andlil\Desktop\DeskDocs\NetBeansProjects\eCommerceWSProxyTop\eCommerceWSProxyNB\nbproject\xml_binding_build.xml:15: grammar is not specified BUILD FAILED (total time: 0 seconds) It creates the \conf\xml-resources\jaxb... directory and xsd file in the folder where the source code is placed, in this case xxx\NetBeansProjects\eCommerceWSProxyTop\eCommerceWSProxy\conf\xml-resources\jaxb and the sources are placed on xxx\NetBeansProjects\eCommerceWSProxyTop\eCommerceWSProxy\src but it seems to be assuming that the directory is on same parent directory as the build directory. The NetBeans project directory (where the build folder resides) is placed on this path (they share the same parentfolder): xxx\NetBeansProjects\eCommerceWSProxyTop\eCommerceWSProxyNB\build So I can't produce a JAXB binding at all, I've tried all variations I could see. In the generated file xml_binding_build.xml within the target: <target name="jaxb-code-generation" depends="xjc-typedef-target,-do-init,-init-macrodef-javac"> the schema tag is generated empty <schema file=""/> if I edit the build file and replaces that with <schema file="../eCommerceWSProxy/conf/xml-resources/jaxb/StoreInformation/storeInformation.xsd"/> the "Regenerate Java Code" on the on the JAXB binding in the GUI works and generates code. However this is a generated build file that shouldn't be edited since it may be overwritten. The JAXB wizard still refuses any changes done using "Change JAXB option" on the JAXB binding in the GUI. So the JAXB wizard doesn't misbehave when the sources folder is placed on another parent folder then where the build folder resides(project folder), and it fails to set where the schema file resides when it generates the xml_binding_build.xml I now also installed NetBeans 8.2 and the exact same defect remains. When the sourcefolder is separated to a parallell directory outside the NetBeans project folder the JAXB wizard to configure a new XML binding doesn't work at all. After assigning a Binding name, a package name and pointing out a xsd schema file on my local disk the Configure XML binding just blinks when pressing Finish button and nothing happens. The dialog stays open and no bindings whatsoever is created. In order to keep the NetBeans project files apart from the application source files it must be a common way to place the source directory outside the project folder, and everything else in NetBeans works ok with that setup. The JAXB wizard needs to be fixed to support that. |