@Test(expected = NullPointerException.class) public void computeMatches_null() { affOrgMatchComputer.computeMatches(null); }
public JavaRDD<AffMatchResult> computeMatches(JavaRDD<Tuple2<AffMatchAffiliation, AffMatchOrganization>> joinedAffOrgs) { checkNotNull(joinedAffOrgs); checkState(CollectionUtils.isNotEmpty(affOrgMatchVoters), "no AffOrgMatchVoter has been set"); JavaRDD<AffMatchResult> affMatchResults = joinedAffOrgs.map(kv->new AffMatchResult(kv._1(), kv._2(), 0)); for (AffOrgMatchVoter voter : affOrgMatchVoters) { affMatchResults = affMatchResults.map(affOrgMatch -> affOrgMatchStrengthRecalculator.recalculateMatchStrength(affOrgMatch, voter)); } affMatchResults = affMatchResults.filter(affOrgMatch -> affOrgMatch.getMatchStrength() > 0); return affMatchResults; }
AffOrgMatchComputer implements Serializable { public JavaRDD<AffMatchResult> computeMatches(JavaRDD<Tuple2<AffMatchAffiliation, AffMatchOrganization>> joinedAffOrgs) { checkNotNull(joinedAffOrgs); checkState(CollectionUtils.isNotEmpty(affOrgMatchVoters), "no AffOrgMatchVoter has been set"); JavaRDD<AffMatchResult> affMatchResults = joinedAffOrgs.map(kv->new AffMatchResult(kv._1(), kv._2(), 0)); for (AffOrgMatchVoter voter : affOrgMatchVoters) { affMatchResults = affMatchResults.map(affOrgMatch -> affOrgMatchStrengthRecalculator.recalculateMatchStrength(affOrgMatch, voter)); } affMatchResults = affMatchResults.filter(affOrgMatch -> affOrgMatch.getMatchStrength() > 0); return affMatchResults; } }
AffOrgMatchComputer implements Serializable { public JavaRDD<AffMatchResult> computeMatches(JavaRDD<Tuple2<AffMatchAffiliation, AffMatchOrganization>> joinedAffOrgs) { checkNotNull(joinedAffOrgs); checkState(CollectionUtils.isNotEmpty(affOrgMatchVoters), "no AffOrgMatchVoter has been set"); JavaRDD<AffMatchResult> affMatchResults = joinedAffOrgs.map(kv->new AffMatchResult(kv._1(), kv._2(), 0)); for (AffOrgMatchVoter voter : affOrgMatchVoters) { affMatchResults = affMatchResults.map(affOrgMatch -> affOrgMatchStrengthRecalculator.recalculateMatchStrength(affOrgMatch, voter)); } affMatchResults = affMatchResults.filter(affOrgMatch -> affOrgMatch.getMatchStrength() > 0); return affMatchResults; }  }
AffOrgMatchComputer implements Serializable { public JavaRDD<AffMatchResult> computeMatches(JavaRDD<Tuple2<AffMatchAffiliation, AffMatchOrganization>> joinedAffOrgs) { checkNotNull(joinedAffOrgs); checkState(CollectionUtils.isNotEmpty(affOrgMatchVoters), "no AffOrgMatchVoter has been set"); JavaRDD<AffMatchResult> affMatchResults = joinedAffOrgs.map(kv->new AffMatchResult(kv._1(), kv._2(), 0)); for (AffOrgMatchVoter voter : affOrgMatchVoters) { affMatchResults = affMatchResults.map(affOrgMatch -> affOrgMatchStrengthRecalculator.recalculateMatchStrength(affOrgMatch, voter)); } affMatchResults = affMatchResults.filter(affOrgMatch -> affOrgMatch.getMatchStrength() > 0); return affMatchResults; }  JavaRDD<AffMatchResult> computeMatches(JavaRDD<Tuple2<AffMatchAffiliation, AffMatchOrganization>> joinedAffOrgs); void setAffOrgMatchVoters(List<AffOrgMatchVoter> affOrgMatchVoters); }
AffOrgMatchComputer implements Serializable { public JavaRDD<AffMatchResult> computeMatches(JavaRDD<Tuple2<AffMatchAffiliation, AffMatchOrganization>> joinedAffOrgs) { checkNotNull(joinedAffOrgs); checkState(CollectionUtils.isNotEmpty(affOrgMatchVoters), "no AffOrgMatchVoter has been set"); JavaRDD<AffMatchResult> affMatchResults = joinedAffOrgs.map(kv->new AffMatchResult(kv._1(), kv._2(), 0)); for (AffOrgMatchVoter voter : affOrgMatchVoters) { affMatchResults = affMatchResults.map(affOrgMatch -> affOrgMatchStrengthRecalculator.recalculateMatchStrength(affOrgMatch, voter)); } affMatchResults = affMatchResults.filter(affOrgMatch -> affOrgMatch.getMatchStrength() > 0); return affMatchResults; }  JavaRDD<AffMatchResult> computeMatches(JavaRDD<Tuple2<AffMatchAffiliation, AffMatchOrganization>> joinedAffOrgs); void setAffOrgMatchVoters(List<AffOrgMatchVoter> affOrgMatchVoters);  }