NCBI C++ ToolKit
names.hpp
Go to the documentation of this file.

Go to the SVN repository for this file.

1 /* $Id: names.hpp 87240 2019-08-12 11:18:21Z fongah2 $
2  * ===========================================================================
3  *
4  * PUBLIC DOMAIN NOTICE
5  * National Center for Biotechnology Information
6  *
7  * This software/database is a "United States Government Work" under the
8  * terms of the United States Copyright Act. It was written as part of
9  * the author's official duties as a United States Government employee and
10  * thus cannot be copyrighted. This software/database is freely available
11  * to the public for use. The National Library of Medicine and the U.S.
12  * Government have not placed any restriction on its use or reproduction.
13  *
14  * Although all reasonable efforts have been taken to ensure the accuracy
15  * and reliability of the software and data, the NLM and the U.S.
16  * Government do not and cannot warrant the performance or results that
17  * may be obtained by using this software or data. The NLM and the U.S.
18  * Government disclaim all warranties, express or implied, including
19  * warranties of performance, merchantability or fitness for any particular
20  * purpose.
21  *
22  * Please cite the author in any work or product based on this material.
23  *
24  * ===========================================================================
25  *
26  * Author: Kevin Bealer
27  *
28  * File Description:
29  * Define names and value types for options known to blast4.
30  *
31  */
32 
33 /// @file names.hpp
34 /// Names used in blast4 network communications.
35 ///
36 /// This file declares string objects corresponding to names used when
37 /// specifying options for blast4 network communications protocol.
38 
39 #ifndef OBJECTS_BLAST_NAMES_HPP
40 #define OBJECTS_BLAST_NAMES_HPP
41 
42 #include <utility>
43 #include <string>
44 #include <corelib/ncbistl.hpp>
48 
50 
51 BEGIN_objects_SCOPE // namespace ncbi::objects::
52 
53 /// Index of remote BLAST options.
54 /// The blast4 server only supports a subset of these
119  eBlastOpt_ForceMbIndex, // corresponds to -use_index flag
120  eBlastOpt_MbIndexName, // corresponds to -index_name flag
124  eBlastOpt_DomainInclusionThreshold, // options for DELTA-BLAST
125 
144 
159  eBlastOpt_MaxValue // For testing/looping, not an actual parameter
160 };
161 
162 
163 /// Field properties for options in a Blast4 parameter list.
165 public:
166  /// Default constructor (for STL)
167  CBlast4Field() : m_Name("-"), m_Type(CBlast4_value::e_not_set) {}
168 
169  /// Construct field with name and type.
171  : m_Name(nm), m_Type(ch) {}
172 
173  static CBlast4Field& Get(EBlastOptIdx opt);
174  static const string& GetName(EBlastOptIdx opt);
175 
176  /// Get field name (key).
177  const string& GetName() const;
178 
179  /// Match field name and type to parameter.
180  bool Match(const CBlast4_parameter& p) const;
181 
182  /// Get field type.
183  CBlast4_value::E_Choice GetType() const;
184 
185 
186  /// Verify parameter name and type, and get boolean value.
187  bool GetBoolean(const CBlast4_parameter& p) const;
188 
189  /// Verify parameter name and type, and get big integer value.
190  Int8 GetBig_integer(const CBlast4_parameter& p) const;
191 
192  /// Verify parameter name and type, and get cutoff value.
193  CConstRef<CBlast4_cutoff> GetCutoff(const CBlast4_parameter& p) const;
194 
195  /// Verify parameter name and type, and get integer value.
196  int GetInteger(const CBlast4_parameter& p) const;
197 
198  /// Verify parameter name and type, and get integer list value.
199  list<int> GetIntegerList(const CBlast4_parameter& p) const;
200 
201  /// Verify parameter name and type, and get matrix (pssm) value.
202  CConstRef<CPssmWithParameters> GetMatrix(const CBlast4_parameter& p) const;
203 
204  /// Verify parameter name and type, and get query mask value.
205  CConstRef<CBlast4_mask> GetQueryMask(const CBlast4_parameter& p) const;
206 
207  /// Verify parameter name and type, and get real value.
208  double GetReal(const CBlast4_parameter & p) const;
209 
210  /// Verify parameter name and type, and get strand_type value.
211  EBlast4_strand_type GetStrandType(const CBlast4_parameter& p) const;
212 
213  /// Verify parameter name and type, and get string value.
214  string GetString(const CBlast4_parameter& p) const;
215 
216 private:
217  /// Field name string as used in Blast4_parameter objects.
218  string m_Name;
219 
220  /// Field value type as used in Blast4_parameter objects.
222 
223  /// Type for map of all blast4 field objects.
225 
226  /// Map of all blast4 field objects.
228 };
229 
230 /*****************************************************************************/
231 // String pairs used to support for get-search-info request
232 
233 /// Used to retrieve information about the BLAST search
235 /// Used to retrieve information about the BLAST alignments
237 
238 /// Used to retrieve the BLAST search status
240 /// Used to retrieve the BLAST search title
242 /// Used to retrieve the BLAST search subjects
244 
245 /// Used to retrieve the PSI-BLAST iteration number
247 
248 /// This function builds the reply name token in the get-search-info reply
249 /// objects, provided a pair of strings such as those defined above
250 /// (i.e.: kBlast4SearchInfoReq{Name,Value})
252 string Blast4SearchInfo_BuildReplyName(const string& name, const string& value);
253 
254 
255 END_objects_SCOPE // namespace ncbi::objects::
256 
258 
259 #endif // OBJECTS_BLAST_NAMES_HPP
User-defined methods of the data storage class.
User-defined methods of the data storage class.
Field properties for options in a Blast4 parameter list.
Definition: names.hpp:164
string m_Name
Field name string as used in Blast4_parameter objects.
Definition: names.hpp:218
static TFieldMap m_Fields
Map of all blast4 field objects.
Definition: names.hpp:227
CBlast4Field(const std::string &nm, CBlast4_value::E_Choice ch)
Construct field with name and type.
Definition: names.hpp:170
CBlast4Field()
Default constructor (for STL)
Definition: names.hpp:167
map< EBlastOptIdx, CBlast4Field > TFieldMap
Type for map of all blast4 field objects.
Definition: names.hpp:224
CBlast4_value::E_Choice m_Type
Field value type as used in Blast4_parameter objects.
Definition: names.hpp:221
CBlast4_parameter –.
CBlast4_value –.
CConstRef –.
Definition: ncbiobj.hpp:1266
Definition: map.hpp:338
string
Definition: cgiapp.hpp:687
int64_t Int8
8-byte (64-bit) signed integer
Definition: ncbitype.h:104
#define END_NCBI_SCOPE
End previously defined NCBI scope.
Definition: ncbistl.hpp:103
#define BEGIN_NCBI_SCOPE
Define ncbi namespace.
Definition: ncbistl.hpp:100
#define NCBI_BLAST_EXPORT
Definition: ncbi_export.h:360
E_Choice
Choice variants.
EBlast4_strand_type
Access to EBlast4_strand_type's attributes (values, names) as defined in spec.
@ e_not_set
const TYPE & Get(const CNamedParameterList *param)
EBlastOptIdx
Index of remote BLAST options.
Definition: names.hpp:55
@ eBlastOpt_Web_DBInput
Definition: names.hpp:153
@ eBlastOpt_WordThreshold
Definition: names.hpp:57
@ eBlastOpt_EntrezQuery
Definition: names.hpp:128
@ eBlastOpt_ComplexityAdjMode
Definition: names.hpp:96
@ eBlastOpt_SeedExtensionMethod
Definition: names.hpp:79
@ eBlastOpt_MismatchPenalty
Definition: names.hpp:101
@ eBlastOpt_MaskLevel
Definition: names.hpp:97
@ eBlastOpt_Web_StepNumber
Definition: names.hpp:152
@ eBlastOpt_CompositionBasedStats
Definition: names.hpp:114
@ eBlastOpt_SubjectBestHit
Definition: names.hpp:127
@ eBlastOpt_LookupTableType
Definition: names.hpp:58
@ eBlastOpt_Web_NewWindow
Definition: names.hpp:148
@ eBlastOpt_NegativeTaxidList
Definition: names.hpp:143
@ eBlastOpt_QueryGeneticCode
Definition: names.hpp:76
@ eBlastOpt_DbLength
Definition: names.hpp:106
@ eBlastOpt_Program
Definition: names.hpp:56
@ eBlastOpt_WordSize
Definition: names.hpp:59
@ eBlastOpt_SegFilteringHicut
Definition: names.hpp:72
@ eBlastOpt_HitlistSize
Definition: names.hpp:85
@ eBlastOpt_FilterString
Definition: names.hpp:63
@ eBlastOpt_StrandOption
Definition: names.hpp:75
@ eBlastOpt_RequiredEnd
Definition: names.hpp:139
@ eBlastOpt_QueryCovHspPerc
Definition: names.hpp:92
@ eBlastOpt_GapXDropoffFinal
Definition: names.hpp:82
@ eBlastOpt_DustFilteringLevel
Definition: names.hpp:66
@ eBlastOpt_OutOfFrameMode
Definition: names.hpp:105
@ eBlastOpt_MBTemplateLength
Definition: names.hpp:61
@ eBlastOpt_BestHitOverhang
Definition: names.hpp:122
@ eBlastOpt_CullingLimit
Definition: names.hpp:88
@ eBlastOpt_TaxidList
Definition: names.hpp:142
@ eBlastOpt_XDropoff
Definition: names.hpp:80
@ eBlastOpt_PercentIdentity
Definition: names.hpp:91
@ eBlastOpt_SegFilteringWindow
Definition: names.hpp:70
@ eBlastOpt_UseRealDbSize
Definition: names.hpp:141
@ eBlastOpt_IgnoreMsaMaster
Definition: names.hpp:123
@ eBlastOpt_Culling
Definition: names.hpp:126
@ eBlastOpt_WindowMaskerTaxId
Definition: names.hpp:118
@ eBlastOpt_GapExtensionCost
Definition: names.hpp:103
@ eBlastOpt_Web_EntrezQuery
Definition: names.hpp:146
@ eBlastOpt_GapOpeningCost
Definition: names.hpp:102
@ eBlastOpt_DbFilteringAlgorithmKey
Definition: names.hpp:133
@ eBlastOpt_Web_DBGroup
Definition: names.hpp:154
@ eBlastOpt_WindowSize
Definition: names.hpp:77
@ eBlastOpt_MatrixPath
Definition: names.hpp:99
@ eBlastOpt_MatchReward
Definition: names.hpp:100
@ eBlastOpt_MaskAtHash
Definition: names.hpp:64
@ eBlastOpt_MaxHspsPerSubject
Definition: names.hpp:87
@ eBlastOpt_SmithWatermanMode
Definition: names.hpp:115
@ eBlastOpt_SegFiltering
Definition: names.hpp:69
@ eBlastOpt_GapExtnAlgorithm
Definition: names.hpp:84
@ eBlastOpt_EvalueThreshold
Definition: names.hpp:89
@ eBlastOpt_MatrixTable
Definition: names.hpp:137
@ eBlastOpt_Web_OrganismName
Definition: names.hpp:149
@ eBlastOpt_Web_BlastSpecialPage
Definition: names.hpp:145
@ eBlastOpt_RepeatFilteringDB
Definition: names.hpp:74
@ eBlastOpt_LCaseMask
Definition: names.hpp:136
@ eBlastOpt_MatrixName
Definition: names.hpp:98
@ eBlastOpt_Web_RunPsiBlast
Definition: names.hpp:150
@ eBlastOpt_NegativeGiList
Definition: names.hpp:138
@ eBlastOpt_Web_ExclSeqUncult
Definition: names.hpp:158
@ eBlastOpt_DomainInclusionThreshold
Definition: names.hpp:124
@ eBlastOpt_BestHitScoreEdge
Definition: names.hpp:121
@ eBlastOpt_LongestIntronLength
Definition: names.hpp:94
@ eBlastOpt_HspRangeMax
Definition: names.hpp:135
@ eBlastOpt_DustFilteringLinker
Definition: names.hpp:68
@ eBlastOpt_SeedContainerType
Definition: names.hpp:78
@ eBlastOpt_ForceMbIndex
Definition: names.hpp:119
@ eBlastOpt_Web_ExclModels
Definition: names.hpp:157
@ eBlastOpt_GapTrigger
Definition: names.hpp:83
@ eBlastOpt_DbFilteringAlgorithmId
Definition: names.hpp:132
@ eBlastOpt_FinalDbSeq
Definition: names.hpp:129
@ eBlastOpt_AlphabetSize
Definition: names.hpp:60
@ eBlastOpt_DbSeqNum
Definition: names.hpp:107
@ eBlastOpt_DustFiltering
Definition: names.hpp:65
@ eBlastOpt_DbGeneticCode
Definition: names.hpp:109
@ eBlastOpt_FirstDbSeq
Definition: names.hpp:130
@ eBlastOpt_MaxValue
Definition: names.hpp:159
@ eBlastOpt_RepeatFiltering
Definition: names.hpp:73
@ eBlastOpt_SegFilteringLocut
Definition: names.hpp:71
@ eBlastOpt_MBTemplateType
Definition: names.hpp:62
@ eBlastOpt_Web_ShortQueryAdjust
Definition: names.hpp:151
@ eBlastOpt_GapXDropoff
Definition: names.hpp:81
@ eBlastOpt_GiList
Definition: names.hpp:131
@ eBlastOpt_GappedMode
Definition: names.hpp:95
@ eBlastOpt_PseudoCount
Definition: names.hpp:112
@ eBlastOpt_WindowMaskerDatabase
Definition: names.hpp:117
@ eBlastOpt_EffectiveSearchSpace
Definition: names.hpp:108
@ eBlastOpt_SumStatisticsMode
Definition: names.hpp:93
@ eBlastOpt_RequiredStart
Definition: names.hpp:140
@ eBlastOpt_PHIPattern
Definition: names.hpp:110
@ eBlastOpt_FrameShiftPenalty
Definition: names.hpp:104
@ eBlastOpt_Web_DBSubgroup
Definition: names.hpp:156
@ eBlastOpt_MbIndexName
Definition: names.hpp:120
@ eBlastOpt_MaxNumHspPerSequence
Definition: names.hpp:86
@ eBlastOpt_Web_JobTitle
Definition: names.hpp:147
@ eBlastOpt_GapTracebackAlgorithm
Definition: names.hpp:113
@ eBlastOpt_SubjectMaskingType
Definition: names.hpp:134
@ eBlastOpt_Web_DBSubgroupName
Definition: names.hpp:155
@ eBlastOpt_DustFilteringWindow
Definition: names.hpp:67
@ eBlastOpt_CutoffScore
Definition: names.hpp:90
@ eBlastOpt_InclusionThreshold
Definition: names.hpp:111
@ eBlastOpt_UnifiedP
Definition: names.hpp:116
string Blast4SearchInfo_BuildReplyName(const string &name, const string &value)
This function builds the reply name token in the get-search-info reply objects, provided a pair of st...
Definition: names.cpp:446
const char * kBlast4SearchInfoReqValue_Title
Used to retrieve the BLAST search title.
const char * kBlast4SearchInfoReqValue_Subjects
Used to retrieve the BLAST search subjects.
const char * kBlast4SearchInfoReqValue_PsiIterationNum
Used to retrieve the PSI-BLAST iteration number.
const char * kBlast4SearchInfoReqName_Alignment
Used to retrieve information about the BLAST alignments.
const char * kBlast4SearchInfoReqValue_Status
Used to retrieve the BLAST search status.
const char * kBlast4SearchInfoReqName_Search
Used to retrieve information about the BLAST search.
const GenericPointer< typename T::ValueType > T2 value
Definition: pointer.h:1227
The NCBI C++/STL use hints.
static bool GetInteger(wxSpinCtrl *spinctrl, int *value)
Modified on Tue Jun 18 13:33:49 2024 by modify_doxy.py rev. 669887