Return-Path: X-Original-To: apmail-creadur-commits-archive@www.apache.org Delivered-To: apmail-creadur-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 287AA10FBC for ; Sun, 8 Dec 2013 19:50:35 +0000 (UTC) Received: (qmail 40623 invoked by uid 500); 8 Dec 2013 19:50:35 -0000 Delivered-To: apmail-creadur-commits-archive@creadur.apache.org Received: (qmail 40598 invoked by uid 500); 8 Dec 2013 19:50:35 -0000 Mailing-List: contact commits-help@creadur.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@creadur.apache.org Delivered-To: mailing list commits@creadur.apache.org Received: (qmail 40591 invoked by uid 99); 8 Dec 2013 19:50:35 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 08 Dec 2013 19:50:35 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 08 Dec 2013 19:50:30 +0000 Received: from eris.apache.org (localhost [127.0.0.1]) by eris.apache.org (Postfix) with ESMTP id 170262388868; Sun, 8 Dec 2013 19:50:08 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r1549163 - in /creadur/rat/branches/gsoc/apache-rat-core/src: main/java/org/apache/rat/analysis/ main/java/org/apache/rat/document/impl/util/ main/java/org/apache/rat/policy/ main/java/org/apache/rat/report/claim/util/ main/java/org/apache/... Date: Sun, 08 Dec 2013 19:50:07 -0000 To: commits@creadur.apache.org From: rdonkin@apache.org X-Mailer: svnmailer-1.0.9 Message-Id: <20131208195008.170262388868@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Author: rdonkin Date: Sun Dec 8 19:50:07 2013 New Revision: 1549163 URL: http://svn.apache.org/r1549163 Log: Moving towards a more simple and direct implementation of the pipeline. Added: creadur/rat/branches/gsoc/apache-rat-core/src/main/java/org/apache/rat/report/claim/util/Pipeline.java - copied, changed from r1549162, creadur/rat/branches/gsoc/apache-rat-core/src/main/java/org/apache/rat/report/claim/util/ClaimReporterMultiplexer.java Removed: creadur/rat/branches/gsoc/apache-rat-core/src/main/java/org/apache/rat/document/impl/util/DocumentAnalyserMultiplexer.java creadur/rat/branches/gsoc/apache-rat-core/src/main/java/org/apache/rat/report/claim/util/ClaimReporterMultiplexer.java creadur/rat/branches/gsoc/apache-rat-core/src/test/java/org/apache/rat/document/impl/util/DocumentAnalyserMultiplexerTest.java Modified: creadur/rat/branches/gsoc/apache-rat-core/src/main/java/org/apache/rat/analysis/DefaultAnalyser.java creadur/rat/branches/gsoc/apache-rat-core/src/main/java/org/apache/rat/policy/DefaultPolicy.java creadur/rat/branches/gsoc/apache-rat-core/src/main/java/org/apache/rat/report/xml/XmlReportFactory.java creadur/rat/branches/gsoc/apache-rat-core/src/test/java/org/apache/rat/analysis/AnalyserFactoryTest.java creadur/rat/branches/gsoc/apache-rat-core/src/test/java/org/apache/rat/report/xml/XmlReportTest.java Modified: creadur/rat/branches/gsoc/apache-rat-core/src/main/java/org/apache/rat/analysis/DefaultAnalyser.java URL: http://svn.apache.org/viewvc/creadur/rat/branches/gsoc/apache-rat-core/src/main/java/org/apache/rat/analysis/DefaultAnalyser.java?rev=1549163&r1=1549162&r2=1549163&view=diff ============================================================================== --- creadur/rat/branches/gsoc/apache-rat-core/src/main/java/org/apache/rat/analysis/DefaultAnalyser.java (original) +++ creadur/rat/branches/gsoc/apache-rat-core/src/main/java/org/apache/rat/analysis/DefaultAnalyser.java Sun Dec 8 19:50:07 2013 @@ -22,7 +22,6 @@ import java.io.IOException; import org.apache.rat.api.Document; import org.apache.rat.api.MetaData; -import org.apache.rat.document.IDocumentAnalyser; import org.apache.rat.document.impl.guesser.ArchiveGuesser; import org.apache.rat.document.impl.guesser.BinaryGuesser; import org.apache.rat.document.impl.guesser.NoteGuesser; @@ -30,7 +29,7 @@ import org.apache.rat.document.impl.gues /** * The Class DefaultAnalyser. */ -public final class DefaultAnalyser implements IDocumentAnalyser { +public final class DefaultAnalyser { /** The matcher. */ private final IHeaderMatcher matcher; Modified: creadur/rat/branches/gsoc/apache-rat-core/src/main/java/org/apache/rat/policy/DefaultPolicy.java URL: http://svn.apache.org/viewvc/creadur/rat/branches/gsoc/apache-rat-core/src/main/java/org/apache/rat/policy/DefaultPolicy.java?rev=1549163&r1=1549162&r2=1549163&view=diff ============================================================================== --- creadur/rat/branches/gsoc/apache-rat-core/src/main/java/org/apache/rat/policy/DefaultPolicy.java (original) +++ creadur/rat/branches/gsoc/apache-rat-core/src/main/java/org/apache/rat/policy/DefaultPolicy.java Sun Dec 8 19:50:07 2013 @@ -18,7 +18,6 @@ */ package org.apache.rat.policy; - import static org.apache.rat.api.domain.RatLicenseFamily.APACHE; import static org.apache.rat.api.domain.RatLicenseFamily.CDDL1; import static org.apache.rat.api.domain.RatLicenseFamily.MIT; @@ -32,22 +31,20 @@ import java.util.Arrays; import org.apache.rat.api.Document; import org.apache.rat.api.MetaData; import org.apache.rat.api.MetaData.Datum; -import org.apache.rat.document.IDocumentAnalyser; import org.apache.rat.license.ILicenseFamily; -public class DefaultPolicy implements IDocumentAnalyser { - private static final String[] APPROVED_LICENSES = { APACHE.getName(), - OASIS.getName(), - W3C.getName(), W3C_DOCUMENTATION.getName(), - TMF854.getName(), - MIT.getName(), CDDL1.getName(), }; +public class DefaultPolicy { + private static final String[] APPROVED_LICENSES = { APACHE.getName(), + OASIS.getName(), W3C.getName(), W3C_DOCUMENTATION.getName(), + TMF854.getName(), MIT.getName(), CDDL1.getName(), }; - private static final String[] toNames(final ILicenseFamily[] approvedLicenses) { + private static final String[] toNames( + final ILicenseFamily[] approvedLicenses) { String[] results = null; if (approvedLicenses != null) { final int length = approvedLicenses.length; results = new String[length]; - for (int i=0;i= 0; + final boolean isApproved = Arrays.binarySearch( + approvedLicenseNames, name) >= 0; reportLicenseApprovalClaim(subject, isApproved); } } Copied: creadur/rat/branches/gsoc/apache-rat-core/src/main/java/org/apache/rat/report/claim/util/Pipeline.java (from r1549162, creadur/rat/branches/gsoc/apache-rat-core/src/main/java/org/apache/rat/report/claim/util/ClaimReporterMultiplexer.java) URL: http://svn.apache.org/viewvc/creadur/rat/branches/gsoc/apache-rat-core/src/main/java/org/apache/rat/report/claim/util/Pipeline.java?p2=creadur/rat/branches/gsoc/apache-rat-core/src/main/java/org/apache/rat/report/claim/util/Pipeline.java&p1=creadur/rat/branches/gsoc/apache-rat-core/src/main/java/org/apache/rat/report/claim/util/ClaimReporterMultiplexer.java&r1=1549162&r2=1549163&rev=1549163&view=diff ============================================================================== --- creadur/rat/branches/gsoc/apache-rat-core/src/main/java/org/apache/rat/report/claim/util/ClaimReporterMultiplexer.java (original) +++ creadur/rat/branches/gsoc/apache-rat-core/src/main/java/org/apache/rat/report/claim/util/Pipeline.java Sun Dec 8 19:50:07 2013 @@ -15,48 +15,59 @@ * KIND, either express or implied. See the License for the * * specific language governing permissions and limitations * * under the License. * - */ + */ package org.apache.rat.report.claim.util; +import java.io.IOException; +import java.util.List; + +import org.apache.rat.analysis.DefaultAnalyser; import org.apache.rat.api.Document; import org.apache.rat.api.RatException; -import org.apache.rat.document.IDocumentAnalyser; +import org.apache.rat.policy.DefaultPolicy; import org.apache.rat.report.RatReport; -import java.util.List; +public class Pipeline implements RatReport { - -public class ClaimReporterMultiplexer implements RatReport { - private final IDocumentAnalyser analyser; + private final DefaultAnalyser analyser; + private final DefaultPolicy policy; private final List reporters; - public ClaimReporterMultiplexer(final IDocumentAnalyser pAnalyser, final List reporters) { - analyser = pAnalyser; + public Pipeline(final DefaultAnalyser analyser, final DefaultPolicy policy, + final List reporters) { + super(); + this.analyser = analyser; + this.policy = policy; this.reporters = reporters; } - public void report(Document document) throws RatException { - if (analyser != null) { + public void report(final Document document) throws RatException { + if (this.analyser != null) { try { - analyser.analyse(document); - } catch (Exception e) { + this.analyser.analyse(document); + } catch (final IOException e) { throw new RatException(e.getMessage(), e); } } - for (RatReport report : reporters) { + + if (this.policy != null) { + this.policy.analyse(document); + } + + for (final RatReport report : this.reporters) { report.report(document); - } + } } public void startReport() throws RatException { - for (RatReport report : reporters) { + for (final RatReport report : this.reporters) { report.startReport(); - } + } } public void endReport() throws RatException { - for (RatReport report : reporters) { + for (final RatReport report : this.reporters) { report.endReport(); - } + } } } Modified: creadur/rat/branches/gsoc/apache-rat-core/src/main/java/org/apache/rat/report/xml/XmlReportFactory.java URL: http://svn.apache.org/viewvc/creadur/rat/branches/gsoc/apache-rat-core/src/main/java/org/apache/rat/report/xml/XmlReportFactory.java?rev=1549163&r1=1549162&r2=1549163&view=diff ============================================================================== --- creadur/rat/branches/gsoc/apache-rat-core/src/main/java/org/apache/rat/report/xml/XmlReportFactory.java (original) +++ creadur/rat/branches/gsoc/apache-rat-core/src/main/java/org/apache/rat/report/xml/XmlReportFactory.java Sun Dec 8 19:50:07 2013 @@ -23,15 +23,13 @@ import java.util.List; import org.apache.rat.ReportConfiguration; import org.apache.rat.analysis.DefaultAnalyser; -import org.apache.rat.document.IDocumentAnalyser; -import org.apache.rat.document.impl.util.DocumentAnalyserMultiplexer; import org.apache.rat.policy.DefaultPolicy; import org.apache.rat.report.RatReport; import org.apache.rat.report.claim.ClaimStatistic; import org.apache.rat.report.claim.impl.ClaimAggregator; import org.apache.rat.report.claim.impl.xml.SimpleXmlClaimReporter; -import org.apache.rat.report.claim.util.ClaimReporterMultiplexer; import org.apache.rat.report.claim.util.LicenseAddingReport; +import org.apache.rat.report.claim.util.Pipeline; import org.apache.rat.report.xml.writer.IXmlWriter; /** @@ -52,13 +50,10 @@ public class XmlReportFactory { .isAddingLicensesForced())); } reporters.add(new SimpleXmlClaimReporter(writer)); - final IDocumentAnalyser analyser = + final DefaultAnalyser analyser = new DefaultAnalyser(pConfiguration.getHeaderMatcher()); final DefaultPolicy policy = new DefaultPolicy(pConfiguration.getApprovedLicenseNames()); - final IDocumentAnalyser[] analysers = { analyser, policy }; - final DocumentAnalyserMultiplexer analysisMultiplexer = - new DocumentAnalyserMultiplexer(analysers); - return new ClaimReporterMultiplexer(analysisMultiplexer, reporters); + return new Pipeline(analyser, policy, reporters); } } Modified: creadur/rat/branches/gsoc/apache-rat-core/src/test/java/org/apache/rat/analysis/AnalyserFactoryTest.java URL: http://svn.apache.org/viewvc/creadur/rat/branches/gsoc/apache-rat-core/src/test/java/org/apache/rat/analysis/AnalyserFactoryTest.java?rev=1549163&r1=1549162&r2=1549163&view=diff ============================================================================== --- creadur/rat/branches/gsoc/apache-rat-core/src/test/java/org/apache/rat/analysis/AnalyserFactoryTest.java (original) +++ creadur/rat/branches/gsoc/apache-rat-core/src/test/java/org/apache/rat/analysis/AnalyserFactoryTest.java Sun Dec 8 19:50:07 2013 @@ -26,7 +26,6 @@ import java.io.StringWriter; import org.apache.rat.api.Document; import org.apache.rat.api.RatException; -import org.apache.rat.document.IDocumentAnalyser; import org.apache.rat.document.impl.MonolithicFileDocument; import org.apache.rat.report.claim.impl.xml.SimpleXmlClaimReporter; import org.apache.rat.report.xml.writer.impl.base.XmlWriter; @@ -39,181 +38,189 @@ import org.junit.Test; */ public class AnalyserFactoryTest { - /** The out. */ - private StringWriter out; + /** The out. */ + private StringWriter out; - /** The reporter. */ - private SimpleXmlClaimReporter reporter; + /** The reporter. */ + private SimpleXmlClaimReporter reporter; - /** The matcher stub. */ - private IHeaderMatcher matcherStub; + /** The matcher stub. */ + private IHeaderMatcher matcherStub; - /** - * Sets the up. - * - * @throws Exception - * the exception - */ - @Before - public void setUp() throws Exception { - out = new StringWriter(); - XmlWriter writer = new XmlWriter(out); - reporter = new SimpleXmlClaimReporter(writer); - matcherStub = new IHeaderMatcher() { - public boolean match(final Document subject, final String line) { - return false; - } - public void reset() { - } - }; - } - - /** - * Standard type analyser. - * - * @throws IOException - * Signals that an I/O exception has occurred. - * @throws RatException - * the rat exception - */ - @Test - public void testStandardTypeAnalyser() throws IOException, RatException { - MonolithicFileDocument document = new MonolithicFileDocument(new File( - "src/test/resources/elements/Text.txt")); - IDocumentAnalyser analyser = new DefaultAnalyser(matcherStub); - analyser.analyse(document); - reporter.report(document); - assertEquals( - "Open standard element", - "/*\n" - + " * Licensed to the Apache Software Foundation (ASF) under one\n" - + " * or more contributor license agreements. See the NOTICE file\n" - + " * distributed with this work for additional information\n" - + " * regarding copyright ownership. The ASF licenses this file\n" - + " * to you under the Apache License, Version 2.0 (the \"License\");\n" - + " * you may not use this file except in compliance with the License.\n" - + " * You may obtain a copy of the License at\n" - + " *\n" - + " * http://www.apache.org/licenses/LICENSE-2.0\n" - + " *\n" - + " * Unless required by applicable law or agreed to in writing,\n" - + " * software distributed under the License is distributed on an\n" - + " * \"AS IS\" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\n" - + " * KIND, either express or implied. See the License for the\n" - + " * specific language governing permissions and limitations\n" - + " * under the License. \n" - + " */\n" - + "\n" - + " \n" - + "", - out.toString()); - } - - /** - * Note type analyser. - * - * @throws IOException - * Signals that an I/O exception has occurred. - * @throws RatException - * the rat exception - */ - @Test - public void testNoteTypeAnalyser() throws IOException, RatException { - MonolithicFileDocument document = new MonolithicFileDocument(new File( - "src/test/elements/LICENSE")); - IDocumentAnalyser analyser = new DefaultAnalyser(matcherStub); - analyser.analyse(document); - reporter.report(document); - assertEquals( - "Open note element", - "", - out.toString()); - } - - /** - * Binary type analyser. - * - * @throws IOException - * Signals that an I/O exception has occurred. - * @throws RatException - * the rat exception - */ - @Test - public void testBinaryTypeAnalyser() throws IOException, RatException { - MonolithicFileDocument document = new MonolithicFileDocument(new File( - "src/test/elements/Image.png")); - IDocumentAnalyser analyser = new DefaultAnalyser(matcherStub); - analyser.analyse(document); - reporter.report(document); - assertEquals( - "Open binary element", - "", - out.toString()); - } - - /** - * Archive type analyser. - * - * @throws IOException - * Signals that an I/O exception has occurred. - * @throws RatException - * the rat exception - */ - @Test - public void testArchiveTypeAnalyser() throws IOException, RatException { - MonolithicFileDocument document = new MonolithicFileDocument(new File( - "src/test/elements/Dummy.jar")); - IDocumentAnalyser analyser = new DefaultAnalyser(matcherStub); - analyser.analyse(document); - reporter.report(document); - assertEquals( - "Open archive element", - "", - out.toString()); - } - - /** - * Test abstract monolithicis composite. - */ - @Test - public void testAbstractMonolithicisComposite() { - MonolithicFileDocument document = new MonolithicFileDocument(new File( - "src/test/elements/Dummy.jar")); - Assert.assertFalse(document.isComposite()); - } - - /** - * Test standard type analyser exception. - * - * @throws IOException - * Signals that an I/O exception has occurred. - * @throws RatException - * the rat exception - */ - @Test(expected = IOException.class) - public void testStandardTypeAnalyserFileException() throws IOException, - RatException { - MonolithicFileDocument document = new MonolithicFileDocument(new File( - "src/test/resources/elements/Text.txtt")); - IDocumentAnalyser analyser = new DefaultAnalyser(matcherStub); - analyser.analyse(document); - } - - /** - * Test note guesser file extensions. - * - * @throws IOException - * Signals that an I/O exception has occurred. - * @throws RatException - * the rat exception - */ - @Test - public void testNoteGuesserFileExtensions() throws IOException, - RatException { - MonolithicFileDocument document = new MonolithicFileDocument(new File( - "src/test/resources/elements/test.LICENSE")); - IDocumentAnalyser analyser = new DefaultAnalyser(matcherStub); - analyser.analyse(document); - Assert.assertEquals(document.getMetaData().getData().size(), 1); - } + /** + * Sets the up. + * + * @throws Exception + * the exception + */ + @Before + public void setUp() throws Exception { + this.out = new StringWriter(); + final XmlWriter writer = new XmlWriter(this.out); + this.reporter = new SimpleXmlClaimReporter(writer); + this.matcherStub = new IHeaderMatcher() { + public boolean match(final Document subject, final String line) { + return false; + } + + public void reset() { + } + }; + } + + /** + * Standard type analyser. + * + * @throws IOException + * Signals that an I/O exception has occurred. + * @throws RatException + * the rat exception + */ + @Test + public void testStandardTypeAnalyser() throws IOException, RatException { + final MonolithicFileDocument document = + new MonolithicFileDocument(new File( + "src/test/resources/elements/Text.txt")); + final DefaultAnalyser analyser = new DefaultAnalyser(this.matcherStub); + analyser.analyse(document); + this.reporter.report(document); + assertEquals( + "Open standard element", + "/*\n" + + " * Licensed to the Apache Software Foundation (ASF) under one\n" + + " * or more contributor license agreements. See the NOTICE file\n" + + " * distributed with this work for additional information\n" + + " * regarding copyright ownership. The ASF licenses this file\n" + + " * to you under the Apache License, Version 2.0 (the \"License\");\n" + + " * you may not use this file except in compliance with the License.\n" + + " * You may obtain a copy of the License at\n" + + " *\n" + + " * http://www.apache.org/licenses/LICENSE-2.0\n" + + " *\n" + + " * Unless required by applicable law or agreed to in writing,\n" + + " * software distributed under the License is distributed on an\n" + + " * \"AS IS\" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\n" + + " * KIND, either express or implied. See the License for the\n" + + " * specific language governing permissions and limitations\n" + + " * under the License. \n" + + " */\n" + + "\n" + + " \n" + + "", + this.out.toString()); + } + + /** + * Note type analyser. + * + * @throws IOException + * Signals that an I/O exception has occurred. + * @throws RatException + * the rat exception + */ + @Test + public void testNoteTypeAnalyser() throws IOException, RatException { + final MonolithicFileDocument document = + new MonolithicFileDocument( + new File("src/test/elements/LICENSE")); + final DefaultAnalyser analyser = new DefaultAnalyser(this.matcherStub); + analyser.analyse(document); + this.reporter.report(document); + assertEquals( + "Open note element", + "", + this.out.toString()); + } + + /** + * Binary type analyser. + * + * @throws IOException + * Signals that an I/O exception has occurred. + * @throws RatException + * the rat exception + */ + @Test + public void testBinaryTypeAnalyser() throws IOException, RatException { + final MonolithicFileDocument document = + new MonolithicFileDocument(new File( + "src/test/elements/Image.png")); + final DefaultAnalyser analyser = new DefaultAnalyser(this.matcherStub); + analyser.analyse(document); + this.reporter.report(document); + assertEquals( + "Open binary element", + "", + this.out.toString()); + } + + /** + * Archive type analyser. + * + * @throws IOException + * Signals that an I/O exception has occurred. + * @throws RatException + * the rat exception + */ + @Test + public void testArchiveTypeAnalyser() throws IOException, RatException { + final MonolithicFileDocument document = + new MonolithicFileDocument(new File( + "src/test/elements/Dummy.jar")); + final DefaultAnalyser analyser = new DefaultAnalyser(this.matcherStub); + analyser.analyse(document); + this.reporter.report(document); + assertEquals( + "Open archive element", + "", + this.out.toString()); + } + + /** + * Test abstract monolithicis composite. + */ + @Test + public void testAbstractMonolithicisComposite() { + final MonolithicFileDocument document = + new MonolithicFileDocument(new File( + "src/test/elements/Dummy.jar")); + Assert.assertFalse(document.isComposite()); + } + + /** + * Test standard type analyser exception. + * + * @throws IOException + * Signals that an I/O exception has occurred. + * @throws RatException + * the rat exception + */ + @Test(expected = IOException.class) + public void testStandardTypeAnalyserFileException() throws IOException, + RatException { + final MonolithicFileDocument document = + new MonolithicFileDocument(new File( + "src/test/resources/elements/Text.txtt")); + final DefaultAnalyser analyser = new DefaultAnalyser(this.matcherStub); + analyser.analyse(document); + } + + /** + * Test note guesser file extensions. + * + * @throws IOException + * Signals that an I/O exception has occurred. + * @throws RatException + * the rat exception + */ + @Test + public void testNoteGuesserFileExtensions() throws IOException, + RatException { + final MonolithicFileDocument document = + new MonolithicFileDocument(new File( + "src/test/resources/elements/test.LICENSE")); + final DefaultAnalyser analyser = new DefaultAnalyser(this.matcherStub); + analyser.analyse(document); + Assert.assertEquals(document.getMetaData().getData().size(), 1); + } } Modified: creadur/rat/branches/gsoc/apache-rat-core/src/test/java/org/apache/rat/report/xml/XmlReportTest.java URL: http://svn.apache.org/viewvc/creadur/rat/branches/gsoc/apache-rat-core/src/test/java/org/apache/rat/report/xml/XmlReportTest.java?rev=1549163&r1=1549162&r2=1549163&view=diff ============================================================================== --- creadur/rat/branches/gsoc/apache-rat-core/src/test/java/org/apache/rat/report/xml/XmlReportTest.java (original) +++ creadur/rat/branches/gsoc/apache-rat-core/src/test/java/org/apache/rat/report/xml/XmlReportTest.java Sun Dec 8 19:50:07 2013 @@ -29,11 +29,10 @@ import java.util.regex.Pattern; import org.apache.rat.analysis.DefaultAnalyser; import org.apache.rat.analysis.IHeaderMatcher; import org.apache.rat.api.Document; -import org.apache.rat.document.IDocumentAnalyser; import org.apache.rat.report.AbstractReport; import org.apache.rat.report.RatReport; import org.apache.rat.report.claim.impl.xml.SimpleXmlClaimReporter; -import org.apache.rat.report.claim.util.ClaimReporterMultiplexer; +import org.apache.rat.report.claim.util.Pipeline; import org.apache.rat.report.xml.writer.IXmlWriter; import org.apache.rat.report.xml.writer.impl.base.XmlWriter; import org.apache.rat.test.utils.Resources; @@ -64,10 +63,10 @@ public class XmlReportTest { public void reset() { } }; - final IDocumentAnalyser analyser = new DefaultAnalyser(matcher); + final DefaultAnalyser analyser = new DefaultAnalyser(matcher); final List reporters = new ArrayList(); reporters.add(reporter); - this.report = new ClaimReporterMultiplexer(analyser, reporters); + this.report = new Pipeline(analyser, null, reporters); } private void report(final DirectoryWalker directory) throws Exception {