On Tue, 9 Nov 2021 06:27:15 GMT, Joe Wang <jo...@openjdk.org> wrote:

>> src/java.xml/share/classes/javax/xml/xpath/XPathFactory.java line 375:
>> 
>>> 373:     /**
>>> 374:      * Sets a property for this {@code XPathFactory} and {@code XPath}
>>> 375:      * created by this factory.
>> 
>> Are properties inherited by the XPath object at create time? The javadoc for 
>> newXPath suggests so and I'm wondering if the javadoc for setProperty needs 
>> to consistent with that. Maybe the intention is really that this method sets 
>> a XPathFactory property and it is used when configuring the XPath object 
>> returned by the newXPath method.
>
> Yes. Made a clarification to the javadoc, and while we are here, to 
> setFeature method as well.

One other suggestion for wording is to change:
"A property set on the factory is effective to the XPath object created 
thereafter"
to something like:
"The property applies to XPath objects that the XPathFactory creates. It has no 
impact on XPath objects that are already created."

I don't have any other comments on the API.

-------------

PR: https://git.openjdk.java.net/jdk/pull/6215

Reply via email to