|How to call a JFace dialog from NSF? via Composite Applications|
I've been asked recently several times how Composite Applications relate to mashups. I think Composite Applications are a superset of mashups. Mashups and Composite Applications support tightly coupled components. Mashups and Composite Applications can trigger dialogs with additional information from another service (example when Google Maps comes up for a selected address). In addition to mashups however Composite Applications also support loosely coupled components. In this entry I want to focus on how Composite Applications can be used to build a mashup as many people think of it.
Check out this screenshot. It shows a very simple application that I've built. When you click on a view entry in Notes a JFace dialog comes up with the selected value.
I admit the sample is not that sexy. I've tried to keep it as simple as possible so that other people can build it also. I've used our simple tutorials as starting point. I exchanged the implementation of the Java action to pop up a message box:
Shell shell = new Shell();
"My SWT dialog displaying value from NSF",
"Selected category: " + val);
The real trick was then to hide the ViewPart of my Eclipse components. You can do this easily by setting a preference in the Composite Application Editor:
I think this is pretty cool. It shows how easy it is to build mashup-like functionality with Composite Applications.