alvinalexander.com | career | drupal | java | mac | mysql | perl | scala | uml | unix  

What this is

This file is included in the DevDaily.com "Java Source Code Warehouse" project. The intent of this project is to help you "Learn Java by Example" TM.

Other links

The source code

<?xml version="1.0" encoding="UTF-8" ?>

<!-- Simple Cheat Sheet -->

<cheatsheet title="Create a plug-in">

   <!-- Introduction -->

   <intro href="/org.eclipse.platform.doc.user/reference/ref-cheatsheets.htm">
      <description>
         This cheat sheet will demonstrate how to create and run an
         RCP application using PDE. 
         <br/>
         <br/>
         To learn more about using cheat sheets, click the help button
         in the top right corner (?). 
      </description>
   </intro>

   <!-- Item -->

   <item title="Open the plug-in development perspective"
         href="/org.eclipse.pde.doc.user/guide/tools/views/views.htm"
         dialog="false"
         skip="false">
      <description>
         To open the plug-in development perspective,
         select <b>Window->Open Perspective->Other... 
         and choose <b>Plug-in Development.
         <br/>
         <br/>
         Alternatively, click the following button to perform the task.
      </description>
      <command serialization="org.eclipse.ui.perspectives.showPerspective(org.eclipse.ui.perspectives.showPerspective.perspectiveId=org.eclipse.pde.ui.PDEPerspective)" required="false" translate="" />
   </item>

   <!-- Item -->

   <item title="Create the plug-in"
         href="/org.eclipse.pde.doc.user/guide/tools/project_wizards/new_plugin_project.htm"
         dialog="true"
         skip="false">
      <description>
         To create the plug-in, perform the following steps:
      </description>
      <subitem label="Select "File->New->Project..." from the main menu, expand the "Plug-in Development" category within the resulting "New Project" dialog box, and choose "Plug-in Project"" 
               skip="false">
         <command serialization="org.eclipse.ui.newWizard(newWizardId=org.eclipse.pde.ui.NewProjectWizard)" required="false" translate="" />
      </subitem>
      <subitem label="Input "com.example.rcpapp" into the "Project Name" text box on the "Plug-in Project" page and click "Next >"" 
               skip="false"/>
      <subitem label="Select the "Yes" radio button under the "Rich Client Application" heading on the "Plug-in Content" page and click "Next >"" 
               skip="false"/>
      <subitem label="Select the "Hello RCP" template from the list of "Available Templates" and click "Finish"" 
               skip="false"/>           
   </item>

   <!-- Item -->

   <item title="Run the RCP Application"
         dialog="false"
         href="/org.eclipse.pde.doc.user/guide/tools/launchers/eclipse_application_launcher.htm"
         skip="false">
      <description>
         To run the RCP application,
         perform the following steps:
      </description>
      <subitem label="Select the "com.example.rcpapp" plug-in editor from the workbench and select the "Overview" tab within it" 
               skip="false">
         <command serialization="org.eclipse.ui.navigate.openResource(filePath=/com.example.rcpapp/META-INF/MANIFEST.MF)" required="false" translate="" />
      </subitem>               
      <subitem label="Click the "Launch an Eclipse application" hyperlink under the "Testing" heading" 
               skip="false"/>
      <subitem label="Verify that you see an empty window with a window title of "Hello RCP"" 
               skip="true"/>
      <subitem label="Exit the RCP application" 
               skip="false"/>
   </item>

   <!-- Item -->

   <item title="Modify the plug-in source"
         dialog="true"
         skip="false">
      <description>
         In this step, we want to suppress the <b>Hello RCP text in
         the window title bar of our RCP application.
         <br/>
         <br/>
         To modify the plug-in source accordingly, 
         perform the following steps:
      </description>
      <subitem label="Open "ApplicationWorkbenchWindowAdvisor.java" by locating it in the "src" folder of the "com.example.rcpapp" package in the "Package Explorer" view and double-clicking it" 
               skip="false">                                                    
         <command serialization="org.eclipse.ui.navigate.openResource(filePath=/com.example.rcpapp/src/com/example/rcpapp/ApplicationWorkbenchWindowAdvisor.java)" required="false" translate="" />
      </subitem>
      <subitem label="Comment out 'configurer.setTitle("Hello RCP");' in the "preWindowOpen()" method" 
               skip="false"/>
      <subitem label="Select "File->Save" from the main menu" 
               skip="false"/>
   </item>

   <!-- Item -->

   <item title="Test the RCP Application"
         dialog="false"
         href="/org.eclipse.pde.doc.user/guide/tools/launchers/eclipse_application_launcher.htm"
         skip="false">
      <description>
         To test the RCP application,
         perform the following steps:
      </description>
      <subitem label="Select the "com.example.rcpapp" plug-in editor from the workbench and select the "Overview" tab within it" 
               skip="false">
         <command serialization="org.eclipse.ui.navigate.openResource(filePath=/com.example.rcpapp/META-INF/MANIFEST.MF)" required="false" translate="" />
      </subitem>               
      <subitem label="Click the "Launch an Eclipse application" hyperlink under the "Testing" heading" 
               skip="false"/>
      <subitem label="Verify that you see an empty window with no window title" 
               skip="true"/>
      <subitem label="Exit the RCP application" 
               skip="false"/>
   </item>

</cheatsheet>
... this post is sponsored by my books ...

#1 New Release!

FP Best Seller

 

new blog posts

 

Copyright 1998-2024 Alvin Alexander, alvinalexander.com
All Rights Reserved.

A percentage of advertising revenue from
pages under the /java/jwarehouse URI on this website is
paid back to open source projects.