tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From craig...@apache.org
Subject cvs commit: jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/users MemoryUserDatabase.java MemoryUserDatabaseFactory.java
Date Tue, 22 Jan 2002 23:41:38 GMT
craigmcc    02/01/22 15:41:38

  Modified:    catalina/src/share/org/apache/catalina/users
                        MemoryUserDatabase.java
                        MemoryUserDatabaseFactory.java
  Log:
  Some versions of Xerces whine about the spelling of the encoding provided
  by the JDK, so desupport this.
  
  Revision  Changes    Path
  1.3       +6 -43     jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/users/MemoryUserDatabase.java
  
  Index: MemoryUserDatabase.java
  ===================================================================
  RCS file: /home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/users/MemoryUserDatabase.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- MemoryUserDatabase.java	22 Jan 2002 23:22:24 -0000	1.2
  +++ MemoryUserDatabase.java	22 Jan 2002 23:41:38 -0000	1.3
  @@ -1,7 +1,7 @@
   /*
  - * $Header: /home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/users/MemoryUserDatabase.java,v
1.2 2002/01/22 23:22:24 craigmcc Exp $
  - * $Revision: 1.2 $
  - * $Date: 2002/01/22 23:22:24 $
  + * $Header: /home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/users/MemoryUserDatabase.java,v
1.3 2002/01/22 23:41:38 craigmcc Exp $
  + * $Revision: 1.3 $
  + * $Date: 2002/01/22 23:41:38 $
    *
    * ====================================================================
    * The Apache Software License, Version 1.1
  @@ -87,7 +87,7 @@
    * a specified XML file for its persistent storage.</p>
    *
    * @author Craig R. McClanahan
  - * @version $Revision: 1.2 $ $Date: 2002/01/22 23:22:24 $
  + * @version $Revision: 1.3 $ $Date: 2002/01/22 23:41:38 $
    * @since 4.1
    */
   
  @@ -124,14 +124,6 @@
   
   
       /**
  -     * The character encoding to be used when reading and writing our
  -     * persistent storage file, or <code>null</code> for the platform
  -     * default encoding.
  -     */
  -    protected String encoding = null;
  -
  -
  -    /**
        * The set of {@link Group}s defined in this database, keyed by
        * group name.
        */
  @@ -183,28 +175,6 @@
   
   
       /**
  -     * Return the character encoding for our persistent storage file.
  -     */
  -    public String getEncoding() {
  -
  -        return (this.encoding);
  -
  -    }
  -
  -
  -    /**
  -     * Set the character encoding for our persistent storage file.
  -     *
  -     * @param encoding The new encoding
  -     */
  -    public void setEncoding(String encoding) {
  -
  -        this.encoding = encoding;
  -
  -    }
  -
  -
  -    /**
        * Return the set of {@link Group}s defined in this user database.
        */
       public Iterator getGroups() {
  @@ -456,18 +426,11 @@
   
               // Configure our PrintWriter
               FileOutputStream fos = new FileOutputStream(fileNew);
  -            OutputStreamWriter osw = null;
  -            if (encoding == null) {
  -                osw = new OutputStreamWriter(fos);
  -            } else {
  -                osw = new OutputStreamWriter(fos, encoding);
  -            }
  +            OutputStreamWriter osw = new OutputStreamWriter(fos);
               writer = new PrintWriter(osw);
   
               // Print the file prolog
  -            writer.print("<?xml version='1.0' encoding='");
  -            writer.print(osw.getEncoding());
  -            writer.println("'?>");
  +            writer.println("<?xml version='1.0'?>");
               writer.println("<tomcat-users>");
   
               // Print entries for each defined group and user
  
  
  
  1.3       +4 -12     jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/users/MemoryUserDatabaseFactory.java
  
  Index: MemoryUserDatabaseFactory.java
  ===================================================================
  RCS file: /home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/users/MemoryUserDatabaseFactory.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- MemoryUserDatabaseFactory.java	22 Jan 2002 23:22:24 -0000	1.2
  +++ MemoryUserDatabaseFactory.java	22 Jan 2002 23:41:38 -0000	1.3
  @@ -1,7 +1,7 @@
   /*
  - * $Header: /home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/users/MemoryUserDatabaseFactory.java,v
1.2 2002/01/22 23:22:24 craigmcc Exp $
  - * $Revision: 1.2 $
  - * $Date: 2002/01/22 23:22:24 $
  + * $Header: /home/cvs/jakarta-tomcat-4.0/catalina/src/share/org/apache/catalina/users/MemoryUserDatabaseFactory.java,v
1.3 2002/01/22 23:41:38 craigmcc Exp $
  + * $Revision: 1.3 $
  + * $Date: 2002/01/22 23:41:38 $
    *
    * ====================================================================
    * The Apache Software License, Version 1.1
  @@ -84,9 +84,6 @@
    * <p>The <code>MemoryUserDatabase</code> instance is configured based
    * on the following parameter values:</p>
    * <ul>
  - * <li><strong>encoding</strong> - The character encoding to use when
  - *     saving the user information to the specified XML file.
  - *     [Server platform default encoding]</li>
    * <li><strong>pathname</strong> - Absolute or relative (to the directory
    *     path specified by the <code>catalina.base</code> system property)
    *     pathname to the XML file from which our user information is loaded,
  @@ -94,7 +91,7 @@
    * </ul>
    *
    * @author Craig R. McClanahan
  - * @version $Revision: 1.2 $ $Date: 2002/01/22 23:22:24 $
  + * @version $Revision: 1.3 $ $Date: 2002/01/22 23:41:38 $
    * @since 4.1
    */
   
  @@ -137,11 +134,6 @@
           // RefAddr values associated with this Reference
           MemoryUserDatabase database = new MemoryUserDatabase(name.toString());
           RefAddr ra = null;
  -
  -        ra = ref.get("encoding");
  -        if (ra != null) {
  -            database.setEncoding(ra.getContent().toString());
  -        }
   
           ra = ref.get("pathname");
           if (ra != null) {
  
  
  

--
To unsubscribe, e-mail:   <mailto:tomcat-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:tomcat-dev-help@jakarta.apache.org>


Mime
View raw message