Package org.ametys.odf.export.pdf
Class EducationalBookletGenerator
- 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.odf.export.pdf.EducationalBookletGenerator
-
- All Implemented Interfaces:
Poolable
,Recyclable
,Disposable
,Component
,LogEnabled
,Serviceable
,Generator
,SitemapModelComponent
,XMLProducer
public class EducationalBookletGenerator extends ServiceableGenerator
Generator producing the SAX of subprogram and its courses for the educational booklet
-
-
Field Summary
Fields Modifier and Type Field Description protected ODFHelper
_odfHelper
The ODF helperprotected AmetysObjectResolver
_resolver
The Ametys object resolver-
Fields inherited from class org.apache.cocoon.generation.ServiceableGenerator
manager
-
Fields inherited from class org.apache.cocoon.generation.AbstractGenerator
objectModel, parameters, resolver, source
-
Fields inherited from class org.apache.cocoon.xml.AbstractXMLProducer
contentHandler, EMPTY_CONTENT_HANDLER, lexicalHandler, xmlConsumer
-
-
Constructor Summary
Constructors Constructor Description EducationalBookletGenerator()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected Set<Course>
_getChildCourses(ProgramItem programItem)
Get all child courses from the program itemprotected void
_saxContentAsFo(Content content)
Sax content as foprotected void
_saxCourse(Course course)
Sax course as foprotected void
_saxSubProgram(SubProgram subProgram)
Sax sub program as fovoid
generate()
void
service(ServiceManager sManager)
-
Methods inherited from class org.apache.cocoon.generation.ServiceableGenerator
dispose
-
Methods inherited from class org.apache.cocoon.generation.AbstractGenerator
recycle, setup
-
Methods inherited from class org.apache.cocoon.xml.AbstractXMLProducer
setConsumer, setContentHandler, setLexicalHandler
-
Methods inherited from class org.apache.avalon.framework.logger.AbstractLogEnabled
enableLogging, getLogger, setupLogger, setupLogger, setupLogger
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.apache.cocoon.xml.XMLProducer
setConsumer
-
-
-
-
Field Detail
-
_resolver
protected AmetysObjectResolver _resolver
The Ametys object resolver
-
_odfHelper
protected ODFHelper _odfHelper
The ODF helper
-
-
Constructor Detail
-
EducationalBookletGenerator
public EducationalBookletGenerator()
-
-
Method Detail
-
service
public void service(ServiceManager sManager) throws ServiceException
- Specified by:
service
in interfaceServiceable
- Overrides:
service
in classServiceableGenerator
- Throws:
ServiceException
-
generate
public void generate() throws IOException, SAXException, ProcessingException
-
_getChildCourses
protected Set<Course> _getChildCourses(ProgramItem programItem) throws MalformedURLException, IOException, SAXException
Get all child courses from the program item- Parameters:
programItem
- the program item- Returns:
- the set of child courses
- Throws:
MalformedURLException
- if an error occurredIOException
- if an error occurredSAXException
- if an error occurred
-
_saxCourse
protected void _saxCourse(Course course) throws MalformedURLException, IOException, SAXException
Sax course as fo- Parameters:
course
- the course- Throws:
MalformedURLException
- if an error occurredIOException
- if an error occurredSAXException
- if an error occurred
-
_saxSubProgram
protected void _saxSubProgram(SubProgram subProgram) throws MalformedURLException, IOException, SAXException
Sax sub program as fo- Parameters:
subProgram
- the sub program- Throws:
MalformedURLException
- if an error occurredIOException
- if an error occurredSAXException
- if an error occurred
-
_saxContentAsFo
protected void _saxContentAsFo(Content content) throws MalformedURLException, IOException, SAXException
Sax content as fo- Parameters:
content
- the content- Throws:
MalformedURLException
- if an error occurredIOException
- if an error occurredSAXException
- if an error occurred
-
-