|
||||||||||
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.JPathTransformer
public class JPathTransformer
Field Summary | |
---|---|
static String |
JPATH_ACTION
jpath:action attribute constant |
static String |
JPATH_CONTINUATION
jpath:continuation element constant |
static String |
JPATH_CONTINUATION_SELECT
jpath:continuation select attribute constant |
static String |
JPATH_IF
jpath:if element constant |
static String |
JPATH_NAMESPACE_URI
namespace constant |
static String |
JPATH_TEST
jpath generic test attribute |
static String |
JPATH_VALUEOF
jpath:value-of element constant |
static String |
JPATH_VALUEOF_SELECT
jpath:value-of select attribute constant |
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 | |
---|---|
JPathTransformer()
|
Method Summary | |
---|---|
void |
endTransformingElement(String uri,
String name,
String raw)
Exit method for all elements in our namespace |
void |
initialize()
Initialize this transformer. |
void |
recycle()
Release all held resources. |
void |
setup(SourceResolver resolver,
Map objectModel,
String src,
Parameters parameters)
Setup this transformer |
void |
startElement(String uri,
String loc,
String raw,
Attributes a)
Intercept startElement to ensure all <jpath:action> attributes are modified. |
void |
startTransformingElement(String uri,
String name,
String raw,
Attributes attr)
Entry method for all elements in 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 |
---|
public static final String JPATH_NAMESPACE_URI
public static final String JPATH_ACTION
public static final String JPATH_VALUEOF
public static final String JPATH_VALUEOF_SELECT
public static final String JPATH_CONTINUATION
public static final String JPATH_CONTINUATION_SELECT
public static final String JPATH_IF
public static final String JPATH_TEST
Constructor Detail |
---|
public JPathTransformer()
Method Detail |
---|
public void initialize() throws Exception
initialize
in interface Initializable
Exception
- if an error occurspublic void setup(SourceResolver resolver, Map objectModel, String src, Parameters parameters) throws ProcessingException, SAXException, IOException
setup
in interface SitemapModelComponent
setup
in class AbstractSAXTransformer
resolver
- a SourceResolver
instanceobjectModel
- the objectModelsrc
- src
parameterparameters
- optional parameters
ProcessingException
- if an error occurs
SAXException
- if an error occurs
IOException
- if an error occurspublic void startElement(String uri, String loc, String raw, Attributes a) throws SAXException
startElement
in interface ContentHandler
startElement
in class AbstractSAXTransformer
uri
- a String
valueloc
- a String
valueraw
- a String
valuea
- an Attributes
value
SAXException
- if an error occursContentHandler.startElement(java.lang.String, java.lang.String, java.lang.String, org.xml.sax.Attributes)
public void startTransformingElement(String uri, String name, String raw, Attributes attr) throws ProcessingException, IOException, SAXException
startTransformingElement
in class AbstractSAXTransformer
uri
- a String
valuename
- a String
valueraw
- a String
valueattr
- an Attributes
value
ProcessingException
- if an error occurs
IOException
- if an error occurs
SAXException
- if an error occurspublic void endTransformingElement(String uri, String name, String raw) throws ProcessingException, IOException, SAXException
endTransformingElement
in class AbstractSAXTransformer
uri
- a String
valuename
- a String
valueraw
- a String
value
ProcessingException
- if an error occurs
IOException
- if an error occurs
SAXException
- if an error occurspublic void recycle()
recycle
in interface Recyclable
recycle
in class AbstractSAXTransformer
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |