ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From peterrei...@apache.org
Subject svn commit: r565104 - in /ant/core/trunk/src/main/org/apache/tools/ant: IntrospectionHelper.java Project.java PropertyHelper.java dispatch/DispatchUtils.java helper/ProjectHelper2.java helper/ProjectHelperImpl.java listener/TimestampedLogger.java
Date Sun, 12 Aug 2007 18:24:21 GMT
Author: peterreilly
Date: Sun Aug 12 11:24:20 2007
New Revision: 565104

URL: http://svn.apache.org/viewvc?view=rev&rev=565104
Log:
checkstyle

Modified:
    ant/core/trunk/src/main/org/apache/tools/ant/IntrospectionHelper.java
    ant/core/trunk/src/main/org/apache/tools/ant/Project.java
    ant/core/trunk/src/main/org/apache/tools/ant/PropertyHelper.java
    ant/core/trunk/src/main/org/apache/tools/ant/dispatch/DispatchUtils.java
    ant/core/trunk/src/main/org/apache/tools/ant/helper/ProjectHelper2.java
    ant/core/trunk/src/main/org/apache/tools/ant/helper/ProjectHelperImpl.java
    ant/core/trunk/src/main/org/apache/tools/ant/listener/TimestampedLogger.java

Modified: ant/core/trunk/src/main/org/apache/tools/ant/IntrospectionHelper.java
URL: http://svn.apache.org/viewvc/ant/core/trunk/src/main/org/apache/tools/ant/IntrospectionHelper.java?view=diff&rev=565104&r1=565103&r2=565104
==============================================================================
--- ant/core/trunk/src/main/org/apache/tools/ant/IntrospectionHelper.java (original)
+++ ant/core/trunk/src/main/org/apache/tools/ant/IntrospectionHelper.java Sun Aug 12 11:24:20
2007
@@ -1530,8 +1530,8 @@
             if (matchedDefinitionClass != null) {
                 throw new BuildException(
                     "ambiguous: restricted definitions for "
-                    + componentName + " " +
-                    matchedDefinitionClass + " and " + exposedClass);
+                    + componentName + " "
+                    + matchedDefinitionClass + " and " + exposedClass);
             }
             matchedDefinitionClass = exposedClass;
             definition = d;

Modified: ant/core/trunk/src/main/org/apache/tools/ant/Project.java
URL: http://svn.apache.org/viewvc/ant/core/trunk/src/main/org/apache/tools/ant/Project.java?view=diff&rev=565104&r1=565103&r2=565104
==============================================================================
--- ant/core/trunk/src/main/org/apache/tools/ant/Project.java (original)
+++ ant/core/trunk/src/main/org/apache/tools/ant/Project.java Sun Aug 12 11:24:20 2007
@@ -1648,6 +1648,7 @@
 
     /**
      * Get the Project instance associated with the specified object.
+     * @param o the object to query.
      * @return Project instance, if any.
      * @since Ant 1.7.1
      */

