Package org.ametys.plugins.forms.content
Class FormDocbookUpdateHandler
java.lang.Object
org.apache.avalon.framework.logger.AbstractLogEnabled
org.ametys.cms.contenttype.DockbookUpdateHandler
org.ametys.plugins.forms.content.FormDocbookUpdateHandler
- All Implemented Interfaces:
LogEnabled
,ContentHandler
,LexicalHandler
This handler look for CMS forms in a RichText.
It must be used after a copy of a Content to changes theses references if necessary.
-
Field Summary
Fields inherited from class org.ametys.cms.contenttype.DockbookUpdateHandler
_contentHandler, _createdContent, _createdObject, _initialAOPath, _initialContent, _initialContentPath, _initialObject, _lexicalHandler
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected void
_copyAttributes
(Attributes attrs, AttributesImpl newAttrs) Copy attributesprotected String
Generate a new form idprotected Attributes
_getAttributesForForm
(Attributes attrs) Get attributes for media objects such as image, flashvoid
startElement
(String uri, String loc, String raw, Attributes attrs) Methods inherited from class org.ametys.cms.contenttype.DockbookUpdateHandler
characters, comment, endCDATA, endDocument, endDTD, endElement, endEntity, endPrefixMapping, ignorableWhitespace, processingInstruction, setContentHandler, setCreatedContent, setCreatedObject, setDocumentLocator, setInitialContent, setInitialObject, setLexicalHandler, skippedEntity, startCDATA, startDocument, startDTD, startEntity, startPrefixMapping
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.xml.sax.ContentHandler
declaration
-
Constructor Details
-
FormDocbookUpdateHandler
public FormDocbookUpdateHandler()
-
-
Method Details
-
startElement
- Specified by:
startElement
in interfaceContentHandler
- Overrides:
startElement
in classDockbookUpdateHandler
- Throws:
SAXException
-
_getAttributesForForm
Get attributes for media objects such as image, flash- Parameters:
attrs
- the attributes- Returns:
- the new attributes
-
_copyAttributes
Copy attributes- Parameters:
attrs
- the attributes to copynewAttrs
- the new attributes
-
_generateFormId
Generate a new form id- Returns:
- a form id
-