Kickstart Wicket in NetBeans IDE 4.1
By Geertjan on Apr 27, 2005
- Download and unzip the wicket-kickstart-1.0 sources.
- In the IDE, click Ctrl-Shift-N. (Or choose File > New Project.) The New Project Wizard appears. Choose Web and then Web Application with Existing Sources:
- Click Next and browse to the location where you unzipped the Wicket Kickstart sources. Select the "wicket-kickstart-1.0" folder for the Location field. Name the project "Kickstart". Click Next and Finish.
From a traditional NetBeans IDE (or probably any other) perspective, the structure of the kickstart project is novel, because the HTML file is located within the source package:
However, the reason for this is that everything in a wicket project is nothing more than a component and, in Tim Boudreau's words, "both the HTML and Java code needed are as simple as the things they're supposed to do". He also says that Wicket is "possibly the cleanest solution to POJO web apps that I've seen at release candidate phase". Matt Raible also has some cool things to say about Wicket here. One thing I personally like about Wicket's philosophy is that it "does not introduce any special syntax to HTML. Instead, it extends HTML in a standards-compliant way via a Wicket namespace that is fully compliant with the XHTML standard." They cite JSP as being "by far the worst offender, allowing the embedding of Java code directly in web pages", while most other frameworks "introduce some kind of special syntax to your HTML code". No special syntax! Wow. This is cool, in Wicket's own words, because special syntax "changes the nature of HTML from the kind of pure-and-simple HTML markup that web designers are familiar with, to some kind of special HTML. This special HTML can be more difficult to preview, edit and understand".
Now that you've got the Kickstart up and running (all you need to do to run the Kickstart application is right-click the project and choose Run Project), you should check out the Wicket Stuff site, which "provides additional Java web components to the core components supplied by the Wicket framework". The additional components include Spring, Hibernate, and Groovy. Or check out their cool samples.
Update 5/7/05: You can now download all the Wicket samples as NetBeans projects. When you do so, you can just open them as projects, just like any other project, from inside the IDE. After resolving some dependencies, you can deploy them, just like any other NetBeans IDE project. For more information, and for the downloadable ZIP file, click here.