Sources for Wicket Sample Plug-in for NetBeans IDE
By Geertjan on Jul 12, 2005
So, after setting these things up, let's deploy the "Hello World" sample.
- Get the basis project. First we'll get the project sample that contains information shared by all other Wicket samples. It contains things like a header file that gives a uniform look and feel to all Wicket projects. Click Ctrl-Shift-N (which opens the New Project wizard) and expand Samples, then Web, and then Wicket. Choose the first project, called "Basis for All Wicket Samples", as shown below:
Click Next, find somewhere to store the project, and then click Finish. Right-click the new project in the Projects window, choose Resolve Reference Problems, click Resolve, and create a library called "wicket" that contains all the JARs provided by the Wicket API.
- Get the Hello World project. Click Ctrl-Shift-N again, and again expand Samples, then Web, and then Wicket. This time, select the project called "Hello World". Click Next and Finish. Right-click the Hello World project in the Projects window, choose Resolve Reference Problems, click Resolve, and browse to where the "Basis for All Wicket Samples" is stored in your filesystem. Select it and click Open Project Folder. The reference problem is now resolved.
- Run the Hello World project. Right click the project and choose Run Project. The project deploys and displays the Hello World application in the IDE's default browser. You can apply the same process to all the other Wicket samples in the New Project wizard, except for Display Tags, which has a few additional dependencies.
One cool thing about this plug-in is that it includes the sources of the plug-in itself -- in the form of a project sample! So, the final sample in the list in the New Project wizard's Wicket category (selected below), creates a sample project that is the plug-in that installs the Wicket samples, including itself.
The selected project sample above makes sense when examined in combination with the NetBeans Project Sample Plug-in Tutorial. For example, the tutorial explains how to modify the layer.xml file to install the samples in the New Project wizard.