@Test public void testSetup() throws Exception { collapser.setup(context); verify(totalTextCounter).setValue(0); verify(docsWithAtLeastOneCitationTextCounter).setValue(0); }
@Override public void setup(TaskAttemptContext context) { totalTextCounter = context.getCounter(CitationTextCounters.TOTAL); totalTextCounter.setValue(0); docsWithAtLeastOneCitationTextCounter = context.getCounter(CitationTextCounters.DOCS_WITH_AT_LEAST_ONE_CITATION); docsWithAtLeastOneCitationTextCounter.setValue(0); totalMatchedCounter = context.getCounter(MatchedCitationCounters.TOTAL); totalMatchedCounter.setValue(0); docsWithAtLeastOneMatchedCitationCounter = context.getCounter(MatchedCitationCounters.DOCS_WITH_AT_LEAST_ONE_CITATION); docsWithAtLeastOneMatchedCitationCounter.setValue(0); }
GenericCitationCollapser extends AbstractSimpleCollapser<Citation> { @Override public void setup(TaskAttemptContext context) { totalTextCounter = context.getCounter(CitationTextCounters.TOTAL); totalTextCounter.setValue(0); docsWithAtLeastOneCitationTextCounter = context.getCounter(CitationTextCounters.DOCS_WITH_AT_LEAST_ONE_CITATION); docsWithAtLeastOneCitationTextCounter.setValue(0); totalMatchedCounter = context.getCounter(MatchedCitationCounters.TOTAL); totalMatchedCounter.setValue(0); docsWithAtLeastOneMatchedCitationCounter = context.getCounter(MatchedCitationCounters.DOCS_WITH_AT_LEAST_ONE_CITATION); docsWithAtLeastOneMatchedCitationCounter.setValue(0); } }
GenericCitationCollapser extends AbstractSimpleCollapser<Citation> { @Override public void setup(TaskAttemptContext context) { totalTextCounter = context.getCounter(CitationTextCounters.TOTAL); totalTextCounter.setValue(0); docsWithAtLeastOneCitationTextCounter = context.getCounter(CitationTextCounters.DOCS_WITH_AT_LEAST_ONE_CITATION); docsWithAtLeastOneCitationTextCounter.setValue(0); totalMatchedCounter = context.getCounter(MatchedCitationCounters.TOTAL); totalMatchedCounter.setValue(0); docsWithAtLeastOneMatchedCitationCounter = context.getCounter(MatchedCitationCounters.DOCS_WITH_AT_LEAST_ONE_CITATION); docsWithAtLeastOneMatchedCitationCounter.setValue(0); }  }
GenericCitationCollapser extends AbstractSimpleCollapser<Citation> { @Override public void setup(TaskAttemptContext context) { totalTextCounter = context.getCounter(CitationTextCounters.TOTAL); totalTextCounter.setValue(0); docsWithAtLeastOneCitationTextCounter = context.getCounter(CitationTextCounters.DOCS_WITH_AT_LEAST_ONE_CITATION); docsWithAtLeastOneCitationTextCounter.setValue(0); totalMatchedCounter = context.getCounter(MatchedCitationCounters.TOTAL); totalMatchedCounter.setValue(0); docsWithAtLeastOneMatchedCitationCounter = context.getCounter(MatchedCitationCounters.DOCS_WITH_AT_LEAST_ONE_CITATION); docsWithAtLeastOneMatchedCitationCounter.setValue(0); }  @Override void setup(TaskAttemptContext context); }
GenericCitationCollapser extends AbstractSimpleCollapser<Citation> { @Override public void setup(TaskAttemptContext context) { totalTextCounter = context.getCounter(CitationTextCounters.TOTAL); totalTextCounter.setValue(0); docsWithAtLeastOneCitationTextCounter = context.getCounter(CitationTextCounters.DOCS_WITH_AT_LEAST_ONE_CITATION); docsWithAtLeastOneCitationTextCounter.setValue(0); totalMatchedCounter = context.getCounter(MatchedCitationCounters.TOTAL); totalMatchedCounter.setValue(0); docsWithAtLeastOneMatchedCitationCounter = context.getCounter(MatchedCitationCounters.DOCS_WITH_AT_LEAST_ONE_CITATION); docsWithAtLeastOneMatchedCitationCounter.setValue(0); }  @Override void setup(TaskAttemptContext context);  }