You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by br...@apache.org on 2005/06/21 07:42:35 UTC

svn commit: r191627 - in /maven/components/trunk/maven-profile: ./ src/main/java/org/apache/maven/profiles/ src/main/resources/META-INF/plexus/

Author: brett
Date: Mon Jun 20 22:42:35 2005
New Revision: 191627

URL: http://svn.apache.org/viewcvs?rev=191627&view=rev
Log:
reformat and optimize imports

Modified:
    maven/components/trunk/maven-profile/profiles.mdo
    maven/components/trunk/maven-profile/src/main/java/org/apache/maven/profiles/DefaultMavenProfilesBuilder.java
    maven/components/trunk/maven-profile/src/main/java/org/apache/maven/profiles/MavenProfilesBuilder.java
    maven/components/trunk/maven-profile/src/main/java/org/apache/maven/profiles/ProfilesConversionUtils.java
    maven/components/trunk/maven-profile/src/main/resources/META-INF/plexus/components.xml

Modified: maven/components/trunk/maven-profile/profiles.mdo
URL: http://svn.apache.org/viewcvs/maven/components/trunk/maven-profile/profiles.mdo?rev=191627&r1=191626&r2=191627&view=diff
==============================================================================
--- maven/components/trunk/maven-profile/profiles.mdo (original)
+++ maven/components/trunk/maven-profile/profiles.mdo Mon Jun 20 22:42:35 2005
@@ -56,13 +56,13 @@
           <required>true</required>
           <version>1.0.0</version>
           <type>String</type>
-          <description>The ID of this build profile, for activation 
+          <description>The ID of this build profile, for activation
             purposes.</description>
         </field>
         <field>
           <name>activation</name>
           <version>1.0.0</version>
