ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From j..@apache.org
Subject cvs commit: ant/src/main/org/apache/tools/ant ComponentHelper.java
Date Thu, 03 Mar 2005 14:04:27 GMT
jkf         2005/03/03 06:04:27

  Modified:    src/main/org/apache/tools/ant ComponentHelper.java
  Log:
  reduced visibility of the members not defined in super class of a private inner class
  removed unnecessary casts
  
  Revision  Changes    Path
  1.52      +7 -10     ant/src/main/org/apache/tools/ant/ComponentHelper.java
  
  Index: ComponentHelper.java
  ===================================================================
  RCS file: /home/cvs/ant/src/main/org/apache/tools/ant/ComponentHelper.java,v
  retrieving revision 1.51
  retrieving revision 1.52
  diff -u -r1.51 -r1.52
  --- ComponentHelper.java	1 Mar 2005 17:17:39 -0000	1.51
  +++ ComponentHelper.java	3 Mar 2005 14:04:27 -0000	1.52
  @@ -325,8 +325,7 @@
                       for (Iterator i = antTypeTable.keySet().iterator();
                            i.hasNext();) {
                           String name = (String) i.next();
  -                        Class clazz =
  -                            (Class) antTypeTable.getExposedClass(name);
  +                        Class clazz = antTypeTable.getExposedClass(name);
                           if (clazz == null) {
                               continue;
                           }
  @@ -358,8 +357,7 @@
                       for (Iterator i = antTypeTable.keySet().iterator();
                            i.hasNext();) {
                           String name = (String) i.next();
  -                        Class clazz =
  -                            (Class) antTypeTable.getExposedClass(name);
  +                        Class clazz = antTypeTable.getExposedClass(name);
                           if (clazz == null) {
                               continue;
                           }
  @@ -911,30 +909,29 @@
       private static class AntTypeTable extends Hashtable {
           private Project project;
   
  -        public AntTypeTable(Project project) {
  +        AntTypeTable(Project project) {
               this.project = project;
           }
   
  -        public AntTypeDefinition getDefinition(String key) {
  +        AntTypeDefinition getDefinition(String key) {
               return (AntTypeDefinition) (super.get(key));
           }
   
  -        /** Equivalent to getTypeType */
           public Object get(Object key) {
               return getTypeClass((String) key);
           }
   
  -        public Object create(String name) {
  +        Object create(String name) {
               AntTypeDefinition def = getDefinition(name);
               return (def == null) ? null : def.create(project);
           }
   
  -        public Class getTypeClass(String name) {
  +        Class getTypeClass(String name) {
               AntTypeDefinition def = getDefinition(name);
               return (def == null) ? null : def.getTypeClass(project);
           }
   
  -        public Class getExposedClass(String name) {
  +        Class getExposedClass(String name) {
               AntTypeDefinition def = getDefinition(name);
               return (def == null) ? null : def.getExposedClass(project);
           }
  
  
  

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


Mime
View raw message