If it is a static label, why not just do it in your model? There's
many ways to do that, and here's one:

public class MyPage extends WebPage {
...

public MyPage() {
  add(new Label(new PropertyModel(this, "getDateFormatted()")));
}

private Date getDate() { ... }

private String getDateFormatted() {
   return myDateFormat.format(getDate());
}

Overriding the converter is another way, but that more work than
necesarry; you'll usually do that either to have uniformity in your
application and do that on a application level, or do it for
components that need to do input and output and override
Component.getConverter


Eelco


-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid3432&bid#0486&dat1642
_______________________________________________
Wicket-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/wicket-user

Reply via email to