...
Most users - having wicket 1.3 code and migrating to 1.4 - will get many "compile warnings" due to generics.
The reason is the new typesafety. The class Component got "generified" and because all Wicket components extend Component, they require a generic too.
But for most Components that doesn't make too much sense. Therefore you should use Void as the generic.
Some Examples:
Code Block | |||||||
---|---|---|---|---|---|---|---|
| |||||||
add(new BookmarkablePageLink("signin", LoginPage.class)); |
Code Block | ||||||
---|---|---|---|---|---|---|
| ||||||
add(new BookmarkablePageLink<Void>("signin", LoginPage.class)); |
...
Prior to 1.4.2, if an enclosure was not to be rendered, it was not mandatory to add any other children to it apart from the 'child' that determines its visibility. This is no longer true as of 1.4.2: you will have to add all children, even if the enclosure is not to be rendered.
https://issues.apache.org/jira/browse/WICKET-2605
The error message will be 'org.apache.wicket.WicketRuntimeException: Could not find child with id: foo in the wicket:enclosure', even though it is not the element with id 'foo' that cannot be found. The incorrect component id display has been fixed as of 1.4.5 via https://issues.apache.org/jira/browse/WICKET-2606