Modified: ant/core/trunk/src/main/org/apache/tools/ant/PropertyHelper.java
URL: http://svn.apache.org/viewvc/ant/core/trunk/src/main/org/apache/tools/ant/PropertyHelper.java?view=diff&rev=565104&r1=565103&r2=565104
==============================================================================
--- ant/core/trunk/src/main/org/apache/tools/ant/PropertyHelper.java (original)
+++ ant/core/trunk/src/main/org/apache/tools/ant/PropertyHelper.java Sun Aug 12 11:24:20 2007
@@ -108,7 +108,8 @@
     };
 
     private static final PropertyExpander DEFAULT_EXPANDER = new PropertyExpander() {
-        public String parsePropertyName(String s, ParsePosition pos, PropertyHelper propertyHelper)
{
+        public String parsePropertyName(
+            String s, ParsePosition pos, PropertyHelper propertyHelper) {
             int index = pos.getIndex();
             if (s.indexOf("${", index) == index) {
                 int end = s.indexOf('}', index);
@@ -124,19 +125,23 @@
     };
 
     /** dummy */
-    private static final PropertyExpander SKIP_$$ = new PropertyExpander() {
-        /**
-         * {@inheritDoc}
-         * @see org.apache.tools.ant.PropertyHelper.PropertyExpander#parsePropertyName(java.lang.String,
java.text.ParsePosition, org.apache.tools.ant.PropertyHelper)
-         */
-        public String parsePropertyName(String s, ParsePosition pos, PropertyHelper propertyHelper)
{
-            int index = pos.getIndex();
-            if (s.indexOf("$$", index) == index) {
-                pos.setIndex(++index);
+    private static final PropertyExpander SKIP_DOUBLE_DOLLAR
+        = new PropertyExpander() {
+            // CheckStyle:LineLengthCheck OFF see too long
+            /**
+             * {@inheritDoc}
+             * @see org.apache.tools.ant.PropertyHelper.PropertyExpander#parsePropertyName(java.lang.String,
java.text.ParsePosition, org.apache.tools.ant.PropertyHelper)
+             */
+            // CheckStyle:LineLengthCheck ON
+            public String parsePropertyName(
+                String s, ParsePosition pos, PropertyHelper propertyHelper) {
+                int index = pos.getIndex();
+                if (s.indexOf("$$", index) == index) {
+                    pos.setIndex(++index);
+                }
+                return null;
             }
-            return null;
-        }
-    };
+        };
 
     private Project project;
     private PropertyHelper next;
@@ -164,7 +169,7 @@
      */
     protected PropertyHelper() {
         add(TO_STRING);
-        add(SKIP_$$);
+        add(SKIP_DOUBLEDOLLAR);
         add(DEFAULT_EXPANDER);
     }
 
@@ -457,8 +462,10 @@
     }
 
     private String parsePropertyName(String value, ParsePosition pos) {
-        for (Iterator iter = getDelegates(PropertyExpander.class).iterator(); iter.hasNext();)
{
-            String propertyName = ((PropertyExpander) iter.next()).parsePropertyName(value,
pos, this);
+        for (Iterator iter = getDelegates(PropertyExpander.class).iterator();
+             iter.hasNext();) {
+            String propertyName = ((PropertyExpander) iter.next())
+                .parsePropertyName(value, pos, this);
             if (propertyName == null) {
                 continue;
             }

Modified: ant/core/trunk/src/main/org/apache/tools/ant/dispatch/DispatchUtils.java
URL: http://svn.apache.org/viewvc/ant/core/trunk/src/main/org/apache/tools/ant/dispatch/DispatchUtils.java?view=diff&rev=565104&r1=565103&r2=565104
==============================================================================
--- ant/core/trunk/src/main/org/apache/tools/ant/dispatch/DispatchUtils.java (original)
+++ ant/core/trunk/src/main/org/apache/tools/ant/dispatch/DispatchUtils.java Sun Aug 12 11:24:20
2007
@@ -27,6 +27,7 @@
 /**
  * Determines and Executes the action method for the task.
  */
+// CheckStyle:HideUtilityClassConstructorCheck OFF - (bc)
 public class DispatchUtils {
     /**
      * Determines and Executes the action method for the task.

Modified: ant/core/trunk/src/main/org/apache/tools/ant/helper/ProjectHelper2.java
URL: http://svn.apache.org/viewvc/ant/core/trunk/src/main/org/apache/tools/ant/helper/ProjectHelper2.java?view=diff&rev=565104&r1=565103&r2=565104
==============================================================================
--- ant/core/trunk/src/main/org/apache/tools/ant/helper/ProjectHelper2.java (original)
+++ ant/core/trunk/src/main/org/apache/tools/ant/helper/ProjectHelper2.java Sun Aug 12 11:24:20
2007
@@ -965,7 +965,8 @@
                 // be namespaced, need to extract the name
                 // and convert from qualified name to uri/name
                 if (ANT_TYPE.equals(name)
-                        || (ANT_CORE_URI.equals(attrUri) && ANT_TYPE.equals(attrs.getLocalName(i))))
{
+                        || (ANT_CORE_URI.equals(attrUri)
+                            && ANT_TYPE.equals(attrs.getLocalName(i)))) {
                     name = ANT_TYPE;
                     int index = value.indexOf(":");
                     if (index >= 0) {

Modified: ant/core/trunk/src/main/org/apache/tools/ant/helper/ProjectHelperImpl.java
URL: http://svn.apache.org/viewvc/ant/core/trunk/src/main/org/apache/tools/ant/helper/ProjectHelperImpl.java?view=diff&rev=565104&r1=565103&r2=565104
==============================================================================
--- ant/core/trunk/src/main/org/apache/tools/ant/helper/ProjectHelperImpl.java (original)
+++ ant/core/trunk/src/main/org/apache/tools/ant/helper/ProjectHelperImpl.java Sun Aug 12
11:24:20 2007
@@ -397,7 +397,8 @@
                     baseDir = value;
                 } else {
                     throw new SAXParseException(
-                            "Unexpected attribute \"" + attrs.getName(i) + "\"", helperImpl.locator);
+                            "Unexpected attribute \"" + attrs.getName(i)
+                            + "\"", helperImpl.locator);
                 }
             }
 

Modified: ant/core/trunk/src/main/org/apache/tools/ant/listener/TimestampedLogger.java
URL: http://svn.apache.org/viewvc/ant/core/trunk/src/main/org/apache/tools/ant/listener/TimestampedLogger.java?view=diff&rev=565104&r1=565103&r2=565104
==============================================================================
--- ant/core/trunk/src/main/org/apache/tools/ant/listener/TimestampedLogger.java (original)
+++ ant/core/trunk/src/main/org/apache/tools/ant/listener/TimestampedLogger.java Sun Aug 12
11:24:20 2007
@@ -20,9 +20,6 @@
 
 import org.apache.tools.ant.DefaultLogger;
 
-import java.util.Date;
-import java.text.DateFormat;
-
 /**
  * Like a normal logger, except with timed outputs
  */



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


Mime
View raw message