Package net.shibboleth.metadata.dom
Class XPathItemSelectionStrategy
java.lang.Object
net.shibboleth.metadata.dom.XPathItemSelectionStrategy
@ThreadSafe
public class XPathItemSelectionStrategy
extends Object
implements Predicate<Item<Element>>
Item selection strategy which selects items on the basis of a boolean XPath expression.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final XPathExpressionCompiled form of the expression.private static final org.slf4j.LoggerClass logger. -
Constructor Summary
ConstructorsConstructorDescriptionXPathItemSelectionStrategy(String expression, NamespaceContext context) Constructor. -
Method Summary
-
Field Details
-
LOG
@Nonnull private static final org.slf4j.Logger LOGClass logger. -
compiledExpression
Compiled form of the expression.XPathExpressionobjects are reusable but are not thread-safe, so access to the compiled expression must be protected.
-
-
Constructor Details
-
XPathItemSelectionStrategy
public XPathItemSelectionStrategy(@Nonnull @NotEmpty String expression, @Nullable NamespaceContext context) throws XPathExpressionException Constructor.- Parameters:
expression- XPath expression to execute.context- Namespace context to use for the expression, expressed as aNamespaceContext.- Throws:
XPathExpressionException- if there is a problem compiling the expression
-
-
Method Details