SimpleSubstitutionMatrix implements SubstitutionMatrix<C> { @SuppressWarnings("unchecked") public SimpleSubstitutionMatrix() { this((CompoundSet<C>) AminoAcidCompoundSet.getAminoAcidCompoundSet(), new InputStreamReader( SimpleSubstitutionMatrix.class.getResourceAsStream("/blosum62.txt")), "blosum62"); } @SuppressWarnings("unchecked") // TODO proper generic type checking instead of possible ClassCastException  SimpleSubstitutionMatrix();  SimpleSubstitutionMatrix(CompoundSet<C> compoundSet, File fileInput);  SimpleSubstitutionMatrix(CompoundSet<C> compoundSet, Reader input, String name);  SimpleSubstitutionMatrix(CompoundSet<C> compoundSet, String matrixInput, String name);  SimpleSubstitutionMatrix(CompoundSet<C> compoundSet, short match, short replace); private  SimpleSubstitutionMatrix(CompoundSet<C> compoundSet, Scanner input, String name); @Override CompoundSet<C> getCompoundSet(); @Override String getDescription(); @Override short[][] getMatrix(); @Override String getMatrixAsString(); @Override short getMaxValue(); @Override short getMinValue(); @Override String getName(); @Override short getValue(C from, C to); @Override SubstitutionMatrix<C> normalizeMatrix(short scale); @Override void setDescription(String description); @Override void setName(String name); @Override String toString();  }
@Test() public void testSimpleSubstitutionMatrix() { SubstitutionMatrix<AminoAcidCompound> matrix = new SimpleSubstitutionMatrix<AminoAcidCompound>(); assertEquals(matrix.getCompoundSet(), AminoAcidCompoundSet.getAminoAcidCompoundSet()); assertEquals(matrix.getName(), "blosum62"); assertEquals(matrix.getMaxValue(), 11); assertEquals(matrix.getMinValue(), -4); }