Author: hboutemy Date: Fri May 1 17:29:39 2009 New Revision: 770766 URL: http://svn.apache.org/viewvc?rev=770766&view=rev Log: restored JDK 1.4 compatibility (Boolean.parseBoolean() Java5 only)
Modified: maven/ant-tasks/branches/maven-ant-tasks-2.0.x/src/main/java/org/apache/maven/artifact/ant/Pom.java Modified: maven/ant-tasks/branches/maven-ant-tasks-2.0.x/src/main/java/org/apache/maven/artifact/ant/Pom.java URL: http://svn.apache.org/viewvc/maven/ant-tasks/branches/maven-ant-tasks-2.0.x/src/main/java/org/apache/maven/artifact/ant/Pom.java?rev=770766&r1=770765&r2=770766&view=diff ============================================================================== --- maven/ant-tasks/branches/maven-ant-tasks-2.0.x/src/main/java/org/apache/maven/artifact/ant/Pom.java (original) +++ maven/ant-tasks/branches/maven-ant-tasks-2.0.x/src/main/java/org/apache/maven/artifact/ant/Pom.java Fri May 1 17:29:39 2009 @@ -60,12 +60,12 @@ /** * A POM typedef. - * + * * Also an Ant Task that registers a handler called POMPropertyHelper that intercepts all calls to property value * resolution and replies instead of Ant to properties that start with the id of the pom. - * + * * Example: ${maven.project.artifactId} - * + * * @author <a href="mailto:br...@apache.org">Brett Porter</a> * @author <a href="mailto:nicola...@apache.org">Nicola Ken Barozzi</a> * @version $Id$ @@ -79,7 +79,7 @@ private MavenProject mavenProject; private File file; - + private List profiles = new ArrayList(); /** @@ -130,12 +130,12 @@ { this.file = file; } - + public List getProfiles() { return profiles; } - + public void addProfile(Profile activeProfile) { this.profiles.add(activeProfile); @@ -180,7 +180,7 @@ try { - + mavenProject = builder.build( file, localRepository, getActivatedProfiles() ); } catch ( ProjectBuildingException e ) @@ -467,13 +467,13 @@ while ( it.hasNext() ) { Profile profile = (Profile) it.next(); - + if ( profile.getId() == null ) { throw new BuildException( "Attribute \"id\" is required for profile in pom type." ); } - - if ( profile.getActive() == null || Boolean.parseBoolean( profile.getActive() ) ) + + if ( profile.getActive() == null || Boolean.valueOf( profile.getActive() ).booleanValue() ) { profileManager.explicitlyActivate( profile.getId() ); }