Class QuantificationFeaturesCache

java.lang.Object
eu.isas.reporter.calculation.QuantificationFeaturesCache

public class QuantificationFeaturesCache extends Object
The quantification features cache stores quantification features.
Author:
Marc Vaudel, Harald Barsnes
  • Constructor Details

    • QuantificationFeaturesCache

      public QuantificationFeaturesCache()
      Constructor.
  • Method Details

    • isEmpty

      public boolean isEmpty()
      Indicates whether the cache is empty
      Returns:
      true if the cache is empty
    • memoryCheck

      public boolean memoryCheck()
      Indicates whether the memory used by the application is lower than a given share of the heap size. The share is set by memoryShare.
      Returns:
      a boolean indicating whether the memory used by the application is lower than 99% of the heap
    • addProteinMatchQuantificationDetails

      public void addProteinMatchQuantificationDetails(int nPeptides, long matchKey, ProteinQuantificationDetails matchQuantificationDetails)
      Adds protein quantification details to the cache.
      Parameters:
      nPeptides - the number of peptides of this protein match
      matchKey - the key of the protein match
      matchQuantificationDetails - the protein quantification details
    • getProteinMatchQuantificationDetails

      public ProteinQuantificationDetails getProteinMatchQuantificationDetails(int nPeptides, long matchKey)
      Returns protein quantification details, null if not in cache.
      Parameters:
      nPeptides - the number of peptides of this protein match
      matchKey - the key of the protein match
      Returns:
      the protein quantification details
    • addPtmQuantificationDetails

      public void addPtmQuantificationDetails(String ptmName, long matchKey, int site, ProteinPtmQuantificationDetails matchQuantificationDetails)
      Adds protein level PTM quantification details to the cache.
      Parameters:
      ptmName - the name of the PTM
      matchKey - the key of the protein match
      site - the site of the PTM on the protein sequence
      matchQuantificationDetails - the protein quantification details
    • getPtmQuantificationDetails

      public ProteinPtmQuantificationDetails getPtmQuantificationDetails(String ptmName, long matchKey, int site)
      Returns protein level PTM quantification details, null if not in cache.
      Parameters:
      ptmName - the name of the PTM
      matchKey - the key of the protein match
      site - the site of the PTM on the protein sequence
      Returns:
      The protein quantification details
    • addPeptideMatchQuantificationDetails

      public void addPeptideMatchQuantificationDetails(int nPeptides, Long matchKey, PeptideQuantificationDetails matchQuantificationDetails)
      Adds peptide quantification details ratio to the cache.
      Parameters:
      nPeptides - the number of peptides of this protein match
      matchKey - the key of the protein match
      matchQuantificationDetails - The protein quantification details
    • getPeptideMatchQuantificationDetails

      public PeptideQuantificationDetails getPeptideMatchQuantificationDetails(int nPsms, Long matchKey)
      Returns peptide quantification details, null if not in cache.
      Parameters:
      nPsms - the number of PSMs of this peptide match
      matchKey - the key of the peptide match
      Returns:
      the peptide quantification details
    • addPSMQuantificationDetails

      public void addPSMQuantificationDetails(String spectrumFile, String spectrumTitle, PsmQuantificationDetails matchQuantificationDetails)
      Adds PSM quantification details ratio to the cache.
      Parameters:
      spectrumFile - the spectrum file
      spectrumTitle - the spectrum title
      matchQuantificationDetails - the protein quantification details
    • getPSMQuantificationDetails

      public PsmQuantificationDetails getPSMQuantificationDetails(String spectrumFile, String spectrumTitle)
      Returns PSM quantification details, null if not in cache.
      Parameters:
      spectrumFile - the spectrum file
      spectrumTitle - the spectrum title
      Returns:
      the PSM quantification details
    • addSpectrumQuantificationDetails

      public void addSpectrumQuantificationDetails(String spectrumFile, String spectrumTitle, SpectrumQuantificationDetails matchQuantificationDetails)
      Adds spectrum quantification details ratio to the cache.
      Parameters:
      spectrumFile - the spectrum file
      spectrumTitle - the spectrum title
      matchQuantificationDetails - the spectrum quantification details
    • getSpectrumQuantificationDetails

      public SpectrumQuantificationDetails getSpectrumQuantificationDetails(String spectrumFile, String spectrumTitle)
      Returns spectrum quantification details, null if not in cache.
      Parameters:
      spectrumFile - the spectrum file
      spectrumTitle - the spectrum title
      Returns:
      the spectrum quantification details