geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From gno...@apache.org
Subject svn commit: r432605 - /geronimo/xbean/trunk/xbean-spring-common/src/main/java/org/apache/xbean/spring/generator/QdoxMappingLoader.java
Date Fri, 18 Aug 2006 14:41:11 GMT
Author: gnodet
Date: Fri Aug 18 07:41:08 2006
New Revision: 432605

URL: http://svn.apache.org/viewvc?rev=432605&view=rev
Log:
Fix infinite loop introduced in XBEAN-33 when parsing interfaces
Put spaces instead of tabs and fix a typo

Modified:
    geronimo/xbean/trunk/xbean-spring-common/src/main/java/org/apache/xbean/spring/generator/QdoxMappingLoader.java

Modified: geronimo/xbean/trunk/xbean-spring-common/src/main/java/org/apache/xbean/spring/generator/QdoxMappingLoader.java
URL: http://svn.apache.org/viewvc/geronimo/xbean/trunk/xbean-spring-common/src/main/java/org/apache/xbean/spring/generator/QdoxMappingLoader.java?rev=432605&r1=432604&r2=432605&view=diff
==============================================================================
--- geronimo/xbean/trunk/xbean-spring-common/src/main/java/org/apache/xbean/spring/generator/QdoxMappingLoader.java
(original)
+++ geronimo/xbean/trunk/xbean-spring-common/src/main/java/org/apache/xbean/spring/generator/QdoxMappingLoader.java
Fri Aug 18 07:41:08 2006
@@ -261,22 +261,20 @@
         }
 
         HashSet interfaces = new HashSet();
-        interfaces.addAll( getFullyQulifiedNames( javaClass.getImplementedInterfaces() )
);
+        interfaces.addAll( getFullyQualifiedNames( javaClass.getImplementedInterfaces() )
);
 
-    	System.out.println("Checking: "+javaClass.getFullyQualifiedName());
+        System.out.println("Checking: "+javaClass.getFullyQualifiedName());
 
-    	ArrayList superClasses = new ArrayList();        
+        ArrayList superClasses = new ArrayList();
         JavaClass p = javaClass;
         while( true ) {
-
-            JavaClass s = javaClass.getSuperJavaClass();
-            if(  s==null || s.equals(p) || "java.lang.Object".equals(s.getFullyQualifiedName())
) {
-            	break;
+            JavaClass s = p.getSuperJavaClass();
+            if( s==null || s.equals(p) || "java.lang.Object".equals(s.getFullyQualifiedName())
) {
+                break;
             }
-        	p=s;
-        	
-        	superClasses.add(p.getFullyQualifiedName());
-            interfaces.addAll( getFullyQulifiedNames( p.getImplementedInterfaces() ) );
+            p = s;
+            superClasses.add(p.getFullyQualifiedName());
+            interfaces.addAll( getFullyQualifiedNames( p.getImplementedInterfaces() ) );
         }
 
         return new ElementMapping(namespace,
@@ -297,15 +295,15 @@
                 interfaces);
     }
 
-    private List getFullyQulifiedNames(JavaClass[] implementedInterfaces) {
-    	ArrayList l = new ArrayList();
-    	for (int i = 0; i < implementedInterfaces.length; i++) {
-			l.add( implementedInterfaces[i].getFullyQualifiedName() );
-		}
-		return l;
-	}
+    private List getFullyQualifiedNames(JavaClass[] implementedInterfaces) {
+        ArrayList l = new ArrayList();
+        for (int i = 0; i < implementedInterfaces.length; i++) {
+            l.add( implementedInterfaces[i].getFullyQualifiedName() );
+        }
+        return l;
+    }
 
-	private String getElementName(JavaClass javaClass, DocletTag tag) {
+    private String getElementName(JavaClass javaClass, DocletTag tag) {
         String elementName = getProperty(tag, "element");
         if (elementName == null) {
             String className = javaClass.getFullyQualifiedName();



Mime
View raw message