avalon-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From hamm...@apache.org
Subject cvs commit: jakarta-avalon-excalibur/altrmi/src/java/org/apache/excalibur/altrmi/server/impl ServerObjectStreamReadWriter.java
Date Thu, 05 Sep 2002 22:22:38 GMT
hammant     2002/09/05 15:22:37

  Modified:    altrmi/src/java/org/apache/excalibur/altrmi/client/impl
                        ClientClassAltrmiFactory.java
                        DefaultInterfaceLookupFactory.java
               altrmi/src/java/org/apache/excalibur/altrmi/client/impl/stream
                        ClientObjectStreamReadWriter.java
               altrmi/src/java/org/apache/excalibur/altrmi/common
                        ClassLoaderObjectInputStream.java
               altrmi/src/java/org/apache/excalibur/altrmi/javacompiler
                        JavaCompiler.java
               altrmi/src/java/org/apache/excalibur/altrmi/server/impl
                        ServerObjectStreamReadWriter.java
  Log:
  Remove last Class.forName()s
  
  Revision  Changes    Path
  1.7       +2 -2      jakarta-avalon-excalibur/altrmi/src/java/org/apache/excalibur/altrmi/client/impl/ClientClassAltrmiFactory.java
  
  Index: ClientClassAltrmiFactory.java
  ===================================================================
  RCS file: /home/cvs/jakarta-avalon-excalibur/altrmi/src/java/org/apache/excalibur/altrmi/client/impl/ClientClassAltrmiFactory.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- ClientClassAltrmiFactory.java	6 May 2002 18:14:36 -0000	1.6
  +++ ClientClassAltrmiFactory.java	5 Sep 2002 22:22:36 -0000	1.7
  @@ -45,7 +45,7 @@
               code = "";
           }
   
  -        return Class.forName( "AltrmiGenerated" + code + publishedServiceName + "_" + objectName
);
  +        return this.getClass().getClassLoader().loadClass( "AltrmiGenerated" + code + publishedServiceName
+ "_" + objectName );
       }
   
       /**
  
  
  
  1.4       +3 -3      jakarta-avalon-excalibur/altrmi/src/java/org/apache/excalibur/altrmi/client/impl/DefaultInterfaceLookupFactory.java
  
  Index: DefaultInterfaceLookupFactory.java
  ===================================================================
  RCS file: /home/cvs/jakarta-avalon-excalibur/altrmi/src/java/org/apache/excalibur/altrmi/client/impl/DefaultInterfaceLookupFactory.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- DefaultInterfaceLookupFactory.java	24 Apr 2002 12:42:56 -0000	1.3
  +++ DefaultInterfaceLookupFactory.java	5 Sep 2002 22:22:36 -0000	1.4
  @@ -34,7 +34,7 @@
           {
               addFactory(
                   "SocketObjectStream:",
  -                (AltrmiInterfaceLookupFactory)Class.forName(
  +                (AltrmiInterfaceLookupFactory)this.getClass().getClassLoader().loadClass(
                       "org.apache.excalibur.altrmi.client.impl.socket.SocketObjectStreamFactoryHelper"
)
                                                 .newInstance() );
           }
  @@ -52,7 +52,7 @@
           {
               addFactory(
                   "SocketCustomStream:",
  -                (AltrmiInterfaceLookupFactory)Class.forName(
  +                (AltrmiInterfaceLookupFactory)this.getClass().getClassLoader().loadClass(
                       "org.apache.excalibur.altrmi.client.impl.socket.SocketCustomStreamFactoryHelper"
)
                                                 .newInstance() );
           }
  
  
  
  1.3       +3 -3      jakarta-avalon-excalibur/altrmi/src/java/org/apache/excalibur/altrmi/client/impl/stream/ClientObjectStreamReadWriter.java
  
  Index: ClientObjectStreamReadWriter.java
  ===================================================================
  RCS file: /home/cvs/jakarta-avalon-excalibur/altrmi/src/java/org/apache/excalibur/altrmi/client/impl/stream/ClientObjectStreamReadWriter.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- ClientObjectStreamReadWriter.java	24 Apr 2002 12:42:58 -0000	1.2
  +++ ClientObjectStreamReadWriter.java	5 Sep 2002 22:22:36 -0000	1.3
  @@ -60,12 +60,12 @@
   
           try
           {
  -            Class clazz = Class.forName( mObjectOutputStreamClassName );
  +            Class clazz = this.getClass().getClassLoader().loadClass( mObjectOutputStreamClassName
);
               Constructor con = clazz.getConstructor( new Class[]{OutputStream.class} );
   
               mObjectOutputStream = (ObjectOutputStream)con.newInstance( new Object[]{
                   outputStream} );
  -            clazz = Class.forName( mObjectInputStreamClassName );
  +            clazz = this.getClass().getClassLoader().loadClass( mObjectInputStreamClassName
);
               con = clazz.getConstructor( new Class[]{InputStream.class} );
               mObjectInputStream = (ObjectInputStream)con.newInstance( new Object[]{inputStream}
);
           }
  
  
  
  1.5       +1 -1      jakarta-avalon-excalibur/altrmi/src/java/org/apache/excalibur/altrmi/common/ClassLoaderObjectInputStream.java
  
  Index: ClassLoaderObjectInputStream.java
  ===================================================================
  RCS file: /home/cvs/jakarta-avalon-excalibur/altrmi/src/java/org/apache/excalibur/altrmi/common/ClassLoaderObjectInputStream.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- ClassLoaderObjectInputStream.java	24 Aug 2002 11:39:05 -0000	1.4
  +++ ClassLoaderObjectInputStream.java	5 Sep 2002 22:22:36 -0000	1.5
  @@ -62,7 +62,7 @@
   
           try
           {
  -            clazz = Class.forName( objectStreamClass.getName(), false, m_classLoader );
  +            clazz = m_classLoader.loadClass( objectStreamClass.getName());
           }
           catch( ClassNotFoundException cnfe )
           {
  
  
  
  1.4       +3 -3      jakarta-avalon-excalibur/altrmi/src/java/org/apache/excalibur/altrmi/javacompiler/JavaCompiler.java
  
  Index: JavaCompiler.java
  ===================================================================
  RCS file: /home/cvs/jakarta-avalon-excalibur/altrmi/src/java/org/apache/excalibur/altrmi/javacompiler/JavaCompiler.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- JavaCompiler.java	24 Apr 2002 12:43:00 -0000	1.3
  +++ JavaCompiler.java	5 Sep 2002 22:22:37 -0000	1.4
  @@ -206,17 +206,17 @@
        * Method getCompilerPluginClass
        *
        *
  -     * @param s
  +     * @param compilerClassName the compiler class name.
        *
        * @return
        *
        */
  -    public static Class getCompilerPluginClass( String s )
  +    public static Class getCompilerPluginClass( String compilerClassName )
       {
   
           try
           {
  -            Class c = Class.forName( s );
  +            Class c = JavaCompiler.class.getClassLoader().loadClass( compilerClassName
);
   
               return c;
           }
  
  
  
  1.4       +3 -3      jakarta-avalon-excalibur/altrmi/src/java/org/apache/excalibur/altrmi/server/impl/ServerObjectStreamReadWriter.java
  
  Index: ServerObjectStreamReadWriter.java
  ===================================================================
  RCS file: /home/cvs/jakarta-avalon-excalibur/altrmi/src/java/org/apache/excalibur/altrmi/server/impl/ServerObjectStreamReadWriter.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- ServerObjectStreamReadWriter.java	24 Apr 2002 12:43:01 -0000	1.3
  +++ ServerObjectStreamReadWriter.java	5 Sep 2002 22:22:37 -0000	1.4
  @@ -60,12 +60,12 @@
   
           try
           {
  -            Class clazz = Class.forName( mObjectInputStreamClassName );
  +            Class clazz = this.getClass().getClassLoader().loadClass( mObjectInputStreamClassName
);
               Constructor con = clazz.getConstructor( new Class[]{InputStream.class} );
   
               mObjectInputStream = (ObjectInputStream)con.newInstance( new Object[]{
                   mInputStream} );
  -            clazz = Class.forName( mObjectOutputStreamClassName );
  +            clazz = this.getClass().getClassLoader().loadClass( mObjectOutputStreamClassName
);
               con = clazz.getConstructor( new Class[]{OutputStream.class} );
               mObjectOutputStream = (ObjectOutputStream)con.newInstance( new Object[]{
                   mOutputStream} );
  
  
  

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


Mime
View raw message