ResultsWriterUtils { public static List<VariantEffectCount> makeVariantEffectCounters(List<String> sampleNames, List<VariantEvaluation> variantEvaluations) { final Set<VariantEffect> variantEffects = ImmutableSet.of( VariantEffect.FRAMESHIFT_ELONGATION, VariantEffect.FRAMESHIFT_TRUNCATION, VariantEffect.FRAMESHIFT_VARIANT, VariantEffect.INTERNAL_FEATURE_ELONGATION, VariantEffect.FEATURE_TRUNCATION, VariantEffect.MNV, VariantEffect.STOP_GAINED, VariantEffect.STOP_LOST, VariantEffect.START_LOST, VariantEffect.SPLICE_ACCEPTOR_VARIANT, VariantEffect.SPLICE_DONOR_VARIANT, VariantEffect.MISSENSE_VARIANT, VariantEffect.INFRAME_INSERTION, VariantEffect.DISRUPTIVE_INFRAME_INSERTION, VariantEffect.INFRAME_DELETION, VariantEffect.DISRUPTIVE_INFRAME_DELETION, VariantEffect.SPLICE_REGION_VARIANT, VariantEffect.STOP_RETAINED_VARIANT, VariantEffect.INITIATOR_CODON_VARIANT, VariantEffect.SYNONYMOUS_VARIANT, VariantEffect.FIVE_PRIME_UTR_TRUNCATION, VariantEffect.FIVE_PRIME_UTR_INTRON_VARIANT, VariantEffect.FIVE_PRIME_UTR_INTRON_VARIANT, VariantEffect.THREE_PRIME_UTR_TRUNCATION, VariantEffect.THREE_PRIME_UTR_INTRON_VARIANT, VariantEffect.THREE_PRIME_UTR_EXON_VARIANT, VariantEffect.CODING_TRANSCRIPT_INTRON_VARIANT, VariantEffect.NON_CODING_TRANSCRIPT_EXON_VARIANT, VariantEffect.NON_CODING_TRANSCRIPT_INTRON_VARIANT, VariantEffect.UPSTREAM_GENE_VARIANT, VariantEffect.DOWNSTREAM_GENE_VARIANT, VariantEffect.INTERGENIC_VARIANT, VariantEffect.REGULATORY_REGION_VARIANT); VariantEffectCounter variantEffectCounter = new VariantEffectCounter(sampleNames, variantEvaluations); return variantEffectCounter.getVariantEffectCounts(variantEffects); } private  ResultsWriterUtils(); static String makeOutputFilename(Path vcfPath, String outputPrefix, OutputFormat outputFormat, ModeOfInheritance modeOfInheritance); static List<VariantEffectCount> makeVariantEffectCounters(List<String> sampleNames, List<VariantEvaluation> variantEvaluations); static List<FilterReport> makeFilterReports(Analysis analysis, AnalysisResults analysisResults); static List<Gene> getMaxPassedGenes(List<Gene> genes, int maxGenes);  }
@Test public void canMakeEmptyVariantTypeCounterFromEmptyVariantEvaluations() { List<VariantEvaluation> variantEvaluations = Collections.emptyList(); List<VariantEffectCount> variantTypeCounters = ResultsWriterUtils.makeVariantEffectCounters(Collections.emptyList(), variantEvaluations); assertThat(variantTypeCounters.isEmpty(), is(false)); VariantEffectCount firstVariantTypeCount = variantTypeCounters.get(0); assertThat(firstVariantTypeCount.getVariantType(), notNullValue()); assertThat(firstVariantTypeCount.getSampleVariantTypeCounts().isEmpty(), is(true)); }