Class Codons


  • public final class Codons
    extends java.lang.Object
    Version:
    $Id: Codons.java 744 2007-07-30 02:57:11Z twobeers $
    Author:
    Andrew Rambaut, Alexei Drummond
    • Constructor Detail

      • Codons

        public Codons()
    • Method Detail

      • getStateCount

        public static int getStateCount()
      • getStates

        public static java.util.List<State> getStates()
      • getCanonicalStateCount

        public static int getCanonicalStateCount()
      • getCanonicalStates

        public static java.util.List<State> getCanonicalStates()
      • getState

        public static CodonState getState​(java.lang.String code)
        Gets the state object for the given code. Returns null if the code is illegal or contains ambiguous nucleotides.
        Parameters:
        code - a three-character string of non-ambiguous nucleotides in uppercase
        Returns:
        the state
      • getState

        public static CodonState getState​(int index)
      • getUnknownState

        public static CodonState getUnknownState()
      • getGapState

        public static CodonState getGapState()
      • isUnknown

        public static boolean isUnknown​(CodonState state)
      • isGap

        public static boolean isGap​(CodonState state)
      • toStateArray

        public static CodonState[] toStateArray​(java.lang.String sequenceString)
      • toStateArray

        public static CodonState[] toStateArray​(byte[] indexArray)