I would like to use XML schema validation and content assist in the Eclipse XML editor for .content.xml files.
Following the advise in https://forums.adobe.com/message/5289292#5289292 I tried the following:
- Obtain http://localhost:4502/crx/explorer/nodetypes/list.jsp?view=cnf&selection= and store it as a file nodetypes.cnd
- Run cnd2xsd converter as follows:
java -jar ~/Software/cnd2xsd-R1.0.0-SNAPSHOT.jar -fc nodetypes.cnd -fx jcr_nodetypes.xsd -r root -rtype root -ns http://www.jcp.org/jcr/1.0 -nsp jcr
Unfortunately, all I got is an exception that seems to complain about something in the nodetypes.cnd file:
javax.jcr.nodetype.InvalidNodeTypeDefinitionException: [{internal}NodeType#{internal}supertypes] auto-created property must have a default value
at org.apache.jackrabbit.core.nodetype.NodeTypeManagerImpl.registerNodeTypes(NodeTypeManagerImpl.java:585)
at org.apache.jackrabbit.commons.cnd.CndImporter.registerNodeTypes(CndImporter.java:157)
at org.apache.jackrabbit.commons.cnd.CndImporter.registerNodeTypes(CndImporter.java:74)
at edu.vt.cs.cnd2xsd.Cnd2XsdConverter.RegisterCustomNodeTypes(Cnd2XsdConverter.java:163)
at edu.vt.cs.cnd2xsd.Cnd2XsdConverter.init(Cnd2XsdConverter.java:648)
at edu.vt.cs.cnd2xsd.Cnd2XsdConverter.main(Cnd2XsdConverter.java:269)
Caused by: org.apache.jackrabbit.core.nodetype.InvalidNodeTypeDefException: [{internal}NodeType#{internal}supertypes] auto-created property must have a default value
at org.apache.jackrabbit.core.nodetype.NodeTypeRegistry.validateNodeTypeDef(NodeTypeRegistry.java:1572)
at org.apache.jackrabbit.core.nodetype.NodeTypeRegistry.internalRegister(NodeTypeRegistry.java:1303)
at org.apache.jackrabbit.core.nodetype.NodeTypeRegistry.internalRegister(NodeTypeRegistry.java:1249)
at org.apache.jackrabbit.core.nodetype.NodeTypeRegistry.registerNodeTypes(NodeTypeRegistry.java:226)
at org.apache.jackrabbit.core.nodetype.NodeTypeRegistry.registerNodeTypes(NodeTypeRegistry.java:208)
at org.apache.jackrabbit.core.nodetype.NodeTypeManagerImpl.registerNodeTypes(NodeTypeManagerImpl.java:441)
at org.apache.jackrabbit.core.nodetype.NodeTypeManagerImpl.registerNodeTypes(NodeTypeManagerImpl.java:575)
... 5 more
Exception in thread "main" java.lang.NullPointerException
at edu.vt.cs.cnd2xsd.Cnd2XsdConverter.loadPropertyMap(Cnd2XsdConverter.java:137)
at edu.vt.cs.cnd2xsd.Cnd2XsdConverter.init(Cnd2XsdConverter.java:655)
at edu.vt.cs.cnd2xsd.Cnd2XsdConverter.main(Cnd2XsdConverter.java:269)
Does somebody per chance have the desired .xsd file at hand already that he/she could post here?
Or does someone have a clue what I could do to get the conversion working?
I'm a bit puzzled that Google didn't show more people having the same problem, i.e. wanting to use XSD schema validation and code completion on .content files, as that seems to be far more convenient than using CRXDE Lite to do the same thing?