CPD Results

The following document contains the results of PMD's CPD 5.0.2.

Duplications

FileLine
org/jdtaus/core/container/mojo/AbstractContainerMojo.java481
org/jdtaus/core/container/mojo/AbstractContainerMojo.java524
            getCompileSourceRoots().iterator(); it.hasNext(); )
        {
            sourceRoot = (String) it.next();
            parentRoot = new File( sourceRoot );

            if ( !parentRoot.exists() || !parentRoot.isDirectory() )
            {
                continue;
            }

            scanner = new DirectoryScanner();
            scanner.setBasedir( sourceRoot );
            scanner.setIncludes( DEFAULT_SOURCE_INCLUDES );
            scanner.addDefaultExcludes();
            scanner.scan();

            for ( final Iterator it2 =
                Arrays.asList( scanner.getIncludedFiles() ).iterator();
                  it2.hasNext(); )
            {
                file = new File( parentRoot, (String) it2.next() );
                files.add( file );
            }
        }

        return files;
    }

    /**
     * Gets all source files from the project's test compile source roots.
     *
     * @return a {@code Collection} holding {@code File} instances for all
     * source files found in all test compile source roots.
     */
    protected final Collection getTestSources()
FileLine
org/jdtaus/core/container/mojo/ContainerReport.java1201
org/jdtaus/core/container/mojo/VerifyModelMojo.java381
        final Collection deps = new LinkedList();

        for ( int m = model.getModules().size() - 1; m >= 0; m-- )
        {
            final Module mod = model.getModules().getModule( m );

            for ( int i = mod.getImplementations().size() - 1; i >= 0; i-- )
            {
                final Implementation impl = mod.getImplementations().
                    getImplementation( i );

                for ( int d = impl.getDependencies().size() - 1; d >= 0; d-- )
                {
FileLine
org/jdtaus/core/container/mojo/JavaContainerMojo.java353
org/jdtaus/core/container/mojo/JavaContainerTestsMojo.java94
                                                mod.getName() ) );

            }
        }
        catch ( final ContextError e )
        {
            throw new MojoExecutionException( e.getMessage(), e );
        }
        catch ( final ContainerError e )
        {
            throw new MojoExecutionException( e.getMessage(), e );
        }
        catch ( final ModelError e )
        {
            throw new MojoExecutionException( e.getMessage(), e );
        }
        catch ( final Exception e )
        {
            throw new MojoExecutionException( e.getMessage(), e );
        }
        finally
        {
            disableThreadContextClassLoader();
            Thread.currentThread().setContextClassLoader( mavenLoader );
        }
    }
FileLine
org/jdtaus/core/container/mojo/JavaCommitMojo.java104
org/jdtaus/core/container/mojo/JavaCommitTestsMojo.java75
                        getBuild().getOutputDirectory() ) );

                }
            }
        }
        catch ( final ContextError e )
        {
            throw new MojoExecutionException( e.getMessage(), e );
        }
        catch ( final ContainerError e )
        {
            throw new MojoExecutionException( e.getMessage(), e );
        }
        catch ( final ModelError e )
        {
            throw new MojoExecutionException( e.getMessage(), e );
        }
        catch ( final Exception e )
        {
            throw new MojoExecutionException( e.getMessage(), e );
        }
        finally
        {
            disableThreadContextClassLoader();
            Thread.currentThread().setContextClassLoader( mavenLoader );
        }

    }
FileLine
org/jdtaus/core/container/mojo/JavaContainerMojo.java353
org/jdtaus/core/container/mojo/JavaContainerTestsMojo.java94
org/jdtaus/core/container/mojo/VerifyModelMojo.java121
                                                mod.getName() ) );

            }
        }
        catch ( final ContextError e )
        {
            throw new MojoExecutionException( e.getMessage(), e );
        }
        catch ( final ContainerError e )
        {
            throw new MojoExecutionException( e.getMessage(), e );
        }
        catch ( final ModelError e )
        {
            throw new MojoExecutionException( e.getMessage(), e );
        }
        catch ( final Exception e )
        {
            throw new MojoExecutionException( e.getMessage(), e );
        }
        finally
        {
            disableThreadContextClassLoader();
            Thread.currentThread().setContextClassLoader( mavenLoader );
        }
    }
FileLine
org/jdtaus/core/container/mojo/JavaContainerMojo.java353
org/jdtaus/core/container/mojo/JavaContainerTestsMojo.java94
org/jdtaus/core/container/mojo/SpringDescriptorMojo.java224
org/jdtaus/core/container/mojo/VerifyModelMojo.java121
                                                mod.getName() ) );

            }
        }
        catch ( final ContextError e )
        {
            throw new MojoExecutionException( e.getMessage(), e );
        }
        catch ( final ContainerError e )
        {
            throw new MojoExecutionException( e.getMessage(), e );
        }
        catch ( final ModelError e )
        {
            throw new MojoExecutionException( e.getMessage(), e );
        }
        catch ( final Exception e )
        {
            throw new MojoExecutionException( e.getMessage(), e );
        }
        finally
        {
            disableThreadContextClassLoader();
            Thread.currentThread().setContextClassLoader( mavenLoader );
FileLine
org/jdtaus/core/container/mojo/JavaCommitMojo.java107
org/jdtaus/core/container/mojo/VerifyModelMojo.java123
            }
        }
        catch ( final ContextError e )
        {
            throw new MojoExecutionException( e.getMessage(), e );
        }
        catch ( final ContainerError e )
        {
            throw new MojoExecutionException( e.getMessage(), e );
        }
        catch ( final ModelError e )
        {
            throw new MojoExecutionException( e.getMessage(), e );
        }
        catch ( final Exception e )
        {
            throw new MojoExecutionException( e.getMessage(), e );
        }
        finally
        {
            disableThreadContextClassLoader();
            Thread.currentThread().setContextClassLoader( mavenLoader );
        }

    }

    protected void commitImplementation( final Model model,
FileLine
org/jdtaus/core/container/mojo/JavaCommitTestsMojo.java78
org/jdtaus/core/container/mojo/JavaContainerTestsMojo.java96
            }
        }
        catch ( final ContextError e )
        {
            throw new MojoExecutionException( e.getMessage(), e );
        }
        catch ( final ContainerError e )
        {
            throw new MojoExecutionException( e.getMessage(), e );
        }
        catch ( final ModelError e )
        {
            throw new MojoExecutionException( e.getMessage(), e );
        }
        catch ( final Exception e )
        {
            throw new MojoExecutionException( e.getMessage(), e );
        }
        finally
        {
            disableThreadContextClassLoader();
            Thread.currentThread().setContextClassLoader( mavenLoader );
        }
    }

}