zongaro     2005/01/24 12:51:24

  Modified:    java/src/org/apache/xpath CachedXPathAPI.java
  Log:
  Fix for Jira bug report XALANJ-1811.
  
  Updated Javadocs for constructors to make it clear that a single instance of
  CachecXPathAPI must not be used by multiple threads without synchronization.
  
  Reviewed by Christine Li (jycli () ca ! ibm ! com)
  
  Revision  Changes    Path
  1.7       +22 -13    xml-xalan/java/src/org/apache/xpath/CachedXPathAPI.java
  
  Index: CachedXPathAPI.java
  ===================================================================
  RCS file: /home/cvs/xml-xalan/java/src/org/apache/xpath/CachedXPathAPI.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- CachedXPathAPI.java       23 Jan 2005 01:02:10 -0000      1.6
  +++ CachedXPathAPI.java       24 Jan 2005 20:51:23 -0000      1.7
  @@ -59,24 +59,33 @@
     */
     protected XPathContext xpathSupport;
   
  -  /** Default constructor. Establishes its own XPathContext, and hence
  -   *  its own DTMManager.  Good choice for simple uses.
  -   * */
  +  /**
  +   * <p>Default constructor. Establishes its own [EMAIL PROTECTED] 
XPathContext}, and hence
  +   * its own [EMAIL PROTECTED] org.apache.xml.dtm.DTMManager}.
  +   * Good choice for simple uses.</p>
  +   * <p>Note that any particular instance of [EMAIL PROTECTED] 
CachedXPathAPI} must not be
  +   * operated upon by multiple threads without synchronization; we do
  +   * not currently support multithreaded access to a single
  +   * [EMAIL PROTECTED] org.apache.xml.dtm.DTM}.</p>
  +   */
     public CachedXPathAPI()
     {
       xpathSupport = new XPathContext();
     }
     
  -  /** This constructor shares its XPathContext with a pre-existing
  -   *  CachedXPathAPI.  That allows sharing document models (DTMs) and
  -   *  previously established location state.
  +  /**
  +   * <p>This constructor shares its [EMAIL PROTECTED] XPathContext} with a 
pre-existing
  +   * [EMAIL PROTECTED] CachedXPathAPI}.  That allows sharing document models
  +   * ([EMAIL PROTECTED] org.apache.xml.dtm.DTM}) and previously established 
location
  +   * state.</p>
  +   * <p>Note that the original [EMAIL PROTECTED] CachedXPathAPI} and the new 
one should
  +   * not be operated upon concurrently; we do not support multithreaded 
access
  +   * to a single [EMAIL PROTECTED] org.apache.xml.dtm.DTM} at this time.  
Similarly,
  +   * any particular instance of [EMAIL PROTECTED] CachedXPathAPI} must not 
be operated
  +   * upon by multiple threads without synchronization.</p>
  +   * <p>%REVIEW% Should this instead do a clone-and-reset on the 
XPathSupport object?</p>
      *
  -   *  Note that the original CachedXPathAPI and the new one should not
  -   *  be operated concurrently; we do not support multithreaded access
  -   *  to a single DTM at this time.
  -   *
  -   *  %REVIEW% Should this instead do a clone-and-reset on the XPathSupport 
object?
  -   * */
  +   */
     public CachedXPathAPI(CachedXPathAPI priorXPathAPI)
     {
       xpathSupport = priorXPathAPI.xpathSupport;
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to