|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.avalon.framework.logger.AbstractLogEnabled org.apache.cocoon.xml.AbstractXMLProducer org.apache.cocoon.xml.AbstractXMLPipe org.apache.cocoon.transformation.AbstractTransformer org.apache.cocoon.transformation.AbstractSAXTransformer org.apache.cocoon.transformation.SimpleFormTransformer
public class SimpleFormTransformer
Nested Class Summary | |
---|---|
protected static class |
SimpleFormTransformer.RepeaterStatus
Keep track of repeater status. |
protected static class |
SimpleFormTransformer.ValueList
Keep track of multiple values. |
Field Summary | |
---|---|
protected Map |
formValues
Map of SimpleFormTransformer.ValueList to track multiple parameters. |
protected static String |
INPUT_MODULE_ROLE
|
protected static String |
INPUT_MODULE_SELECTOR
|
protected int |
recordingCount
Count nested repeat elements. |
protected List |
repeater
List of SimpleFormTransformer.RepeaterStatus elements keeping track of nested repeat blocks. |
protected boolean |
skipChildrenOnly
Skip element's content only. |
protected Map |
validationResults
current request's validation results (all validated elements) |
protected Object[] |
values
current element's request parameter values |
Fields inherited from class org.apache.cocoon.transformation.AbstractSAXTransformer |
---|
context, defaultNamespaceURI, EMPTY_ATTRIBUTES, emptyAttributes, ignoreEmptyCharacters, ignoreEventsCount, ignoreHooksCount, ignoreWhitespaces, manager, namespaceURI, objectModel, parameters, recorderStack, request, resolver, response, source, stack |
Fields inherited from class org.apache.cocoon.xml.AbstractXMLProducer |
---|
contentHandler, EMPTY_CONTENT_HANDLER, lexicalHandler, xmlConsumer |
Fields inherited from interface org.apache.cocoon.transformation.Transformer |
---|
ROLE |
Constructor Summary | |
---|---|
SimpleFormTransformer()
|
Method Summary | |
---|---|
void |
configure(Configuration config)
Avalon Configurable Interface |
protected void |
endRepeatElement(String uri,
String name,
String raw)
Stop recording repeat contents and replay required number of times. |
void |
endTransformingElement(String uri,
String name,
String raw)
Start processing elements of our namespace. |
protected String |
printAttributes(Attributes attr)
Generate string representation of attributes. |
void |
recycle()
Recycle this component. |
protected void |
relayEndElement(String uri,
String name,
String raw)
Calls the super's method endTransformingElement and decrements the ignoreEventsCount if larger than zero. |
protected void |
relayStartElement(boolean skip,
boolean skipChildrenOnly,
String uri,
String name,
String raw,
Attributes attr)
Calls the super's method startTransformingElement and increments the ignoreEventsCount if skip is true. |
protected void |
relayStartElement(String uri,
String name,
String raw,
Attributes attr)
Calls the super's method startTransformingElement. |
void |
setup(SourceResolver resolver,
Map objectModel,
String src,
Parameters par)
Setup the next round. |
protected void |
startCheckableElement(String aName,
String uri,
String name,
String raw,
AttributesImpl attributes)
Handle input elements that may have a "checked" attributes, i.e. checkbox and radio. |
protected void |
startErrorElement(String uri,
String name,
String raw,
Attributes attr)
Handle error elements. |
protected void |
startFormElement(String uri,
String name,
String raw,
Attributes attr)
Start processing a form element. |
protected void |
startInputElement(String uri,
String name,
String raw,
Attributes attr)
Handle input elements. |
protected void |
startNonCheckableElement(String aName,
String uri,
String name,
String raw,
AttributesImpl attributes)
Handle input elements that may don't have a "checked" attributes, e.g. text, password, button. |
protected void |
startOptionElement(String uri,
String name,
String raw,
Attributes attr)
Handle option elements. |
protected void |
startRepeatElement(String uri,
String name,
String raw,
Attributes attr)
Start recording repeat element contents and push repeat expression and variable to repeater stack. |
protected void |
startSelectElement(String uri,
String name,
String raw,
Attributes attr)
Handle select elements. |
protected void |
startTextareaElement(String uri,
String name,
String raw,
Attributes attributes)
Handles textarea elements. |
void |
startTransformingElement(String uri,
String name,
String raw,
Attributes attr)
Start processing elements of our namespace. |
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 |
---|
protected static final String INPUT_MODULE_ROLE
protected static final String INPUT_MODULE_SELECTOR
protected Object[] values
protected Map validationResults
protected boolean skipChildrenOnly
protected int recordingCount
protected List repeater
SimpleFormTransformer.RepeaterStatus
elements keeping track of nested repeat blocks.
protected Map formValues
SimpleFormTransformer.ValueList
to track multiple parameters.
Constructor Detail |
---|
public SimpleFormTransformer()
Method Detail |
---|
public void configure(Configuration config) throws ConfigurationException
configure
in interface Configurable
configure
in class AbstractSAXTransformer
ConfigurationException
public void setup(SourceResolver resolver, Map objectModel, String src, Parameters par) throws ProcessingException, SAXException, IOException
setup
in interface SitemapModelComponent
setup
in class AbstractSAXTransformer
resolver
- The current SourceResolverobjectModel
- The objectModel of the environment.src
- The value of the src attribute in the sitemap.par
- The parameters from the sitemap.
ProcessingException
SAXException
IOException
public void recycle()
recycle
in interface Recyclable
recycle
in class AbstractSAXTransformer
protected String printAttributes(Attributes attr)
protected void startCheckableElement(String aName, String uri, String name, String raw, AttributesImpl attributes) throws SAXException
SAXException
protected void startNonCheckableElement(String aName, String uri, String name, String raw, AttributesImpl attributes) throws SAXException
SAXException
protected void startInputElement(String uri, String name, String raw, Attributes attr) throws SAXException
SAXException
protected void startSelectElement(String uri, String name, String raw, Attributes attr) throws SAXException
SAXException
protected void startOptionElement(String uri, String name, String raw, Attributes attr) throws SAXException
SAXException
protected void startTextareaElement(String uri, String name, String raw, Attributes attributes) throws SAXException
SAXException
protected void startErrorElement(String uri, String name, String raw, Attributes attr) throws SAXException
SAXException
protected void startFormElement(String uri, String name, String raw, Attributes attr) throws SAXException
uri
- The namespace of the element.name
- The local name of the element.raw
- The qualified name of the element.attr
- The attributes of the element.
SAXException
protected void startRepeatElement(String uri, String name, String raw, Attributes attr) throws SAXException
uri
- name
- raw
- attr
-
SAXException
protected void endRepeatElement(String uri, String name, String raw) throws SAXException
uri
- name
- raw
-
SAXException
public void startTransformingElement(String uri, String name, String raw, Attributes attr) throws SAXException
startTransformingElement
in class AbstractSAXTransformer
uri
- The namespace of the element.name
- The local name of the element.raw
- The qualified name of the element.attr
- The attributes of the element.
SAXException
public void endTransformingElement(String uri, String name, String raw) throws SAXException
endTransformingElement
in class AbstractSAXTransformer
uri
- The namespace of the element.name
- The local name of the element.raw
- The qualified name of the element.
SAXException
protected void relayStartElement(String uri, String name, String raw, Attributes attr) throws SAXException
uri
- name
- raw
- attr
-
SAXException
protected void relayStartElement(boolean skip, boolean skipChildrenOnly, String uri, String name, String raw, Attributes attr) throws SAXException
skip
- skipChildrenOnly
- uri
- name
- raw
- attr
-
SAXException
protected void relayEndElement(String uri, String name, String raw) throws SAXException
uri
- name
- raw
-
SAXException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |