From c87252eaff5db00138f3056457709ad569aa048e Mon Sep 17 00:00:00 2001 From: Conor MacNeill Date: Tue, 5 Feb 2002 11:59:28 +0000 Subject: [PATCH] A little bit of checkstyle (thanks Oliver) Build fiel changes git-svn-id: https://svn.apache.org/repos/asf/ant/core/trunk@271150 13f79535-47bb-0310-9956-ffa450edef68 --- proposal/mutant/ant1compat.xml | 5 ++- proposal/mutant/build.xml | 2 +- .../ant/antcore/execution/ExecutionFrame.java | 1 - .../org/apache/ant/antlib/system/AntBase.java | 45 ++++++++++++++----- .../ant/common/antlib/AbstractComponent.java | 7 +-- .../apache/ant/common/util/AntException.java | 3 +- 6 files changed, 43 insertions(+), 20 deletions(-) diff --git a/proposal/mutant/ant1compat.xml b/proposal/mutant/ant1compat.xml index 9e572a121..4b89f002e 100644 --- a/proposal/mutant/ant1compat.xml +++ b/proposal/mutant/ant1compat.xml @@ -23,11 +23,9 @@ - - @@ -37,9 +35,12 @@ + + + diff --git a/proposal/mutant/build.xml b/proposal/mutant/build.xml index f0e03c32b..3fbea496d 100644 --- a/proposal/mutant/build.xml +++ b/proposal/mutant/build.xml @@ -162,7 +162,7 @@ classname="com.puppycrawl.tools.checkstyle.CheckStyleTask"> - + must be supplied"); + throw new ExecutionException("\"name\" attribute of " + + " must be supplied"); } if (value == null) { - throw new ExecutionException("\"value\" attribute of must be supplied"); + throw new ExecutionException("\"value\" attribute of " + + " must be supplied"); } } } @@ -178,9 +185,15 @@ public abstract class AntBase extends AbstractTask { return toId; } + /** + * Validate this data type instance + * + * @exception ExecutionException if the refid attribute has not been set + */ public void validateComponent() throws ExecutionException { if (refId == null) { - throw new ExecutionException("\"refid\" attribute of must be supplied"); + throw new ExecutionException("\"refid\" attribute of " + + " must be supplied"); } } } @@ -188,10 +201,16 @@ public abstract class AntBase extends AbstractTask { /** The name of the target to be evaluated in the sub-build */ private String targetName; - /** flag which indicates if all current properties should be passed to the subbuild */ + /** + * flag which indicates if all current properties should be passed to + * the subbuild + */ private boolean inheritAll = true; - /** flag which indicates if all current references should be passed to the subbuild */ + /** + * flag which indicates if all current references should be passed to + * the subbuild + */ private boolean inheritRefs = false; /** The properties which will be passed to the sub-build */ @@ -203,7 +222,7 @@ public abstract class AntBase extends AbstractTask { /** * Sets the target to be executed in the subbuild * - * @param targetName the name of the target to build + * @param targetName the name of the target to build */ public void setTarget(String targetName) { this.targetName = targetName; @@ -221,7 +240,8 @@ public abstract class AntBase extends AbstractTask { /** * Indicate if all references are to be passed to the subbuild * - * @param inheritRefs true if the sub-build should be given all the current references + * @param inheritRefs true if the sub-build should be given all the + * current references */ public void setInheritRefs(boolean inheritRefs) { this.inheritRefs = inheritRefs; @@ -251,7 +271,8 @@ public abstract class AntBase extends AbstractTask { * Add a reference to be passed * * @param reference the descriptor of the reference to be passed - * @exception ExecutionException if the reference does not reference a valid object + * @exception ExecutionException if the reference does not reference a + * valid object */ public void addReference(Reference reference) throws ExecutionException { String refId = reference.getRefId(); diff --git a/proposal/mutant/src/java/common/org/apache/ant/common/antlib/AbstractComponent.java b/proposal/mutant/src/java/common/org/apache/ant/common/antlib/AbstractComponent.java index ecb390833..7ce50cf3b 100644 --- a/proposal/mutant/src/java/common/org/apache/ant/common/antlib/AbstractComponent.java +++ b/proposal/mutant/src/java/common/org/apache/ant/common/antlib/AbstractComponent.java @@ -80,7 +80,6 @@ public abstract class AbstractComponent implements ExecutionComponent { * Validate the component. This is called after the element has been * configured from its build model. The element may perform validation * of its configuration - * * @exception ExecutionException if validation fails */ @@ -100,9 +99,11 @@ public abstract class AbstractComponent implements ExecutionComponent { /** * Short cut to get a core service instance * - * @param serviceClass the required interface of which an instance is required + * @param serviceClass the required interface of which an instance is + * required * @return the core's instance of the requested service - * @exception ExecutionException if the core does not support the requested service + * @exception ExecutionException if the core does not support the + * requested service */ protected Object getCoreService(Class serviceClass) throws ExecutionException { diff --git a/proposal/mutant/src/java/common/org/apache/ant/common/util/AntException.java b/proposal/mutant/src/java/common/org/apache/ant/common/util/AntException.java index 11964d6bc..b3bb95ba4 100755 --- a/proposal/mutant/src/java/common/org/apache/ant/common/util/AntException.java +++ b/proposal/mutant/src/java/common/org/apache/ant/common/util/AntException.java @@ -146,7 +146,8 @@ public abstract class AntException extends Exception { * Sets the file location where the error occured. * * @param newLocation the new location value - * @param override true if the location should override any currently set location + * @param override true if the location should override any currently + * set location */ public void setLocation(Location newLocation, boolean override) { if (override || location == Location.UNKNOWN_LOCATION) {