Update of 
/cvsroot/xdoclet-plugins/xdoclet-plugins/plugin-tapestry/src/main/java/org/xdoclet/plugin/tapestry
In directory 
sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv27451/xdoclet-plugins/plugin-tapestry/src/main/java/org/xdoclet/plugin/tapestry

Modified Files:
        GenericTapestryPlugin.java 
Log Message:
Added getAbstractGetters method, needed by inject shortcut tags

Index: GenericTapestryPlugin.java
===================================================================
RCS file: 
/cvsroot/xdoclet-plugins/xdoclet-plugins/plugin-tapestry/src/main/java/org/xdoclet/plugin/tapestry/GenericTapestryPlugin.java,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** GenericTapestryPlugin.java  22 Aug 2005 09:47:24 -0000      1.1
--- GenericTapestryPlugin.java  7 Sep 2005 14:57:01 -0000       1.2
***************
*** 6,14 ****
--- 6,18 ----
  package org.xdoclet.plugin.tapestry;
  
+ import com.thoughtworks.qdox.model.JavaMethod;
  import java.util.ArrayList;
  import java.util.Collection;
  import java.util.Collections;
  import java.util.HashMap;
+ import java.util.HashSet;
+ import java.util.Iterator;
  import java.util.Map;
+ import java.util.Set;
  
  import org.apache.commons.collections.CollectionUtils;
***************
*** 51,57 ****
          return publicId;
      }
! 
      public String getSystemId() {
          return systemId;
      }
  }
\ No newline at end of file
--- 55,79 ----
          return publicId;
      }
!     
      public String getSystemId() {
          return systemId;
      }
+     
+     /**
+      * Determines all the abstract getters in a JavaClass
+      * @return a Set of JavaMethod objects
+      */
+     public Set getAbstractGetters(JavaClass clazz) {
+         Set abstractGetters = new HashSet();
+         JavaMethod[] methods = clazz.getMethods();
+ 
+         for (int i = 0; i < methods.length; i++) {
+             boolean abztract = methods[i].isAbstract();
+             boolean getter = methods[i].isPropertyAccessor();
+             if (abztract && getter) {
+                 abstractGetters.add(methods[i]);
+             }
+         }
+         return abstractGetters;
+     }
  }
\ No newline at end of file



-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO
September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices
Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA
Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf
_______________________________________________
xdoclet-plugins-commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/xdoclet-plugins-commits

Reply via email to