Build a Rich Client Platform application
by, 11-14-2011 at 05:54 PM (1205 Views)
While the Eclipse platform is designed to serve as an open tools platform, it is architect so that its components could be used to build just about any client application. The minimal set of plug-ins needed to build a rich client application is collectively known as the Rich Client Platform.
Applications that don't require a common resource model can be built using a subset of the platform. These rich applications are still based on a dynamic plug-in model, and the UI is built using the same toolkits and extension points. The layout and function of the workbench is under fine-grained control of the plug-in developer in this case. Up until now, we've been adding all of our visible function to the platform SDK workbench. In a rich client application, we are responsible for defining the application and its workbench.
When we say that the Rich Client Platform is the minimal set of plug-ins needed to build a platform application with a UI, we mean that your application need only require two plug-ins, org.eclipse.ui and org.eclipse.core runtime. However, rich client applications are free to use any API deemed necessary for their feature set, and can require any plug-ins above the bare minimum.
The main thing that differentiates a rich client application from the platform workbench is that the application is responsible for defining which class should be run as the main application. We'll look at how this is done in the context of an example.
Now I will tell you how to create a simple RCP application.
In Eclipse select File-> New Project. From the list select Plug-In project.
Then perform the following steps:
Give your RCP plugin a name, e.g. "MyRCP" .
As a template select the "Hello RCP".RCP 3.
Make the following settings. As we are going to develop a RCP application, select "Yes" at the last question.
Click finish and you should see an editor and the tab "Overview" should be selected. Select then under "Testing" "Launch an Eclipse Application". Alternatively: Run this program by selecting the automatically created "plugin.xml", right mouse click and select run as Eclipse Application. The result should look like the following: