Configuring Eclipse
Prerequisites
Eclipse (of course...) with the following plugins
-
Eclipse XML editors and tools (XML / XSLT edition)
-
XSD - XML schema definition (XSD edition)
-
PyDev (for the Python parser)
-
C/C++ Development tools (for the C parser)
-
PDT PHP development tools (for the PHP parser)
Creating project tree
The eclipse project bundled with ns-xml is located in script/eclipse. To create symbolic links to sources inside this folder, run
./tools/sh/eclipse/configure.sh
Using Mercurial
Add
[ui]ignore.eclipse = resources/hg/ignores/eclipse
in your .hg/hgrc file to ignore these symbolic links
Adding ns-xml XML schema to Eclipse XML catalog
-
Open Eclipse Preferences
-
In XML > XML Catalog > XML Catalog Entriss, click Add...
-
In the new dialog, click Workspace
-
Browse ns-xml/xsd ... and select one of the XSD schema (ex: program/2.0/program.xsd), validate
-
Repeat the operation for each schema
Eclipse can now use the XSD to auto-complete and auto-validate XML files that use a ns-xml schemas.