Class AbstractEventGenerator
java.lang.Object
org.apache.avalon.framework.logger.AbstractLogEnabled
org.apache.cocoon.xml.AbstractXMLProducer
org.apache.cocoon.generation.AbstractGenerator
org.apache.cocoon.generation.ServiceableGenerator
org.ametys.plugins.calendar.events.AbstractEventGenerator
- All Implemented Interfaces:
Poolable,Recyclable,Disposable,Component,LogEnabled,Serviceable,Generator,SitemapModelComponent,XMLProducer
- Direct Known Subclasses:
EventGenerator,EventsGenerator
Abstract generator provinding methods to sax an event content
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected ContentFilterHelperThe content filter helper.protected SourceResolverThe source resolver.Fields inherited from class org.apache.cocoon.generation.ServiceableGenerator
managerFields inherited from class org.apache.cocoon.generation.AbstractGenerator
objectModel, parameters, resolver, sourceFields inherited from class org.apache.cocoon.xml.AbstractXMLProducer
contentHandler, EMPTY_CONTENT_HANDLER, lexicalHandler, xmlConsumer -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected String_getFormatedDateAttribute(Content content, String attributePath) Retrieves the formated value of the date attribute of the given contentvoidsaxContent(ContentHandler handler, Content content, boolean saxContentItSelf, WebContentFilter filter, boolean checkUserAccess) SAX a contentvoidsaxXMLContent(ContentHandler handler, Content content, String viewName) SAX a content in XML mode.voidservice(ServiceManager serviceManager) Methods inherited from class org.apache.cocoon.generation.ServiceableGenerator
disposeMethods inherited from class org.apache.cocoon.generation.AbstractGenerator
recycle, setupMethods inherited from class org.apache.cocoon.xml.AbstractXMLProducer
setConsumer, setContentHandler, setLexicalHandlerMethods inherited from class org.apache.avalon.framework.logger.AbstractLogEnabled
enableLogging, getLogger, setupLogger, setupLogger, setupLoggerMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.apache.cocoon.xml.XMLProducer
setConsumer
-
Field Details
-
_resolver
The source resolver. -
_filterHelper
The content filter helper.
-
-
Constructor Details
-
AbstractEventGenerator
public AbstractEventGenerator()
-
-
Method Details
-
service
- Specified by:
servicein interfaceServiceable- Overrides:
servicein classServiceableGenerator- Throws:
ServiceException
-
saxContent
public void saxContent(ContentHandler handler, Content content, boolean saxContentItSelf, WebContentFilter filter, boolean checkUserAccess) throws SAXException, IOException SAX a content- Parameters:
handler- The content handler to SAX intocontent- The content.saxContentItSelf- true to sax the content, false will only sax some metafilter- The filter. Can be null if saxContentItSelf is falsecheckUserAccess- True to check user access when saxing the content itself- Throws:
SAXException- If an error occurs while SAXingIOException- If an error occurs while retrieving content.
-
_getFormatedDateAttribute
Retrieves the formated value of the date attribute of the given content- Parameters:
content- the contentattributePath- the path of the attribute. The attribute must be date or date time- Returns:
- the formated value
-
saxXMLContent
public void saxXMLContent(ContentHandler handler, Content content, String viewName) throws SAXException, IOException SAX a content in XML mode.- Parameters:
handler- The content handler to SAX intocontent- The content to SAXviewName- The view to use- Throws:
SAXException- If an error occurs while SAXingIOException- If an error occurs while retrieving content.
-