Examples of StyleDateConverter


Examples of org.apache.wicket.datetime.StyleDateConverter

    DateTimeZone.setDefault(DateTimeZone.forTimeZone(tzServer));

    WebClientInfo clientInfo = (WebClientInfo)tester.getSession().getClientInfo();
    clientInfo.getProperties().setTimeZone(tzClient);

    StyleDateConverter converter = new StyleDateConverter(true);

    Calendar cal = Calendar.getInstance(tzClient);
    cal.set(2011, 10, 5, 0, 0, 0);
    cal.set(Calendar.MILLISECOND, 0);

    Date dateRef = cal.getTime();
    Date date = converter.convertToObject("05.11.2011", Locale.GERMANY);
    log.debug("ref: " + dateRef.getTime() + "; converted: " + date.getTime());
    log.debug("ref: " + dateRef + "; date: " + date);
    assertEquals(dateRef, date);

    TimeZone.setDefault(origJvmDef);
View Full Code Here

Examples of org.wicketstuff.calendar.util.StyleDateConverter

   *
   * @see org.apache.wicket.markup.html.form.TextField
   */
  public static DateTextField forDateStyle(String id, IModel model,
      String dateStyle) {
    return new DateTextField(id, model, new StyleDateConverter(dateStyle,
        true));
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.