This is a more advanced version of the XPathExtractor bean which supports XPath functions.
An AdvancedXPathExtractor is created using a Spring bean with the following attributes:
Attribute | Value | Description |
---|---|---|
id | User-defined | A unique ID for the bean. |
parent | rdf.extractor.advanced.xpath.abstract | The parent bean. |
The AdvancedXPathExtractor bean takes the following properties:
Property | Type | Mandatory | Description |
---|---|---|---|
xmlSchemaFilter | XmlSchemaFilter | Required | A filter for which the bean applies. |
xpathQueries | Map <QName,String> | Required | Map defining the XPath expressions to used for each predicate. Use a fully-qualified name with Clark notation as the key of the entry. |
<bean id="my.custom.advanced.xpath.extractor" parent="rdf.extractor.advanced.xpath.abstract"> <property name="xmlSchemaFilter" ref="dita.schemas.topic"/> <property name="xpathQueries"> <map> <entry key-ref="qname.dita.title" value="string-join(/*/title/normalize-space(.),'')"/> <entry key-ref="qname.dita.shortdesc" value="normalize-space(string-join(/*/shortdesc/node(),''))"/> </map> </property> </bean>
To debug your AdvancedXPathExtractor, add the following entry to your
log4j.properties
file:
log4j.logger.com.componize.rdf.pipeline.stax.AdvancedXPathExtractorFactory=trace