Examples of WeekSwitcher


Examples of org.openfaces.component.timetable.WeekSwitcher

    protected void renderText(
            FacesContext context,
            AbstractSwitcher switcher,
            TimetableView timetableView,
            SimpleDateFormat dateFormat) throws IOException {
        WeekSwitcher weekSwitcher = (WeekSwitcher) switcher;
        Locale locale = switcher.getLocale();
        TimeZone timeZone = switcher.getTimeZone();

        SimpleDateFormat fromDateFormat = CalendarUtil.getSimpleDateFormat(null, null,
                weekSwitcher.getFromPattern(), "MMMM d", locale, timeZone);
        SimpleDateFormat toDateFormat = CalendarUtil.getSimpleDateFormat(null, null,
                weekSwitcher.getToPattern(), "MMMM d, yyyy", locale, timeZone);
        Map<String,Object> requestMap = context.getExternalContext().getRequestMap();
        requestMap.put(getFromPatternKey(), fromDateFormat.toPattern());
        requestMap.put(getToPatternKey(), toDateFormat.toPattern());

        ResponseWriter writer = context.getResponseWriter();
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.