Class FormEntryInformationGenerator
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.forms.generators.FormEntryInformationGenerator
- All Implemented Interfaces:
Poolable
,Recyclable
,Disposable
,Component
,LogEnabled
,Serviceable
,Generator
,SitemapModelComponent
,XMLProducer
- Direct Known Subclasses:
FormAdminEntryInformationGenerator
,FormMailEntryInformationGenerator
Generate the entry of a form
This generator is used for "my submission" service
-
Field Summary
Modifier and TypeFieldDescriptionprotected CurrentUserProvider
The current user providerprotected FormEntryDAO
The form entry DAOprotected FormQuestionDAO
The form question DAOprotected AmetysObjectResolver
The Ametys Object resolverprotected UserManager
The user managerFields 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
-
Method Summary
Modifier and TypeMethodDescriptionprotected void
_addAdditionalEntryAttributes
(FormEntry entry, AttributesImpl attrs) Add additional entry attributesprotected void
_checkRights
(FormEntry entry) Check right before saxing entryprotected List<FormQuestion>
_getQuestions
(FormEntry entry, Optional<Long> currentStepId) Get the questions of the given entryprotected void
Sax the entryprotected void
_saxQuestion
(FormQuestion question, FormEntry entry) Sax the questionvoid
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 Details
-
_currentUserProvider
The current user provider -
_resolver
The Ametys Object resolver -
_userManager
The user manager -
_formEntryDAO
The form entry DAO -
_formQuestionDAO
The form question DAO
-
-
Constructor Details
-
FormEntryInformationGenerator
public FormEntryInformationGenerator()
-
-
Method Details
-
service
- Specified by:
service
in interfaceServiceable
- Overrides:
service
in classServiceableGenerator
- Throws:
ServiceException
-
generate
-
_checkRights
Check right before saxing entry- Parameters:
entry
- the entry
-
_saxEntry
Sax the entry- Parameters:
entry
- the entry- Throws:
SAXException
- if a saxing error occurred
-
_getQuestions
Get the questions of the given entry- Parameters:
entry
- the entrycurrentStepId
- the current step id. Can be empty- Returns:
- the list of question
-
_saxQuestion
Sax the question- Parameters:
question
- the questionentry
- the entry- Throws:
SAXException
- if a saxing exception occurred
-
_addAdditionalEntryAttributes
Add additional entry attributes- Parameters:
entry
- the entryattrs
- the attributes
-