cocoon-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From coli...@apache.org
Subject cvs commit: cocoon-2.1/src/java/org/apache/cocoon/generation JXTemplateGenerator.java
Date Wed, 21 Apr 2004 21:37:50 GMT
coliver     2004/04/21 14:37:50

  Modified:    src/java/org/apache/cocoon/generation
                        JXTemplateGenerator.java
  Log:
  Support java.util.Iterator as value for 'items' in forEach
  
  Revision  Changes    Path
  1.40      +6 -3      cocoon-2.1/src/java/org/apache/cocoon/generation/JXTemplateGenerator.java
  
  Index: JXTemplateGenerator.java
  ===================================================================
  RCS file: /home/cvs/cocoon-2.1/src/java/org/apache/cocoon/generation/JXTemplateGenerator.java,v
  retrieving revision 1.39
  retrieving revision 1.40
  diff -u -r1.39 -r1.40
  --- JXTemplateGenerator.java	1 Apr 2004 16:50:32 -0000	1.39
  +++ JXTemplateGenerator.java	21 Apr 2004 21:37:49 -0000	1.40
  @@ -711,6 +711,9 @@
                               }
   
                           };
  +                } else if (obj instanceof Iterator) {
  +                    // support Iterator
  +                    return (Iterator)obj;
                   }
                   return super.getIterator(obj, i);
               }
  @@ -3284,8 +3287,8 @@
                                   iter = Introspector.getUberspect().getIterator(
                                           result,
                                           new Info(ev.location.getSystemId(),
  -                                                ev.location.getLineNumber(),
  -                                                ev.location.getColumnNumber()));
  +                                                 ev.location.getLineNumber(),
  +                                                 ev.location.getColumnNumber()));
                               }
                               if (iter == null) {
                                   iter = EMPTY_ITER;
  
  
  

Mime
View raw message