writer.writeText(",\n" + eventName + ": "+onEventDefinition.toScript(), null);
}
}
public String getInputValue(FacesContext context, UIComponent component) {
UICalendar input = (UICalendar) component;
// XXX nick - nick - can contain either Date or String instance
Object value = input.getSubmittedValue();
Object curVal = input.getValue();
if (value == null) {
DateTimeConverter converter = new DateTimeConverter();
converter.setPattern(input.getDatePattern());
converter.setLocale(input.getLocale());
converter.setTimeZone(input.getTimeZone());
return converter.getAsString(context, input, curVal);
}
if (value instanceof Date) {
DateTimeConverter converter = new DateTimeConverter();
converter.setPattern(input.getDatePattern());
converter.setLocale(input.getLocale());
return converter.getAsString(context, input, value);
}
if (value instanceof String) {
Converter converter = SelectUtils.getConverterForProperty(context,