CanonicalAnnotation { @NotNull static String trimEnsembleVersion(@NotNull final String transcriptId) { if (transcriptId.startsWith("EN") && transcriptId.contains(".")) { return transcriptId.substring(0, transcriptId.indexOf(".")); } return transcriptId; } CanonicalAnnotation(@NotNull final List<DriverGene> driverGenes, @NotNull final List<CanonicalTranscript> transcripts); @NotNull Optional<SnpEffAnnotation> canonicalSnpEffAnnotation(@NotNull final List<SnpEffAnnotation> allAnnotations);  }
@Test public void testTrimEnsembleTranscriptId() { assertEquals("ENST00000361570", CanonicalAnnotation.trimEnsembleVersion("ENST00000361570")); assertEquals("ENST00000361570", CanonicalAnnotation.trimEnsembleVersion("ENST00000361570.v8")); }