Name | Modified | Size | Downloads / Week |
---|---|---|---|
old_versions | 2023-09-13 | ||
doc | 2023-07-04 | ||
README_Site.md | 2023-09-13 | 8.2 kB | |
sf.eclipse.javacc-1.6.1-updatesite.zip | 2023-09-13 | 11.2 MB | |
Licence_CeCILL_V2-fr.html | 2010-12-03 | 32.0 kB | |
Totals: 5 Items | 11.2 MB | 9 |
The JavaCC Eclipse Plug-in(s)
Overview
The JavaCC Eclipse Plug-in is designed to help development of JavaCC / JTB applications within the Eclipse IDE.
It is available as an Eclipse feature for the standard head build, through the UI. This feature also allows headless builds.
There is also a headless only feature designed for headless builds, without installing the UI.
Although you can use some versions of the JavaCC tool for C++ or Javascript generation, the plug-in editor currently supports only grammars with Java code lines, not grammars with C++ or Javascript code lines.
Version
Last update Sept, 2023 - version 1.6.1.
Requirements
The current plug-in version requires Eclipse 4.6+ (Neon+) and a Java 1.8+ JDK.
It has been tested up to Eclipse 2023-06 (4.28) and Java 17.
It embeds JavaCC 7.0.12 jar, at user's disposal, but the user can tell the plugin to use any JavaCC jar he has downloaded on his workstation.
It embeds JTB 1.5.1 jar, at user's disposal. but the user can tell the plugin to use any JTB jar he has downloaded on his workstation.
Download & Installation
There are different methods for downloading and installing the plug-in.
- Eclipse Marketplace:
- search JavaCC,
- install the JavaCC Eclipse Plug-in version x.y.z
- Update site:
- add http://sourceforge.net/projects/eclipse-javacc to your software update sites
- use Help / Install new software... /, work with this software update site, and follow instructions
- Download and install a local update (useful if you need to install the plug-in on many Eclipse instances):
- download, from http://sourceforge.net/projects/eclipse-javacc/ through the Download button, or
download directly from https://sourceforge.net/projects/eclipse-javacc/files/
the (zipped) update site file sf.eclipse.javacc-x.y.z-updatesite.zip under a local directory - add this zip file as an archive software site
- use Help / Install new software... /, work with this archive software site, and follow instructions
- download, from http://sourceforge.net/projects/eclipse-javacc/ through the Download button, or
The installation wizard will show 3 features that can be installed:
- the normal user would select only the Feature, which will install everything for head & headless builds as well as the Help pages
- if a user wants to perform only headless builds and does not want to install the UI Plug-in, he can select only the Headless Feature
- and if he wants to install only the Help pages in his Eclipse Help, he can select only the Help Feature
For older versions, look under folder old_versions.
Since version 1.6.0, the plug-in structure has changed: the folders under the Eclipse installation folder:
- were before:
- under plugins: sf.eclipse.javacc_1.5.n
- under features: sf.eclipse.javacc.feature_1.5.n
- are now:
- under plugins: sf.eclipse.javacc.core_1.6.n, sf.eclipse.javacc.help_1.6.n & sf.eclipse.javacc.ui_1.6.n
- under features: sf.eclipse.javacc.help.feature_1.6.n, sf.eclipse.javacc.headless.feature_1.6.n & sf.eclipse.javacc.feature_1.6.n.
Note: if you try to reinstall the same version of an Eclipse feature after having un-installed it, you will probably find that you still has the old version. This is because Eclipse p2 has kept it in its cache and did not re-download it. In that case you should try :
- first ensure the old version has been uninstalled
- then run the p2 garbage collector, by running the command:
eclipse -application org.eclipse.equinox.p2.garbagecollector.application -profile <my-profile>
where <my-profile> is the value of the property eclipse.p2.profile in configuration/config.ini, most probably epp.package.java - then Reload the update site (the Reload button in the Available Software Sites of Install/update in the Preferences)
- and finally install the new version.
To run the p2 garbage collector command, you can:
- either modify your eclipse.ini to add the 2 arguments (-application and -profile) and restart Eclipse,
- or create a Run configuration of type Eclipse application running not a product but the application org.eclipse.equinox.p2.garbagecollector.application, adding to its arguments -profile <my-profile>, launch it from within Eclipse, and restart Eclipse.
Updating to 1.6.x
When updating your Eclipse installation from version 1.5.x to 1.6.x, you may encounter the following problems, due to the change of plug-in ids:
- on starting the workbench, if you had opened JavaCC Editors or JavaCC Call Hierarchy View or JavaCC Console, they will probably fail to load: just close them and reopen them.
Since version 1.6.1, on starting the workbench, the plug-in will iterate on all the projects of the workspace, and for each one it will change the nature and builder ids from the old ones to the new ones (so no action is needed from you). Some info messages will show in the Error Log view.
In version 1.6.0, you will have to manually change, in the .project files, the ids sf.eclipse.javacc.javaccbuilder
and sf.eclipse.javacc.javaccnature
to sf.eclipse.javacc.core.javaccbuilder
and sf.eclipse.javacc.core.javaccnature
(they exist if the JavaCC nature is enabled).
Trust Authorities
While installing, you may be blocked on the Trust Authorities popup that shows the https://eclipse-javacc.sourceforge.net Authority / Update Site and the Trust Selected button staying greyed.
You need to go to the Window / Preferences / Install/Update / Trust page, Authorities tab, and Add the Authority https://eclipse-javacc.sourceforge.net
.
Provided features (tools)
The JavaCC Eclipse Plug-in provides:
- preferences pages at the workbench level (mostly for editor text styling settings)
- properties pages at the project level (mostly for project building settings)
- main and contextual menus, and toolbar buttons
- an editor for JavaCC, JJTree and JTB sources, with:
- syntax coloring, matching punctuation highlighting, folding,
- formatting, automatic indentation,
- content assist,
- navigation to elements declaration and occurrences
- problem markers, task tags,
- spell checking (but not spell correction),
- keyboard shortcuts (for the commands - can be customized through the standard mechanism)
- new grammar file wizard
- an outline view for JavaCC, JJTree and JTB sources, showing the grammar structure
- a call hierarchy view for JavaCC, JJTree and JTB sources, showing the grammar caller / callees tree
- JavaCC, JJTre, JJDoc & JTB sources compilation, integrated with the Eclipse incremental build system, with problems reporting, through a builder and a nature, triggered:
- either by menus, buttons and save actions in the UI (head builds)
- or by an application through a run configuration (headless builds)
- a console view for displaying compilation outputs with hyperlinks to Errors and Warnings
- a decoration of the generated files
- a User Guide manual through the Eclipse menu Help / Help Contents / Show Contextual Help
Release notes
See readme under folder Release notes.
Plug-in User Guide
See the JavaCC Eclipse Plug-in User Guide.
JavaCC documentation
See for example the JavaCC web site.
JTB documentation
See the JTB web site.
Support
Use the project site at SourceForge.
Contributing
See readme under folder Contributing.
Licence
See Cecill Licence and GPL.