fr.paris.lutece.plugins.calendar.service
Class XMLUtils

java.lang.Object
  extended by fr.paris.lutece.plugins.calendar.service.XMLUtils

public final class XMLUtils
extends Object

This class provides utils features to manipulate and convert XML calendar information


Field Summary
static String STYLE_CLASS_EMPTY_DAY
           
static String STYLE_CLASS_SMALLMONTH_DAY
           
static String STYLE_CLASS_SUFFIX_OFF
           
static String STYLE_CLASS_SUFFIX_OLD
           
static String STYLE_CLASS_SUFFIX_TODAY
           
static String STYLE_CLASS_VIEW_MONTH_DAY
           
static String STYLE_CLASS_VIEW_WEEK_DAY
           
 
Method Summary
static String getAgendaXml(String strAgenda, javax.servlet.http.HttpServletRequest request)
          Returns the Xml code of a calendar events
static String getRssXml(CalendarFilter filter)
          Returns the Xml code for RSS
static String getXml(List<Event> listEvents)
          Returns the Xml code of the Calendar portlet without XML heading
static String getXMLPortletCalendar(Locale local, Calendar cal, javax.servlet.http.HttpServletRequest request)
          Get the XML of a calendar
static byte[] transformXMLToXSL(String strXml, InputStream baSource, Map<String,String> params, Properties outputProperties)
          This method performs XSL Transformation.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

STYLE_CLASS_VIEW_MONTH_DAY

public static final String STYLE_CLASS_VIEW_MONTH_DAY
See Also:
Constant Field Values

STYLE_CLASS_VIEW_WEEK_DAY

public static final String STYLE_CLASS_VIEW_WEEK_DAY
See Also:
Constant Field Values

STYLE_CLASS_SMALLMONTH_DAY

public static final String STYLE_CLASS_SMALLMONTH_DAY
See Also:
Constant Field Values

STYLE_CLASS_SUFFIX_OLD

public static final String STYLE_CLASS_SUFFIX_OLD
See Also:
Constant Field Values

STYLE_CLASS_SUFFIX_TODAY

public static final String STYLE_CLASS_SUFFIX_TODAY
See Also:
Constant Field Values

STYLE_CLASS_SUFFIX_OFF

public static final String STYLE_CLASS_SUFFIX_OFF
See Also:
Constant Field Values

STYLE_CLASS_EMPTY_DAY

public static final String STYLE_CLASS_EMPTY_DAY
See Also:
Constant Field Values
Method Detail

getAgendaXml

public static String getAgendaXml(String strAgenda,
                                  javax.servlet.http.HttpServletRequest request)
Returns the Xml code of a calendar events

Parameters:
strAgenda - The id of the agenda
request - request servlet request
Returns:
the Xml code of the agenda content

getRssXml

public static String getRssXml(CalendarFilter filter)
Returns the Xml code for RSS

Parameters:
filter - The filter
Returns:
the Xml code of the agenda content

getXml

public static String getXml(List<Event> listEvents)
Returns the Xml code of the Calendar portlet without XML heading

Parameters:
listEvents - The list of events
Returns:
the Xml code of the agenda content

transformXMLToXSL

public static byte[] transformXMLToXSL(String strXml,
                                       InputStream baSource,
                                       Map<String,String> params,
                                       Properties outputProperties)
                                throws Exception
This method performs XSL Transformation.

Parameters:
strXml - The input XML document
baSource - The source input stream
params - parameters to apply to the XSL Stylesheet
outputProperties - properties to use for the xsl transform. Will overload the xsl output definition.
Returns:
The output document transformed
Throws:
Exception - The exception

getXMLPortletCalendar

public static String getXMLPortletCalendar(Locale local,
                                           Calendar cal,
                                           javax.servlet.http.HttpServletRequest request)
Get the XML of a calendar

Parameters:
local - The locale
cal - The calendar
request - The request
Returns:
The XML


Copyright © 2014 Mairie de Paris. All Rights Reserved.