tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From fha...@apache.org
Subject svn commit: r380286 - /tomcat/container/tc5.5.x/modules/groupcom/src/share/org/apache/catalina/cluster/io/ReplicationStream.java
Date Fri, 24 Feb 2006 00:50:57 GMT
Author: fhanik
Date: Thu Feb 23 16:50:54 2006
New Revision: 380286

URL: http://svn.apache.org/viewcvs?rev=380286&view=rev
Log:
Played around with caching class lookups

Modified:
    tomcat/container/tc5.5.x/modules/groupcom/src/share/org/apache/catalina/cluster/io/ReplicationStream.java

Modified: tomcat/container/tc5.5.x/modules/groupcom/src/share/org/apache/catalina/cluster/io/ReplicationStream.java
URL: http://svn.apache.org/viewcvs/tomcat/container/tc5.5.x/modules/groupcom/src/share/org/apache/catalina/cluster/io/ReplicationStream.java?rev=380286&r1=380285&r2=380286&view=diff
==============================================================================
--- tomcat/container/tc5.5.x/modules/groupcom/src/share/org/apache/catalina/cluster/io/ReplicationStream.java
(original)
+++ tomcat/container/tc5.5.x/modules/groupcom/src/share/org/apache/catalina/cluster/io/ReplicationStream.java
Thu Feb 23 16:50:54 2006
@@ -21,6 +21,7 @@
 import java.io.IOException;
 import java.io.ObjectInputStream;
 import java.io.ObjectStreamClass;
+import java.util.HashMap;
 
 /**
  * Custom subclass of <code>ObjectInputStream</code> that loads from the
@@ -35,11 +36,12 @@
 
 public final class ReplicationStream extends ObjectInputStream {
 
-
+    
     /**
      * The class loader we will use to resolve classes.
      */
     private ClassLoader[] classLoaders = null;
+    
 
     /**
      * Construct a new instance of CustomObjectInputStream
@@ -88,7 +90,8 @@
     
     public Class findReplicationClass(String name)
         throws ClassNotFoundException, IOException {
-        return Class.forName(name, false, getClass().getClassLoader());
+        Class clazz = Class.forName(name, false, getClass().getClassLoader());
+        return clazz;
     }
 
     public Class findExternalClass(String name)
@@ -97,7 +100,8 @@
         ClassNotFoundException cnfe = null;
         for (int i=0; i<classLoaders.length; i++ ) {
             try {
-                return Class.forName(name, false, classLoaders[i]);
+                Class clazz = Class.forName(name, false, classLoaders[i]);
+                return clazz;
             } catch ( ClassNotFoundException x ) {
                 cnfe = x;
             } 



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


Mime
View raw message