Jython Projects

A Jython project is an Eclipse project that knows that it is being used for editing Jython modules. A Jython project has the Jython nature, as Eclipse calls it. A Jython project comes with a Jython builder. A Jython builder is responsible for building an internal model of the modules in the associated project, so that the user can browse modules easily and that source problems can be marked as warnings or errors in the module editor and the problems view.

Organizing Jython source code in Jython projects is crucial to unlock all features of JyDT.

In the context of projects, these terms are used often:

  • Source folder: A Jython project treats some folders as source folders. Folders are marked as source folders on the properties page of a Jython project. Only modules in source folders are taken into account when building the internal model of a project. Consequently, only definitions in modules in source folders show up when requesting content assist and when using the Open Definition and Open Class commands to navigate to definitions. Source folders show up in the Projects view of the Browsing perspective.
  • System path: The system path of a project corresponds to the Jython system path used when a module is run. The system path of a Jython project is set on the properties pages of the project. It may contain source folders and other folders. The other folders typically contain modules outside the project, e.g. external libraries. The system path is used to find imported modules. If a module cannot be found, an error marker will be shown on the line in the source code to indicate the missing module.
  • Class path: The class path of a project lists the extra class path entries that together with jython.jar make up the class path to be used when a module is launched. The class path is set on the properties pages of a Jython project. It may contain references to external jars and folders holding Java class files.