java.lang.Object
com.compomics.util.experiment.identification.protein_sequences.digestion.PeptideDraft

public class PeptideDraft
extends Object
Draft of a peptide used during protein sequence digestion.
Author:
Marc Vaudel
  • Constructor Details

    • PeptideDraft

      public PeptideDraft()
      Empty default constructor
    • PeptideDraft

      public PeptideDraft​(char[] sequence)
      Constructor.
      Parameters:
      sequence - the peptide sequence.
    • PeptideDraft

      public PeptideDraft​(char[] sequence, String nTermModification, HashMap<Integer,​String> fixedAaModifications, double mass)
      Constructor.
      Parameters:
      sequence - the peptide sequence
      nTermModification - the N-term modification
      fixedAaModifications - the fixed modifications at amino acids
      mass - the mass
    • PeptideDraft

      public PeptideDraft​(char[] sequence, String nTermModification, HashMap<Integer,​String> fixedAaModifications, double mass, int missedCleavages)
      Constructor.
      Parameters:
      sequence - the peptide sequence
      nTermModification - the N-term modification
      fixedAaModifications - the fixed modifications at amino acids
      mass - the mass
      missedCleavages - the number of missed cleavages
    • PeptideDraft

      public PeptideDraft​(char[] sequence, String nTermModification, String cTermModification, HashMap<Integer,​String> fixedAaModifications, double mass)
      Constructor.
      Parameters:
      sequence - the peptide sequence
      nTermModification - the N-term modification
      cTermModification - the C-term modification
      fixedAaModifications - the fixed modifications at amino acids
      mass - the mass
    • PeptideDraft

      public PeptideDraft​(char[] sequence, String nTermModification, String cTermModification, HashMap<Integer,​String> fixedAaModifications, double mass, int missedCleavages)
      Constructor.
      Parameters:
      sequence - the peptide sequence
      nTermModification - the N-term modification
      cTermModification - the C-term modification
      fixedAaModifications - the fixed modifications at amino acids
      mass - the mass
      missedCleavages - the number of missed cleavages
  • Method Details

    • clone

      public PeptideDraft clone()
      Creates a new peptide draft with the same attributes as this one.
      Overrides:
      clone in class Object
      Returns:
      a new peptide draft
    • getSequence

      public char[] getSequence()
      Returns the sequence.
      Returns:
      the sequence
    • setSequence

      public void setSequence​(char[] sequence)
      Sets the sequence.
      Parameters:
      sequence - the sequence
    • length

      public int length()
      Returns the length of the sequence.
      Returns:
      the length of the sequence
    • getnTermModification

      public String getnTermModification()
      Returns the N-term modification.
      Returns:
      the N-term modification
    • setnTermModification

      public void setnTermModification​(String nTermModification)
      Sets the N-term modification.
      Parameters:
      nTermModification - the N-term modification
    • getcTermModification

      public String getcTermModification()
      Returns the C-term modification.
      Returns:
      the C-term modification
    • setcTermModification

      public void setcTermModification​(String cTermModification)
      Sets the C-term modification.
      Parameters:
      cTermModification - the C-term modification
    • getMass

      public double getMass()
      Returns the mass.
      Returns:
      the mass
    • setMass

      public void setMass​(double mass)
      Sets the mass.
      Parameters:
      mass - the mass
    • getFixedAaModifications

      public HashMap<Integer,​String> getFixedAaModifications()
      Returns the modifications at specific amino acids.
      Returns:
      the modifications at specific amino acids
    • setFixedAaModifications

      public void setFixedAaModifications​(HashMap<Integer,​String> fixedAaModifications)
      Sets the modifications at specific amino acids.
      Parameters:
      fixedAaModifications - the modifications at specific amino acids
    • increaseMissedCleavages

      public void increaseMissedCleavages()
      Increases the number of missed cleavages.
    • getMissedCleavages

      public int getMissedCleavages()
      Returns the number of missed cleavages.
      Returns:
      the number of missed cleavages
    • increaseNX

      public void increaseNX()
      Increases the number of Xs already considered in this draft.
    • getnX

      public int getnX()
      Returns the number of Xs already considered in this draft.
      Returns:
      the number of Xs
    • getIndexOnProtein

      public int getIndexOnProtein()
      Returns the peptide index on the protein.
      Returns:
      the peptide index on the protein
    • setIndexOnProtein

      public void setIndexOnProtein​(int indexOnProtein)
      Sets the peptide index on the protein.
      Parameters:
      indexOnProtein - the peptide index on the protein
    • getPeptide

      public ExtendedPeptide getPeptide​(double massMin, double massMax)
      Returns a peptide from the peptide draft.
      Parameters:
      massMin - the minimal mass
      massMax - the maximal mass
      Returns:
      the peptide built from the peptide draft
    • getPeptide

      public ExtendedPeptide getPeptide​(double massMin, double massMax, BoxedObject<Boolean> smallMass)
      Returns a peptide from the peptide draft.
      Parameters:
      massMin - the minimal mass
      massMax - the maximal mass
      smallMass - an encapsulated boolean indicating whether the peptide passed the maximal mass filter
      Returns:
      the peptide built from the peptide draft
    • getFixedModifications

      public String[] getFixedModifications()
      Returns the fixed modifications for the peptide.
      Returns:
      the fixed modifications for the peptide.