-          <description><![CDATA[The conditional logic which will automatically 
+          <description><![CDATA[The conditional logic which will automatically
             trigger the inclusion of this profile.]]></description>
           <association>
             <type>Activation</type>
@@ -70,7 +70,7 @@
         </field>
         <field>
           <name>properties</name>
-          <description>Extended configuration specific to this profile goes 
+          <description>Extended configuration specific to this profile goes
             here.</description>
           <type>Properties</type>
           <association xml.mapStyle="inline">
@@ -82,7 +82,7 @@
           <name>repositories</name>
           <version>1.0.0</version>
           <description><![CDATA[The lists of the remote repositories]]>
-            </description>
+          </description>
           <association>
             <type>Repository</type>
             <multiplicity>*</multiplicity>
@@ -98,8 +98,8 @@
             <type>Repository</type>
             <multiplicity>*</multiplicity>
           </association>
-          <comment><![CDATA[ This may be removed or relocated in the near 
-            future. It is undecided whether plugins really need a remote 
+          <comment><![CDATA[ This may be removed or relocated in the near
+            future. It is undecided whether plugins really need a remote
             repository set of their own. ]]></comment>
         </field>
       </fields>
@@ -108,7 +108,7 @@
       <name>Activation</name>
       <version>1.0.0</version>
       <description><![CDATA[
-        The conditions within the build runtime environment which will trigger 
+        The conditions within the build runtime environment which will trigger
         the automatic inclusion of the parent build profile.
       ]]></description>
       <fields>
@@ -167,16 +167,16 @@
         <field>
           <name>snapshotPolicy</name>
           <version>1.0.0</version>
-          <description> The policy for downloading snapshots - can be "always", 
-            "daily" (default), "interval:XXX" (in minutes) or "never". 
-            </description>
+          <description>The policy for downloading snapshots - can be "always",
+            "daily" (default), "interval:XXX" (in minutes) or "never".
+          </description>
           <type>String</type>
           <defaultValue>daily</defaultValue>
         </field>
         <field>
           <name>layout</name>
           <version>1.0.0</version>
-          <description>The type of layout this repository uses for locating and 
+          <description>The type of layout this repository uses for locating and
             storing artifacts - can be "legacy" or "default".</description>
           <type>String</type>
           <defaultValue>default</defaultValue>
@@ -184,7 +184,8 @@
         <field>
           <name>checksumPolicy</name>
           <version>1.0.0</version>
-          <description>What to do when verification of an artifact checksum fails - warn, fail, etc. Valid values are "fail" or "warn"</description>
+          <description>What to do when verification of an artifact checksum fails - warn, fail, etc. Valid values are
+            "fail" or "warn"</description>
           <type>String</type>
           <defaultValue>warn</defaultValue>
         </field>

Modified: maven/components/trunk/maven-profile/src/main/java/org/apache/maven/profiles/DefaultMavenProfilesBuilder.java
URL: http://svn.apache.org/viewcvs/maven/components/trunk/maven-profile/src/main/java/org/apache/maven/profiles/DefaultMavenProfilesBuilder.java?rev=191627&r1=191626&r2=191627&view=diff
==============================================================================
--- maven/components/trunk/maven-profile/src/main/java/org/apache/maven/profiles/DefaultMavenProfilesBuilder.java (original)
+++ maven/components/trunk/maven-profile/src/main/java/org/apache/maven/profiles/DefaultMavenProfilesBuilder.java Mon Jun 20 22:42:35 2005
@@ -27,24 +27,23 @@
 public class DefaultMavenProfilesBuilder
     implements MavenProfilesBuilder
 {
-    
     private static final String PROFILES_XML_FILE = "profiles.xml";
 
     public ProfilesRoot buildProfiles( File basedir )
         throws IOException, XmlPullParserException
     {
         File profilesXml = new File( basedir, PROFILES_XML_FILE );
-        
+
         ProfilesRoot profilesRoot = null;
-        
-        if( profilesXml.exists() )
+
+        if ( profilesXml.exists() )
         {
             ProfilesXpp3Reader reader = new ProfilesXpp3Reader();
             FileReader fileReader = null;
             try
             {
                 fileReader = new FileReader( profilesXml );
-                
+
                 profilesRoot = reader.read( fileReader );
             }
             finally
@@ -52,7 +51,7 @@
                 IOUtil.close( fileReader );
             }
         }
-        
+
         return profilesRoot;
     }
 

Modified: maven/components/trunk/maven-profile/src/main/java/org/apache/maven/profiles/MavenProfilesBuilder.java
URL: http://svn.apache.org/viewcvs/maven/components/trunk/maven-profile/src/main/java/org/apache/maven/profiles/MavenProfilesBuilder.java?rev=191627&r1=191626&r2=191627&view=diff
==============================================================================
--- maven/components/trunk/maven-profile/src/main/java/org/apache/maven/profiles/MavenProfilesBuilder.java (original)
+++ maven/components/trunk/maven-profile/src/main/java/org/apache/maven/profiles/MavenProfilesBuilder.java Mon Jun 20 22:42:35 2005
@@ -16,7 +16,6 @@
  * limitations under the License.
  */
 
-import org.apache.maven.profiles.ProfilesRoot;
 import org.codehaus.plexus.util.xml.pull.XmlPullParserException;
 
 import java.io.File;

Modified: maven/components/trunk/maven-profile/src/main/java/org/apache/maven/profiles/ProfilesConversionUtils.java
URL: http://svn.apache.org/viewcvs/maven/components/trunk/maven-profile/src/main/java/org/apache/maven/profiles/ProfilesConversionUtils.java?rev=191627&r1=191626&r2=191627&view=diff
==============================================================================
--- maven/components/trunk/maven-profile/src/main/java/org/apache/maven/profiles/ProfilesConversionUtils.java (original)
+++ maven/components/trunk/maven-profile/src/main/java/org/apache/maven/profiles/ProfilesConversionUtils.java Mon Jun 20 22:42:35 2005
@@ -1,14 +1,5 @@
 package org.apache.maven.profiles;
 
-import org.apache.maven.model.Activation;
-import org.apache.maven.model.ActivationProperty;
-import org.apache.maven.model.Profile;
-import org.apache.maven.model.Repository;
-import org.apache.maven.profiles.AlwaysOnActivation;
-
-import java.util.Iterator;
-import java.util.List;
-
 /*
  * Copyright 2001-2005 The Apache Software Foundation.
  *
@@ -25,9 +16,16 @@
  * limitations under the License.
  */
 
+import org.apache.maven.model.Activation;
+import org.apache.maven.model.ActivationProperty;
+import org.apache.maven.model.Profile;
+import org.apache.maven.model.Repository;
+
+import java.util.Iterator;
+import java.util.List;
+
 public class ProfilesConversionUtils
 {
-    
     private ProfilesConversionUtils()
     {
     }
@@ -35,9 +33,9 @@
     public static Profile convertFromProfileXmlProfile( org.apache.maven.profiles.Profile profileXmlProfile )
     {
         Profile profile = new Profile();
-        
+
         profile.setId( profileXmlProfile.getId() );
-        
+
         profile.setSource( "profiles.xml" );
 
         org.apache.maven.profiles.Activation profileActivation = profileXmlProfile.getActivation();
@@ -59,14 +57,14 @@
 
                 activation.setProperty( prop );
             }
-            
+
             profile.setActivation( activation );
         }
         else
         {
             profile.setActivation( new AlwaysOnActivation() );
         }
-        
+
         profile.setProperties( profileXmlProfile.getProperties() );
 
         List repos = profileXmlProfile.getRepositories();
@@ -75,7 +73,8 @@
             for ( Iterator it = repos.iterator(); it.hasNext(); )
             {
                 profile
-                    .addRepository( convertFromProfileXmlRepository( (org.apache.maven.profiles.Repository) it.next() ) );
+                    .addRepository(
+                        convertFromProfileXmlRepository( (org.apache.maven.profiles.Repository) it.next() ) );
             }
         }
 

Modified: maven/components/trunk/maven-profile/src/main/resources/META-INF/plexus/components.xml
URL: http://svn.apache.org/viewcvs/maven/components/trunk/maven-profile/src/main/resources/META-INF/plexus/components.xml?rev=191627&r1=191626&r2=191627&view=diff
==============================================================================
--- maven/components/trunk/maven-profile/src/main/resources/META-INF/plexus/components.xml (original)
+++ maven/components/trunk/maven-profile/src/main/resources/META-INF/plexus/components.xml Mon Jun 20 22:42:35 2005
@@ -1,6 +1,6 @@
 <component-set>
   <components>
-    <!--
+<!--
      |
      |
      |



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