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
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected void_copyAttributes(Attributes attrs, AttributesImpl newAttrs) Copy attributesprotected StringGenerate a new form idprotected Attributes_getAttributesForForm(Attributes attrs) Get attributes for media objects such as image, flashvoidstartElement(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, startPrefixMappingMethods 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.xml.sax.ContentHandler
declaration
-
Constructor Details
-
FormDocbookUpdateHandler
public FormDocbookUpdateHandler()
-
-
Method Details
-
startElement
- Specified by:
startElementin interfaceContentHandler- Overrides:
startElementin 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
-