@Test(expected = NullPointerException.class) public void generateReport_MatchedDocOrganizations_NULL() { reportGenerator.generateReport(null); }
public List<ReportEntry> generateReport(JavaRDD<MatchedOrganization> matchedDocOrganizations) { Preconditions.checkNotNull(matchedDocOrganizations); List<ReportEntry> reportEntries = Lists.newArrayList(); long docOrgReferenceCount = matchedDocOrganizations.count(); reportEntries.add(createCounterReportEntry(DOC_ORG_REFERENCES, docOrgReferenceCount)); long docWithAtLeastOneOrgCount = matchedDocOrganizations.map(v->v.getDocumentId()).distinct().count(); reportEntries.add(createCounterReportEntry(DOCS_WITH_AT_LEAST_ONE_ORG, docWithAtLeastOneOrgCount)); return reportEntries; }
AffMatchReportGenerator implements Serializable { public List<ReportEntry> generateReport(JavaRDD<MatchedOrganization> matchedDocOrganizations) { Preconditions.checkNotNull(matchedDocOrganizations); List<ReportEntry> reportEntries = Lists.newArrayList(); long docOrgReferenceCount = matchedDocOrganizations.count(); reportEntries.add(createCounterReportEntry(DOC_ORG_REFERENCES, docOrgReferenceCount)); long docWithAtLeastOneOrgCount = matchedDocOrganizations.map(v->v.getDocumentId()).distinct().count(); reportEntries.add(createCounterReportEntry(DOCS_WITH_AT_LEAST_ONE_ORG, docWithAtLeastOneOrgCount)); return reportEntries; } }
AffMatchReportGenerator implements Serializable { public List<ReportEntry> generateReport(JavaRDD<MatchedOrganization> matchedDocOrganizations) { Preconditions.checkNotNull(matchedDocOrganizations); List<ReportEntry> reportEntries = Lists.newArrayList(); long docOrgReferenceCount = matchedDocOrganizations.count(); reportEntries.add(createCounterReportEntry(DOC_ORG_REFERENCES, docOrgReferenceCount)); long docWithAtLeastOneOrgCount = matchedDocOrganizations.map(v->v.getDocumentId()).distinct().count(); reportEntries.add(createCounterReportEntry(DOCS_WITH_AT_LEAST_ONE_ORG, docWithAtLeastOneOrgCount)); return reportEntries; }  }
AffMatchReportGenerator implements Serializable { public List<ReportEntry> generateReport(JavaRDD<MatchedOrganization> matchedDocOrganizations) { Preconditions.checkNotNull(matchedDocOrganizations); List<ReportEntry> reportEntries = Lists.newArrayList(); long docOrgReferenceCount = matchedDocOrganizations.count(); reportEntries.add(createCounterReportEntry(DOC_ORG_REFERENCES, docOrgReferenceCount)); long docWithAtLeastOneOrgCount = matchedDocOrganizations.map(v->v.getDocumentId()).distinct().count(); reportEntries.add(createCounterReportEntry(DOCS_WITH_AT_LEAST_ONE_ORG, docWithAtLeastOneOrgCount)); return reportEntries; }  List<ReportEntry> generateReport(JavaRDD<MatchedOrganization> matchedDocOrganizations); }
AffMatchReportGenerator implements Serializable { public List<ReportEntry> generateReport(JavaRDD<MatchedOrganization> matchedDocOrganizations) { Preconditions.checkNotNull(matchedDocOrganizations); List<ReportEntry> reportEntries = Lists.newArrayList(); long docOrgReferenceCount = matchedDocOrganizations.count(); reportEntries.add(createCounterReportEntry(DOC_ORG_REFERENCES, docOrgReferenceCount)); long docWithAtLeastOneOrgCount = matchedDocOrganizations.map(v->v.getDocumentId()).distinct().count(); reportEntries.add(createCounterReportEntry(DOCS_WITH_AT_LEAST_ONE_ORG, docWithAtLeastOneOrgCount)); return reportEntries; }  List<ReportEntry> generateReport(JavaRDD<MatchedOrganization> matchedDocOrganizations);  }