Monday, February 21, 2011

CNF goes RAP.

I am glad to announce that Common Navigation Framework is ported to RAP. Thanks to the effort of CNF it was not so difficult.
There is a lot publish on CNF, so if you want to know how to start with CNF you can go here or there.
Framework is really useful and now ready to be used in webapps.

Anyway I decided to show a short example. So here it is.

There are two content providers that contribute to the tree. One providing a real nodes, second providing "virtual" ones. To put CNF online and still keep it single-sourced is good to separate the RAP application logic from the view contribution.





Then our contribution navigations should be marked optional (org.eclipse.ui, org.eclipse.ui.navigator, org.eclipse.ui.rap, and org.eclipse.rap.ui.navigator).  The dependency is resolved at the run-time for both RAP and RCP configuration.

This example can be downloaded as zip archive which contains two bundles and starting configuration
The starters for RAP and RCP configurations are attached in the examples.
Oh... And the last important thing:


The CNF port project page is maintained at Eclipse Wiki.
So you can find a link to CVS sources there :)

No comments: