This project has retired. For details please refer to its Attic page.
Apache Forrest: Eclipse Plugin
Apache Software Foundation > Apache Forrest
 
Font size:      

Apache Forrest: Eclipse Plugin

Eclipse Plugin

Warning
The Forrest plugin for Eclipse is new and under development.

Installation notes

To get you started while the documentation is being developed, see this forrest-dev mail thread: [eclipse] How to install? .

Wizards

A number of wizards are provided for performing common tasks. This section briefly describes the available wizards.

Creating a new Forrest Project

To create a new Forrest project select "New Project" from either the context menu in the package explorer or the "New" menu and select Forrest -> Seed New Project.

Project Name and Location

A wizard will ask you for the name of the project and the location in which the project files are to be created (by default the files will be in your current workspace). When you are done, click on Next

Site options

Here you will see the Site Options page. This is where you can specify certain options for your new site. Currently the available options are:

  • Group Name
  • Project Name
  • Vendor
  • Copyright link
  • Disable PDF link
  • Disable POD link
  • Disable Print link
  • Disable Text link
  • Disable XML link

There is also an option to save these sselections as your default settings. If this is done, the next time you create a project it will have the same seelections that you have specified here. When you are finished with this page, click on Next

Activate Plugins

This page allows you to select the plugins that you would like your project to use. The list of available plugins is on the left and list of plugins that you have chosen for your project is on the right. Once you have selected those plugins click on Finish to create your new Site Project.

Creating a new XDoc

To create a new XDoc within yout Forrest project select "New -> Other..." and then select "New XDoc" from the Forrest node.

Editors

A number of editors are provided for Forrest configuration files. This section describes those editors.

site.xml Editor

First, you need to activate the Site.xml view. This can be done by: Window -> Show View -> Other... -> Forrest -> SiteXML -> OK Now you will see the the view open up in Eclipse. To view a tree, click on the project you are working and you should see the structure of the site.xml as a tree in the view.

There are two ways to add the note to the site.xml file.

  1. Drag a file from the Package Explorer to the tree. This will create a new element with references to that dropped file(s).
  2. Right click on an element in the site.xml tree and select "Add Element". A wizard will come up which will allow you to enter the HREF, Description, Label and Element name for the new element that is being added.

To delete an element, right click on the element in the tree and click on "Delete Element".

Warning
For the changes to show up when you run a test site for your project, you must save the changes. Right click on the tree and select "Save". In a later version of the plugin this step will not be necessary.
Fixme (Anil Ramnanan)
Currently there is no easy way to edit an existing element. The element will be linked to the Properties View in Eclipse to allow for easy editing

tabs.xml Editor

First, you need to activate the Tab.xml view. This can be done by: Window -> Show View -> Other... -> Forrest -> TabXML -> OK Now you will see the the view open up in Eclipse. To view a tree, click on the project you are working and you should see the structure of the tabs.xml as a tree in the view.

To add a new element to the tabs.xml file right click on an element in the tabs.xml tree and select "Add Element". A wizard will come up which will allow you to enter the Id, Dir, Label and Index File for the new tab element that is being added.

To delete an element, right click on the element in the tree and click on Delete Element

Warning
For the changes to show up when you run a test site for your project, you must save the changes. Right click on the tree and select "Save". In a later version of the plugin this step will not be necessary.
Fixme (Anil Ramnanan)
Currently there is no easy way to edit an element. The element will be linked to the Properties View in Eclipse to allow for easy editing

Locationmap.xml Editor

First, you need to activate the Locationmap view. This can be done by:

Window -> Show View -> Other... -> Forrest -> Locationmap -> OK

Now you will see the the view open up in Eclipse. To view a tree, click on the project you are working and you should see the structure of the Locationmap.xml as a tree in the view.

To add a match, you must rich click on the locater element and click on "Add Match". A wizard will come up asking you to enter the Pattern or the Match.

Right click on the match you just created and click on "Add Location". This will allow you to enter the Location Source.

To delete an element, right click on the element in the tree and click on Delete Element

For the changes to show up when you run a test site for your project, you must save the changes. Right click on the tree and select "Save".

Fixme (Anil Ramnanan)
Currently there is no easy way to edit an element. The element will be linked to the Properties View in Eclipse to allow for easy editing

Activate Forrest:Views for a project

To activate views when seeding a new project:

File -> New -> Project -> Forrest -> Seed New Project -> Next

Type in the name of the project and click on Next. To Activate views for the new project, check off "Activate Views" and click on Finish. When "Activate Views" is selected, the new project has project.skin=leather-dev uncommented and the relevant plugins for views are added to project.required.plugins

To add a new View doc (*.fv), click on New -> Other -> Forrest -> View Doc. Enter the file name of the view document and click on Finish.

Browse a remote Repostory

The Repository Browser allows you to browse a a remote repository and include the documents in a Forrest Project. To show the Repository Browser view go to Window -> Show View - >Other. Expand the Forrest Tree and select Repository Browser.

Note
Currently the repository Browser only has support for the Daisy repository but support for other repoisotries can be easily added. If you have specific need pleae join us on the dev list where we will be happy to assist.

Daisy Repository

For the Repository Browser to work with the Daisy repository, the settings for the daisy repository must be configured.

Go to Windows -> Preferences. Chose Daisy. Here you will see a number of options to set for the daisy repository.

  • Repository Location - this is the http location of the repoistory browser. This can be a domain name or an IP address e.g. localhost or 127.0.0.1
  • Repository Port - This is the port that the repository runs on e.g. 9623
  • Repository Username - This is the username that is set for the repository
  • Repository Password - This is the password that is used to authenticate the user for the repository

To include a document from a Repository in a Forrest Project, click on the document in the Document list of the repository browser and drag it to locator section in the Locationmap View.

Modify and Build Forrest Sites

Once a Forrest Project has been created the user can access the context menus to modify and build the site.

Modify Settings

In order to modify the settings of a project, right click on the project in the Package Explorer. At the bottom of the menu you will find two meny items.

  • Modify Plugins Selection - This will let you add and remove Forrest plugins from your project
  • Modify Configurations - This allows you to modify the Site Option settings that were selected when the project was created.

Build Site Options

In order to build a project, right click on the project in the Package Explorer. At the bottom of the menu you will find the Site menu item. This menu item has a number of sub items.

  • Start Test Server - This will start the project as a local webapp and open a browser window that will allow you to preview it.
  • Stop Test Server - This will stop the local webapp.
  • Build WAR File - This will build the site as a webapp in a war file located in the build folder of your project.
  • Build Site - This will build a static site from your project in the Build folder of your project.