AminoAcidFunctions { @NotNull public static String forceSingleLetterProteinAnnotation(@NotNull String proteinAnnotation) { String convertedProteinAnnotation = proteinAnnotation; for (Map.Entry<String, String> mapping : TRI_LETTER_AMINO_ACID_TO_SINGLE_LETTER.entrySet()) { convertedProteinAnnotation = convertedProteinAnnotation.replaceAll(mapping.getKey(), mapping.getValue()); } return convertedProteinAnnotation; }  @Nullable static String findAminoAcidForCodon(@NotNull String codon); @NotNull static List<String> allTrinucleotidesForSameAminoAcid(@NotNull String trinucleotideToFind, @NotNull Strand strand); @NotNull static String forceSingleLetterProteinAnnotation(@NotNull String proteinAnnotation); @NotNull static String reverseAndFlip(@NotNull String string);  }
@Test public void canForceSingleLetterProteinAnnotation() { assertEquals("p.N334K", AminoAcidFunctions.forceSingleLetterProteinAnnotation("p.Asn334Lys")); }