Package org.apache.batik.bridge.svg12
Class XPathPatternContentSelector
- java.lang.Object
-
- org.apache.batik.bridge.svg12.AbstractContentSelector
-
- org.apache.batik.bridge.svg12.XPathPatternContentSelector
-
public class XPathPatternContentSelector extends AbstractContentSelector
A class to handle the XPath Pattern syntax for XBL content elements.- Version:
- $Id: XPathPatternContentSelector.java 1733416 2016-03-03 07:07:13Z gadams $
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description protected classXPathPatternContentSelector.NSPrefixResolverXalan prefix resolver.protected classXPathPatternContentSelector.SelectedNodesImplementation of NodeList that contains the nodes that matched this selector.-
Nested classes/interfaces inherited from class org.apache.batik.bridge.svg12.AbstractContentSelector
AbstractContentSelector.ContentSelectorFactory, AbstractContentSelector.XPathPatternContentSelectorFactory, AbstractContentSelector.XPathSubsetContentSelectorFactory
-
-
Field Summary
Fields Modifier and Type Field Description protected org.apache.xpath.XPathContextcontextThe XPath context.protected java.lang.StringexpressionThe expression string.protected XPathPatternContentSelector.NSPrefixResolverprefixResolverThe Xalan prefix resolver.protected XPathPatternContentSelector.SelectedNodesselectedContentThe selected nodes.protected org.apache.xpath.XPathxpathThe XPath expression.-
Fields inherited from class org.apache.batik.bridge.svg12.AbstractContentSelector
boundElement, contentElement, contentManager, selectorFactories
-
-
Constructor Summary
Constructors Constructor Description XPathPatternContentSelector(ContentManager cm, XBLOMContentElement content, org.w3c.dom.Element bound, java.lang.String selector)Creates a new XPathPatternContentSelector.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.w3c.dom.NodeListgetSelectedContent()Returns a list of nodes that were matched by the given selector string.protected voidparse()Parses the XPath selector.(package private) booleanupdate()Forces this selector to update its selected nodes list.-
Methods inherited from class org.apache.batik.bridge.svg12.AbstractContentSelector
createSelector, isSelected
-
-
-
-
Field Detail
-
prefixResolver
protected XPathPatternContentSelector.NSPrefixResolver prefixResolver
The Xalan prefix resolver.
-
xpath
protected org.apache.xpath.XPath xpath
The XPath expression.
-
context
protected org.apache.xpath.XPathContext context
The XPath context.
-
selectedContent
protected XPathPatternContentSelector.SelectedNodes selectedContent
The selected nodes.
-
expression
protected java.lang.String expression
The expression string.
-
-
Constructor Detail
-
XPathPatternContentSelector
public XPathPatternContentSelector(ContentManager cm, XBLOMContentElement content, org.w3c.dom.Element bound, java.lang.String selector)
Creates a new XPathPatternContentSelector.
-
-
Method Detail
-
parse
protected void parse()
Parses the XPath selector.
-
getSelectedContent
public org.w3c.dom.NodeList getSelectedContent()
Returns a list of nodes that were matched by the given selector string.- Specified by:
getSelectedContentin classAbstractContentSelector
-
update
boolean update()
Forces this selector to update its selected nodes list. Returns true if the selected node list needed updating. This assumes that the previous content elements in this shadow tree (in document order) have up-to-date selectedContent lists.- Specified by:
updatein classAbstractContentSelector
-
-