maven-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ol...@apache.org
Subject svn commit: r1306858 - in /maven/scm/trunk: maven-scm-api/src/main/java/org/apache/maven/scm/ maven-scm-providers/maven-scm-provider-bazaar/src/main/java/org/apache/maven/scm/provider/bazaar/ maven-scm-providers/maven-scm-provider-hg/src/main/java/org/...
Date Thu, 29 Mar 2012 13:41:29 GMT
Author: olamy
Date: Thu Mar 29 13:41:29 2012
New Revision: 1306858

URL: http://svn.apache.org/viewvc?rev=1306858&view=rev
Log:
use Integer.valueOf rather than new Integer

Modified:
    maven/scm/trunk/maven-scm-api/src/main/java/org/apache/maven/scm/CommandParameters.java
    maven/scm/trunk/maven-scm-providers/maven-scm-provider-bazaar/src/main/java/org/apache/maven/scm/provider/bazaar/BazaarUtils.java
    maven/scm/trunk/maven-scm-providers/maven-scm-provider-hg/src/main/java/org/apache/maven/scm/provider/hg/HgUtils.java

Modified: maven/scm/trunk/maven-scm-api/src/main/java/org/apache/maven/scm/CommandParameters.java
URL: http://svn.apache.org/viewvc/maven/scm/trunk/maven-scm-api/src/main/java/org/apache/maven/scm/CommandParameters.java?rev=1306858&r1=1306857&r2=1306858&view=diff
==============================================================================
--- maven/scm/trunk/maven-scm-api/src/main/java/org/apache/maven/scm/CommandParameters.java
(original)
+++ maven/scm/trunk/maven-scm-api/src/main/java/org/apache/maven/scm/CommandParameters.java
Thu Mar 29 13:41:29 2012
@@ -143,7 +143,7 @@ public class CommandParameters
     public void setInt( CommandParameter parameter, int value )
         throws ScmException
     {
-        setObject( parameter, new Integer( value ) );
+        setObject( parameter, Integer.valueOf( value ) );
     }
 
     // ----------------------------------------------------------------------

Modified: maven/scm/trunk/maven-scm-providers/maven-scm-provider-bazaar/src/main/java/org/apache/maven/scm/provider/bazaar/BazaarUtils.java
URL: http://svn.apache.org/viewvc/maven/scm/trunk/maven-scm-providers/maven-scm-provider-bazaar/src/main/java/org/apache/maven/scm/provider/bazaar/BazaarUtils.java?rev=1306858&r1=1306857&r2=1306858&view=diff
==============================================================================
--- maven/scm/trunk/maven-scm-providers/maven-scm-provider-bazaar/src/main/java/org/apache/maven/scm/provider/bazaar/BazaarUtils.java
(original)
+++ maven/scm/trunk/maven-scm-providers/maven-scm-provider-bazaar/src/main/java/org/apache/maven/scm/provider/bazaar/BazaarUtils.java
Thu Mar 29 13:41:29 2012
@@ -63,7 +63,7 @@ public final class BazaarUtils
     /** Setup exit codes*/
     static
     {
-        DEFAULTEEXITCODES.add( new Integer( 0 ) );
+        DEFAULTEEXITCODES.add( Integer.valueOf( 0 ) );
 
         //Diff is different
         List<Integer> diffExitCodes = new ArrayList<Integer>();
@@ -94,7 +94,7 @@ public final class BazaarUtils
             {
                 exitCodes = EXITCODEMAP.get( cmdAndArgs[0] );
             }
-            boolean success = exitCodes.contains( new Integer( exitCode ) );
+            boolean success = exitCodes.contains( Integer.valueOf( exitCode ) );
 
             //On failure (and not due to exceptions) - run diagnostics
             String providerMsg = "Execution of bazaar command succeded";

Modified: maven/scm/trunk/maven-scm-providers/maven-scm-provider-hg/src/main/java/org/apache/maven/scm/provider/hg/HgUtils.java
URL: http://svn.apache.org/viewvc/maven/scm/trunk/maven-scm-providers/maven-scm-provider-hg/src/main/java/org/apache/maven/scm/provider/hg/HgUtils.java?rev=1306858&r1=1306857&r2=1306858&view=diff
==============================================================================
--- maven/scm/trunk/maven-scm-providers/maven-scm-provider-hg/src/main/java/org/apache/maven/scm/provider/hg/HgUtils.java
(original)
+++ maven/scm/trunk/maven-scm-providers/maven-scm-provider-hg/src/main/java/org/apache/maven/scm/provider/hg/HgUtils.java
Thu Mar 29 13:41:29 2012
@@ -75,8 +75,8 @@ public final class HgUtils
         EXIT_CODE_MAP.put( HgCommandConstants.DIFF_CMD, diffExitCodes );
         //Outgoing is different
         List<Integer> outgoingExitCodes = new ArrayList<Integer>( 2 );
-        outgoingExitCodes.add( new Integer( 0 ) ); //There are changes
-        outgoingExitCodes.add( new Integer( 1 ) ); //No changes
+        outgoingExitCodes.add( Integer.valueOf( 0 ) ); //There are changes
+        outgoingExitCodes.add( Integer.valueOf( 1 ) ); //No changes
         EXIT_CODE_MAP.put( HgCommandConstants.OUTGOING_CMD, outgoingExitCodes );        
     }
 
@@ -101,7 +101,7 @@ public final class HgUtils
             {
                 exitCodes = EXIT_CODE_MAP.get( cmdAndArgs[0] );
             }
-            boolean success = exitCodes.contains( new Integer( exitCode ) );
+            boolean success = exitCodes.contains( Integer.valueOf( exitCode ) );
 
             //On failure (and not due to exceptions) - run diagnostics
             String providerMsg = "Execution of hg command succeded";



Mime
View raw message