You are viewing a plain text version of this content. The canonical link for it is here.
Posted to slide-dev@jakarta.apache.org by oz...@apache.org on 2004/07/15 14:37:36 UTC

cvs commit: jakarta-slide/webdavclient/connector/src/java/org/apache/webdav/connector WebDAVLocalTransaction.java WebDAVConnection.java WebDAVManagedConnectionFactory.java WebDAVConnectionSpec.java WebDAVConnectionFactory.java

ozeigermann    2004/07/15 05:37:36

  Modified:    webdavclient/connector/src/java/org/apache/webdav/connector
                        WebDAVLocalTransaction.java WebDAVConnection.java
                        WebDAVManagedConnectionFactory.java
                        WebDAVConnectionSpec.java
                        WebDAVConnectionFactory.java
  Log:
  Cleaned stuff a bit and added rudimentary Javadocs
  
  Revision  Changes    Path
  1.2       +7 -7      jakarta-slide/webdavclient/connector/src/java/org/apache/webdav/connector/WebDAVLocalTransaction.java
  
  Index: WebDAVLocalTransaction.java
  ===================================================================
  RCS file: /home/cvs/jakarta-slide/webdavclient/connector/src/java/org/apache/webdav/connector/WebDAVLocalTransaction.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- WebDAVLocalTransaction.java	12 Jul 2004 15:21:54 -0000	1.1
  +++ WebDAVLocalTransaction.java	15 Jul 2004 12:37:36 -0000	1.2
  @@ -35,9 +35,9 @@
    */
   public class WebDAVLocalTransaction implements javax.resource.spi.LocalTransaction, javax.resource.cci.LocalTransaction {
   
  -    WebdavResource webdavResource;
  -    String owner;
  -    int timeout;
  +    protected WebdavResource webdavResource;
  +    protected String owner;
  +    protected int timeout;
   
       public WebDAVLocalTransaction(WebdavResource webdavResource, String owner, int timeout) {
           this.webdavResource = webdavResource;
  
  
  
  1.2       +13 -5     jakarta-slide/webdavclient/connector/src/java/org/apache/webdav/connector/WebDAVConnection.java
  
  Index: WebDAVConnection.java
  ===================================================================
  RCS file: /home/cvs/jakarta-slide/webdavclient/connector/src/java/org/apache/webdav/connector/WebDAVConnection.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- WebDAVConnection.java	12 Jul 2004 15:21:54 -0000	1.1
  +++ WebDAVConnection.java	15 Jul 2004 12:37:36 -0000	1.2
  @@ -34,7 +34,9 @@
   import org.apache.webdav.lib.WebdavResource;
   
   /**
  - *   
  + * Abstraction of a connection to a Slide (WebDAV) server. All actual requests are made via the
  + * {@link WebdavResource} the user gets with {@link #getWebdavResource()}.
  + * 
    * @version $Revision$
    * 
    */
  @@ -46,6 +48,12 @@
           this.mc = (WebDAVManagedConnection) mc;
       }
   
  +    /**
  +     * Returns the {@link WebdavResource} that has been associated to this WebDAV connection. All actual requests
  +     * to the WebDAV server are done with this{@link WebdavResource}.  
  +     * 
  +     * @return the {@link WebdavResource} associated to this connection 
  +     */
       public WebdavResource getWebdavResource() {
           return mc.getWebdavResource();
       }
  
  
  
  1.4       +5 -5      jakarta-slide/webdavclient/connector/src/java/org/apache/webdav/connector/WebDAVManagedConnectionFactory.java
  
  Index: WebDAVManagedConnectionFactory.java
  ===================================================================
  RCS file: /home/cvs/jakarta-slide/webdavclient/connector/src/java/org/apache/webdav/connector/WebDAVManagedConnectionFactory.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- WebDAVManagedConnectionFactory.java	14 Jul 2004 10:09:17 -0000	1.3
  +++ WebDAVManagedConnectionFactory.java	15 Jul 2004 12:37:36 -0000	1.4
  @@ -44,7 +44,7 @@
    */
   public class WebDAVManagedConnectionFactory implements ManagedConnectionFactory {
   
  -    private PrintWriter writer;
  +    protected PrintWriter writer;
   
       /**
        * @see ManagedConnectionFactory#createConnectionFactory(ConnectionManager)
  
  
  
  1.3       +24 -7     jakarta-slide/webdavclient/connector/src/java/org/apache/webdav/connector/WebDAVConnectionSpec.java
  
  Index: WebDAVConnectionSpec.java
  ===================================================================
  RCS file: /home/cvs/jakarta-slide/webdavclient/connector/src/java/org/apache/webdav/connector/WebDAVConnectionSpec.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- WebDAVConnectionSpec.java	13 Jul 2004 14:13:16 -0000	1.2
  +++ WebDAVConnectionSpec.java	15 Jul 2004 12:37:36 -0000	1.3
  @@ -31,7 +31,8 @@
   import org.apache.commons.httpclient.URIException;
   
   /**
  - *   
  + * Specifies where the {@link WebDAVConnection} shall go to. 
  + *  
    * @version $Revision$
    * 
    */
  @@ -41,13 +42,29 @@
       protected HttpURL httpURL;
       protected int timeout;
       
  +    /**
  +     * Creates a specification where the {@link WebDAVConnection} shall go to.
  +     * 
  +     * @param httpURL complete url of the Slide (WebDAV) server including user and password
  +     * @param timeout timeout of the externally controlled transaction 
  +     */
       public WebDAVConnectionSpec(HttpURL httpURL, int timeout) {
           this.httpURL = httpURL;
           this.timeout = timeout; 
       
       }
  -    public WebDAVConnectionSpec(String uri, String userName, String password, int timeout) throws URIException {
  -        this.httpURL = uri.startsWith("https") ? new HttpsURL(uri.toCharArray()) : new HttpURL(uri.toCharArray());
  +
  +    /**
  +     * Creates a specification where the {@link WebDAVConnection} shall go to.
  +     * 
  +     * @param url url string of the Slide (WebDAV) server
  +     * @param userName user name for login to the Slide (WebDAV) server
  +     * @param password password for login to the Slide (WebDAV) server
  +     * @param timeout timeout of the externally controlled transaction 
  +     * @throws URIException if the given uri is not a valid one
  +     */
  +    public WebDAVConnectionSpec(String url, String userName, String password, int timeout) throws URIException {
  +        this.httpURL = url.startsWith("https") ? new HttpsURL(url) : new HttpURL(url);
           this.httpURL.setUserinfo(userName, password);
           this.timeout = timeout; 
       }
  
  
  
  1.2       +7 -7      jakarta-slide/webdavclient/connector/src/java/org/apache/webdav/connector/WebDAVConnectionFactory.java
  
  Index: WebDAVConnectionFactory.java
  ===================================================================
  RCS file: /home/cvs/jakarta-slide/webdavclient/connector/src/java/org/apache/webdav/connector/WebDAVConnectionFactory.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- WebDAVConnectionFactory.java	12 Jul 2004 15:21:54 -0000	1.1
  +++ WebDAVConnectionFactory.java	15 Jul 2004 12:37:36 -0000	1.2
  @@ -42,9 +42,9 @@
    */
   public class WebDAVConnectionFactory implements ConnectionFactory {
   
  -    Reference reference;
  -    ConnectionManager cm;
  -    ManagedConnectionFactory mcf;
  +    protected Reference reference;
  +    protected ConnectionManager cm;
  +    protected ManagedConnectionFactory mcf;
   
       public WebDAVConnectionFactory(ManagedConnectionFactory mcf, ConnectionManager cm) {
           System.out.println("MCF Init with mcf " + mcf + " cm " + cm);
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: slide-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: slide-dev-help@jakarta.apache.org