Remove redundant casts

This commit is contained in:
Stephen Connolly 2014-01-06 11:23:19 +00:00
parent 5f29be799f
commit 3929f55c31
4 changed files with 4 additions and 4 deletions

View File

@ -98,7 +98,7 @@ public final class ModelUtils
if ( !handleAsInheritance || ( parentInherited == null ) if ( !handleAsInheritance || ( parentInherited == null )
|| Boolean.valueOf( parentInherited ) ) || Boolean.valueOf( parentInherited ) )
{ {
Plugin childPlugin = (Plugin) childPlugins.get( parentPlugin.getKey() ); Plugin childPlugin = childPlugins.get( parentPlugin.getKey() );
if ( ( childPlugin != null ) && !assembledPlugins.contains( childPlugin ) ) if ( ( childPlugin != null ) && !assembledPlugins.contains( childPlugin ) )
{ {

View File

@ -432,7 +432,7 @@ public class ModelUtilsTest
// this block prevents MNG-1703 // this block prevents MNG-1703
assertEquals( 1, child.getDependencies().size() ); assertEquals( 1, child.getDependencies().size() );
Dependency dep2 = (Dependency) child.getDependencies().get( 0 ); Dependency dep2 = child.getDependencies().get( 0 );
assertEquals( dep.getManagementKey(), dep2.getManagementKey() ); assertEquals( dep.getManagementKey(), dep2.getManagementKey() );
} }

View File

@ -104,7 +104,7 @@ public class ProjectSorter
vertices.put( project.getVersion(), dag.addVertex( projectId ) ); vertices.put( project.getVersion(), dag.addVertex( projectId ) );
} }
for ( Vertex projectVertex : (List<Vertex>) dag.getVerticies() ) for ( Vertex projectVertex : dag.getVerticies() )
{ {
String projectId = projectVertex.getLabel(); String projectId = projectVertex.getLabel();

View File

@ -464,7 +464,7 @@ public class MavenCli
ClassRealm coreRealm = cliRequest.classWorld.getClassRealm( "plexus.core" ); ClassRealm coreRealm = cliRequest.classWorld.getClassRealm( "plexus.core" );
if ( coreRealm == null ) if ( coreRealm == null )
{ {
coreRealm = (ClassRealm) cliRequest.classWorld.getRealms().iterator().next(); coreRealm = cliRequest.classWorld.getRealms().iterator().next();
} }
ClassRealm extRealm = cliRequest.classWorld.newRealm( "maven.ext", null ); ClassRealm extRealm = cliRequest.classWorld.newRealm( "maven.ext", null );