Matrix Science header

ms_mascotrespeptide.hpp

00001 /*
00002 ##############################################################################
00003 # file: ms_mascotrespeptide.hpp                                              #
00004 # 'msparser' toolkit                                                         #
00005 # Encapsulates a peptide from the summary section or peptides section of the #
00006 # mascot results file                                                        #
00007 ##############################################################################
00008 # COPYRIGHT NOTICE                                                           #
00009 # Copyright 1998-2002 Matrix Science Limited  All Rights Reserved.           #
00010 #                                                                            #
00011 ##############################################################################
00012 #    $Archive:: /MowseBranches/ms_mascotresfile_1.2/include/ms_mascotrespe $ #
00013 #     $Author: francoisr $ #
00014 #       $Date: 2017/03/31 10:23:24 $ #
00015 #   $Revision: 1.46 $ #
00016 # $NoKeywords::                                                            $ #
00017 ##############################################################################
00018 */
00019 
00020 #ifndef MS_MASCOTRESPEPTIDE_HPP
00021 #define MS_MASCOTRESPEPTIDE_HPP
00022 
00023 #ifdef _WIN32
00024 #pragma warning(disable:4251)   // Don't want all classes to be exported
00025 #pragma warning(disable:4786)   // Debug symbols too long
00026 #   ifndef _MATRIX_USE_STATIC_LIB
00027 #       ifdef MS_MASCOTRESFILE_EXPORTS
00028 #           define MS_MASCOTRESFILE_API __declspec(dllexport)
00029 #       else
00030 #           define MS_MASCOTRESFILE_API __declspec(dllimport)
00031 #       endif
00032 #   else
00033 #       define MS_MASCOTRESFILE_API
00034 #   endif
00035 #else
00036 #   define MS_MASCOTRESFILE_API
00037 #endif
00038 
00039 // for the sake of #include <string>
00040 #ifdef __ALPHA_UNIX__
00041 #include <ctype.h>
00042 #endif
00043 
00044 // Includes from the standard template library
00045 #include <string>
00046 #include <vector>
00047 
00048 namespace msparser_internal {
00049     class ms_peptide_impl;
00050 }
00051 
00052 namespace matrix_science {
00053     class ms_protein;
00054     class ms_mascotresults;
00055 
00061 
00062 
00073     class MS_MASCOTRESFILE_API ms_peptide
00074     {
00075         public:
00077             ms_peptide();
00078 
00080             ms_peptide( int         query,
00081                         int         rank,
00082                         int         missedCleavages,
00083                         double      mrCalc,
00084                         double      delta,
00085                         double      observed,
00086                         int         charge,
00087                         int         numIonsMatched,
00088                         std::string peptideStr,
00089                         int         peaksUsedFromIons1,
00090                         std::string varModsStr,
00091                         double      ionsScore,
00092                         std::string seriesUsedStr,
00093                         int         peaksUsedFromIons2,
00094                         int         peaksUsedFromIons3,
00095                         const ms_mascotresults * pResults = 0,
00096                         bool        storeReloadableInfo = true);
00097 
00098             enum SEARCH_PHASE {
00099                 SEARCH_PHASE_PRIMARY = 0,
00100                 SEARCH_PHASE_ERRTOL = 1,
00101                 SEARCH_PHASE_LIBRARY = 2
00102             };
00103 
00105             ms_peptide( const int                query,
00106                         const int                rank,
00107                         const SEARCH_PHASE       searchPhase,
00108                         const int                missedCleavages,
00109                         const double             mrCalc,
00110                         const double             delta,
00111                         const double             observed,
00112                         const int                charge,
00113                         const int                numIonsMatched,
00114                         const std::string      & peptideStr,
00115                         const int                peaksUsedFromIons1,
00116                         const std::string      & varModsStr,
00117                         const std::string      & summedModsStr,
00118                         const std::string      & localModsStr,
00119                         const double             ionsScore,
00120                         const std::string      & seriesUsedStr,
00121                         const int                peaksUsedFromIons2,
00122                         const int                peaksUsedFromIons3,
00123                         const std::string      & primaryNlStr,
00124                         const std::string      & summedModsNlStr,
00125                         const std::string      & localModsNlStr,
00126                         const std::string      & substStr,
00127                         const std::string      & componentStr,
00128                         const ms_mascotresults * pResults = 0,
00129                         const bool               storeReloadableInfo = true);
00130 
00132             ms_peptide(const ms_peptide& src);
00133 
00135             ~ms_peptide();
00136 
00137 #ifndef SWIG
00138 
00139             ms_peptide& operator=(const ms_peptide& right);
00140 #endif
00141 
00142             void copyFrom(const ms_peptide* src);
00143 
00145             bool clearReloadableInfo();
00146 
00148             int         getQuery()              const;
00149 
00151             int         getRank()               const;
00152             void        setRank(int rank);
00153             
00155             int         getPrettyRank()         const;
00156             void        setPrettyRank(int rank);
00157             
00159             int         getAmbiguityGroupId()         const;
00161             void        setAmbiguityGroupId(int group);
00162 
00164             bool        getAnyMatch()           const;
00165 
00167             int         getMissedCleavages()    const;
00168 
00170             double      getMrCalc()             const;
00171 
00173             double      getDelta()              const;
00174 
00176             double      getObserved()           const;
00177 
00179             double      getMrExperimental()     const;
00180 
00182             int         getCharge()             const;
00183 
00185             int         getNumIonsMatched()     const;
00186 
00188             std::string getPeptideStr(bool substituteAmbiguous = true) const;
00189 
00191             int         getPeptideLength()      const;
00192 
00194             int         getPeaksUsedFromIons1() const;
00195 
00197             int         getPeaksUsedFromIons2() const;
00198 
00200             int         getPeaksUsedFromIons3() const;
00201 
00203             std::string getVarModsStr()         const;
00204 
00206             void        setVarModsStr(const std::string str);
00207 
00209             std::string getSummedModsStr()         const;
00210 
00212             void        setSummedModsStr(const std::string str);
00213 
00215             std::string getLocalModsStr()         const;
00216 
00218             void        setLocalModsStr(const std::string str);
00219 
00221             std::string getParsedLocalModsStr()         const;
00222 
00224             double      getIonsScore()          const;
00225 
00227             double      getExpectationValue() const;
00228 
00230             std::string getSeriesUsedStr()      const;
00231 
00233             bool        isSamePeptideStr(ms_peptide * peptide, 
00234                                          bool substituteAmbiguous = true) const;
00235 
00237             bool        isSameVarModsStr(ms_peptide * peptide) const;
00238 
00240             bool        isSameSummedModsStr(ms_peptide * peptide) const;
00241 
00243             int         getFirstProtAppearedIn() const;
00244 
00247             void        setFirstProtAppearedIn(int n);
00248 
00250             double      getIonsIntensity()      const;
00251             void        setIonsIntensity(double n);
00252 
00254             const ms_protein * getProtein(int num) const;
00255 
00257             const std::vector<int> getProteins()const;
00258 
00260             int         getNumProteins()        const;
00261             void addProtein(const ms_protein * protein);
00262             void addProtein(const int hitNumber);
00263 
00265             std::string getAmbiguityString()    const;
00266             bool setAmbiguityString(const std::string val);
00267 
00269             std::string getPrimaryNlStr()       const;
00270             void        setPrimaryNlStr(const std::string value);
00271 
00273             std::string getSummedModsNlStr()       const;
00274             void        setSummedModsNlStr(const std::string value);
00275 
00277             std::string getLocalModsNlStr()       const;
00278             void        setLocalModsNlStr(const std::string value);
00279 
00281             bool getIsFromErrorTolerant()       const;
00282             void setIsFromErrorTolerant(const bool isFromErrorTolerant);
00283 
00285             std::string getComponentStr()       const;
00286             void        setComponentStr(const std::string value);
00287 
00289             bool        getLessThanMinPepLen()  const;
00290 
00292             int getNum13C(const double tol, const std::string tolu, const std::string mass_type) const;
00293 
00295             void setPercolatorScores(double posteriorErrorProbability, 
00296                                      double qValue,
00297                                      double internalPercolatorScore);
00298 
00300             bool anyPercolatorResults()     const;
00301 
00303             void getPercolatorScores(double * posteriorErrorProbability, 
00304                                      double * qValue, 
00305                                      double * internalPercolatorScore, 
00306                                      double * mascotIonsScore) const;
00307 
00309             bool getIsFromLibrary()       const;
00310             void setIsFromLibrary(const bool isFromLibrary);
00311 
00313             void getAnyProteinTermination(
00314                     bool & isNterminus,
00315                     bool & isCterminus) const;
00316 
00318             void setInternalSortingScore(double s);
00319 
00321             double getInternalSortingScore() const;
00322 
00323         private:
00324             msparser_internal::ms_peptide_impl * pImpl_;
00325     }; // end of resfile_group
00327 }   // matrix_science namespace
00328 
00329 #endif // MS_MASCOTRESPEPTIDE_HPP
00330 
00331 /*------------------------------- End of File -------------------------------*/
Copyright © 2016 Matrix Science Ltd.  All Rights Reserved. Generated on Fri Jun 2 2017 01:44:51