mirror of https://github.com/apache/maven.git
parent
a6f113abce
commit
ce35eff448
|
@ -138,7 +138,7 @@ public class ArtifactRepositoryPolicy
|
|||
else if ( updatePolicy.startsWith( UPDATE_POLICY_INTERVAL ) )
|
||||
{
|
||||
String s = updatePolicy.substring( UPDATE_POLICY_INTERVAL.length() + 1 );
|
||||
int minutes = Integer.valueOf( s );
|
||||
int minutes = Integer.parseInt( s );
|
||||
Calendar cal = Calendar.getInstance();
|
||||
cal.add( Calendar.MINUTE, -minutes );
|
||||
if ( cal.getTime().after( lastModified ) )
|
||||
|
@ -212,7 +212,7 @@ public class ArtifactRepositoryPolicy
|
|||
else if ( policy != null && policy.startsWith( ArtifactRepositoryPolicy.UPDATE_POLICY_INTERVAL ) )
|
||||
{
|
||||
String s = policy.substring( UPDATE_POLICY_INTERVAL.length() + 1 );
|
||||
return Integer.valueOf( s );
|
||||
return Integer.parseInt( s );
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
|
@ -76,7 +76,7 @@ public final class ModelUtils
|
|||
|
||||
String inherited = plugin.getInherited();
|
||||
|
||||
if ( ( inherited != null ) && !Boolean.valueOf( inherited ) )
|
||||
if ( ( inherited != null ) && !Boolean.parseBoolean( inherited ) )
|
||||
{
|
||||
it.remove();
|
||||
}
|
||||
|
@ -97,7 +97,7 @@ public final class ModelUtils
|
|||
// 2. the parent's <inherited/> flag is not set
|
||||
// 3. the parent's <inherited/> flag is set to true
|
||||
if ( !handleAsInheritance || ( parentInherited == null )
|
||||
|| Boolean.valueOf( parentInherited ) )
|
||||
|| Boolean.parseBoolean( parentInherited ) )
|
||||
{
|
||||
Plugin childPlugin = childPlugins.get( parentPlugin.getKey() );
|
||||
|
||||
|
@ -217,7 +217,7 @@ public final class ModelUtils
|
|||
// from here to the end of the method is dealing with merging of the <executions/> section.
|
||||
String parentInherited = parent.getInherited();
|
||||
|
||||
boolean parentIsInherited = ( parentInherited == null ) || Boolean.valueOf( parentInherited );
|
||||
boolean parentIsInherited = ( parentInherited == null ) || Boolean.parseBoolean( parentInherited );
|
||||
|
||||
List<PluginExecution> parentExecutions = parent.getExecutions();
|
||||
|
||||
|
@ -234,7 +234,7 @@ public final class ModelUtils
|
|||
String inherited = parentExecution.getInherited();
|
||||
|
||||
boolean parentExecInherited =
|
||||
parentIsInherited && ( ( inherited == null ) || Boolean.valueOf( inherited ) );
|
||||
parentIsInherited && ( ( inherited == null ) || Boolean.parseBoolean( inherited ) );
|
||||
|
||||
if ( !handleAsInheritance || parentExecInherited )
|
||||
{
|
||||
|
|
|
@ -382,7 +382,7 @@ public class DefaultModelInheritanceAssembler
|
|||
{
|
||||
String parentInherited = parentPlugin.getInherited();
|
||||
|
||||
if ( !handleAsInheritance || ( parentInherited == null ) || Boolean.valueOf( parentInherited ) )
|
||||
if ( !handleAsInheritance || ( parentInherited == null ) || Boolean.parseBoolean( parentInherited ) )
|
||||
{
|
||||
|
||||
ReportPlugin assembledPlugin = parentPlugin;
|
||||
|
@ -470,7 +470,7 @@ public class DefaultModelInheritanceAssembler
|
|||
// from here to the end of the method is dealing with merging of the <executions/> section.
|
||||
String parentInherited = parent.getInherited();
|
||||
|
||||
boolean parentIsInherited = ( parentInherited == null ) || Boolean.valueOf( parentInherited );
|
||||
boolean parentIsInherited = ( parentInherited == null ) || Boolean.parseBoolean( parentInherited );
|
||||
|
||||
List<ReportSet> parentReportSets = parent.getReportSets();
|
||||
|
||||
|
|
|
@ -96,7 +96,7 @@ public final class CLIReportingUtils
|
|||
msg += ( rev != null ? rev : "" );
|
||||
if ( StringUtils.isNotBlank( timestamp ) )
|
||||
{
|
||||
String ts = formatTimestamp( Long.valueOf( timestamp ) );
|
||||
String ts = formatTimestamp( Long.parseLong( timestamp ) );
|
||||
msg += ( rev != null ? "; " : "" ) + ts;
|
||||
}
|
||||
msg += ")";
|
||||
|
|
|
@ -1613,7 +1613,7 @@ public class MavenCli
|
|||
}
|
||||
else
|
||||
{
|
||||
request.setDegreeOfConcurrency( Integer.valueOf( threadConfiguration ) );
|
||||
request.setDegreeOfConcurrency( Integer.parseInt( threadConfiguration ) );
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1631,7 +1631,7 @@ public class MavenCli
|
|||
int calculateDegreeOfConcurrencyWithCoreMultiplier( String threadConfiguration )
|
||||
{
|
||||
int procs = Runtime.getRuntime().availableProcessors();
|
||||
return (int) ( Float.valueOf( threadConfiguration.replace( "C", "" ) ) * procs );
|
||||
return (int) ( Float.parseFloat( threadConfiguration.replace( "C", "" ) ) * procs );
|
||||
}
|
||||
|
||||
// ----------------------------------------------------------------------
|
||||
|
|
Loading…
Reference in New Issue