& service,
51 boolignore_unsupported_options)
52: m_Program (program),
54m_PerformCulling (
false),
57m_Locality (locality),
58m_IgnoreUnsupportedOptions(ignore_unsupported_options),
59m_ForceMbIndex (
false)
65 const string& service)
79 if(s ==
"rpsblast") {
82}
else if(s ==
"psi") {
85}
else if(s ==
"phi") {
88}
else if(s ==
"delta_blast") {
92 else if(s ==
"indexed") {
95}
else if(p ==
"blastn") {
96 if(s ==
"megablast") {
100 if(s ==
"vecscreen") {
104 if((s ==
"sra") || (s ==
"wgs") || (s==
"indexed")) {
107}
else if(p ==
"tblastn") {
108 if(s ==
"rpsblast") {
111}
else if(s ==
"psi") {
115 if((s ==
"sra") || (s ==
"wgs")) {
118}
else if(p ==
"tblastx") {
120}
else if(p ==
"blastx") {
121 if(s ==
"rpsblast") {
127 if(!found && !(s==
"plain"|| s==
"multi_blast")) {
128 string msg=
"Unsupported combination of program (";
130 msg+=
") and service (";
142objects::CBlast4_parameter & p)
153 if(! p.CanGetName() || p.GetName().empty()) {
156 "Option has no name.");
159 stringnm = p.GetName();
225|| p.GetName() ==
"EvalueThreshold") {
231 string msg=
"EvalueThreshold has unsupported type.";
259 #ifdef NCBI_STRICT_GI 262 ITERATE( list<int>, it, int_list ) {
267 #elif defined(NCBI_INT8_GI) 274 ITERATE( list<int>, it, int_list ) {
377 #ifdef NCBI_STRICT_GI 380 ITERATE( list<int>, it, int_list ) {
385 #elif defined(NCBI_INT8_GI) 392 ITERATE( list<int>, it, int_list ) {
403 #ifdef NCBI_STRICT_TAX_ID 405list<TTaxId> taxid_list;
406 ITERATE(list<int>, it, int_list) {
483 #ifdef NCBI_STRICT_TAX_ID 485list<TTaxId> taxid_list;
486 ITERATE(list<int>, it, int_list) {
535 string msg=
"Internal: Error processing option [";
542eServiceNotAvailable,
588 const string& program_string)
595 if(find_if(L->begin(), L->end(),
600 _TRACE(
"Adjusting program to phiblastn");
605 _TRACE(
"Adjusting program to phiblastp");
610 string msg=
"Incorrect combination of option (";
612 msg+=
") and program (";
613 msg+= program_string;
617eServiceNotAvailable,
630 _TRACE(
"Adjusting program to discontiguous Megablast");
639 _TRACE(
"Adjusting program to psiblast");
651 constobjects::CBlast4_parameters* popts,
652 constobjects::CBlast4_parameters* fopts,
653objects::CBlast4_parameters& retval)
655retval.Set().clear();
657retval.Set().insert(retval.Set().end(), aopts->Get().begin(), aopts->Get().end());
660retval.Set().insert(retval.Set().end(), popts->Get().begin(), popts->Get().end());
663retval.Set().insert(retval.Set().end(), fopts->Get().begin(), fopts->Get().end());
669 constobjects::CBlast4_parameters * popts,
670 constobjects::CBlast4_parameters* fopts,
674objects::CBlast4_parameters all_params;
683 if(task_name !=
NULL)
ESubjectMaskingType
Define the possible subject masking types.
EBlastPrelimGapExt
The algorithm to be used for preliminary gapped extensions.
EBlastTbackExt
The algorithm to be used for final gapped extensions with traceback.
Declares the CBlastOptionsBuilder class.
Boolean Blast_QueryIsNucleotide(EBlastProgramType p)
Returns true if the query is nucleotide.
EProgram
This enumeration is to evolve into a task/program specific list that specifies sets of default parame...
@ eBlastn
Nucl-Nucl (traditional blastn)
@ ePHIBlastn
Nucleotide PHI BLAST.
@ eBlastp
Protein-Protein.
@ ePHIBlastp
Protein PHI BLAST.
@ eDiscMegablast
Nucl-Nucl using discontiguous megablast.
Field properties for options in a Blast4 parameter list.
bool Match(const CBlast4_parameter &p) const
Match field name and type to parameter.
const string & GetName() const
Get field name (key).
static CBlast4Field & Get(EBlastOptIdx opt)
Defines BLAST error codes (user errors included)
Class to build CBlastOptionsHandle from blast4 ASN objects.
Handle to the options to the BLAST algorithm.
Encapsulates ALL the BLAST algorithm's options.
Exception class for the CRemoteBlast class.
ECompoAdjustModes
An collection of constants that specify all permissible modes of composition adjustment.
void SetPHIPattern(const char *pattern, bool is_dna)
int GetFirstDbSeq()
Get the OID range start point.
int m_HspRangeMax
How much culling to do.
void SetInclusionThreshold(double u)
void SetCompositionBasedStats(ECompoAdjustModes mode)
SOptional< int > m_DbFilteringAlgorithmId
The GI list (or none).
string m_Service
Service value for blast4 protocol.
void SetEvalueThreshold(double eval)
Sets EvalueThreshold.
void SetStrandOption(objects::ENa_strand s)
SOptional< list< TTaxId > > m_TaxidList
The tax id list (or none).
SOptional< string > m_EntrezQuery
The entreq query to use (or none).
void SetPseudoCount(int u)
SOptional< string > m_DbFilteringAlgorithmKey
bool HaveFirstDbSeq()
Check whether an OID range start point is specified.
void x_ProcessOneOption(CBlastOptionsHandle &opts, objects::CBlast4_parameter &p)
Apply the value of one option to the CBlastOptionsHandle.
objects::CBlast4_parameters::Tdata TValueList
List of name/value pairs.
int GetDbFilteringAlgorithmId()
Get the database filtering algorithm ID.
void SetQueryCovHspPerc(double p)
Sets QueryCovHspPerc.
void x_ProcessOptions(CBlastOptionsHandle &opts, const TValueList *L)
Apply the value of all options to the CBlastOptionsHandle.
void SetDbLength(Int8 len)
Sets DbLength.
SOptional< list< TGi > > m_NegativeGiList
The negative GI list (or none).
TSeqRange m_QueryRange
The range to restrict the query sequence(s)
void SetGapExtnAlgorithm(EBlastPrelimGapExt a)
void SetWindowMaskerTaxId(int taxid)
Sets the tax id to select an appropriate windowmasker database Conversion algorithm from tax id to da...
bool HaveNegativeTaxidList()
Check whether a negative tax id list is specified.
void SetOutOfFrameMode(bool m=true)
void SetDomainInclusionThreshold(double th)
SOptional< int > m_FirstDbSeq
The first OID to process (or none).
void SetDustFilteringLinker(int m)
static EProgram ComputeProgram(const string &program, const string &service)
Compute the EProgram value to use for this search.
void SetSegFilteringHicut(double m)
list< TGi > GetNegativeGiList()
Get the negative GI list.
void SetGapOpeningCost(int g)
ESubjectMaskingType GetSubjectMaskingType()
void SetQueryGeneticCode(int gc)
void SetEffectiveSearchSpace(Int8 eff)
Sets EffectiveSearchSpace.
void SetRepeatFilteringDB(const char *db)
Sets the repeat filtering database to use.
void SetGapTracebackAlgorithm(EBlastTbackExt a)
void SetIgnoreMsaMaster(bool val)
static CBlastOptionsHandle * Create(EProgram program, EAPILocality locality=CBlastOptions::eLocal)
Creates an options handle object configured with default options for the requested program,...
void SetWordThreshold(double w)
Sets WordThreshold.
bool HaveGiList()
Check whether a GI list is specified.
CBlastOptions & SetOptions()
Returns a reference to the internal options class which this object is a handle for.
void SetGapExtensionCost(int e)
SOptional< list< TGi > > m_GiList
The GI list (or none).
static void s_MergeCBlast4_parameters(const objects::CBlast4_parameters *aopts, const objects::CBlast4_parameters *popts, const objects::CBlast4_parameters *fopts, objects::CBlast4_parameters &retval)
Convenience function to merge all lists into one object to facilitate invoking AdjustProgram.
void SetSumStatisticsMode(bool m=true)
void SetUnifiedP(int u=0)
list< TTaxId > GetTaxidList()
Get the Tax list.
SOptional< ESubjectMaskingType > m_SubjectMaskingType
void SetUseIndex(bool use_index=true, const string &index_name="", bool force_index=false, bool old_style_index=false)
void SetDustFilteringWindow(int m)
void SetMismatchPenalty(int p)
bool HaveEntrezQuery()
Check whether an Entrez query is specified.
void SetGapXDropoffFinal(double x)
bool m_ForceMbIndex
Should loading of the megablast BLAST DB index be required?
list< TTaxId > GetNegativeTaxidList()
Get the negative tax id list.
TMaskList GetQueryMasks()
Get the query masks.
void SetMatrixName(const char *matrix)
EBlastProgramType GetProgramType() const
Returns the CORE BLAST notion of program type.
static EProgram AdjustProgram(const TValueList *L, EProgram program, const string &program_string)
Adjust the EProgram based on option values.
void SetHitlistSize(int s)
Sets HitlistSize.
bool HasDbFilteringAlgorithmKey()
Check whether a database filtering algorithm key is specified.
void SetBestHitOverhang(double overhang)
void SetGapXDropoff(double x)
SOptional< int > m_FinalDbSeq
The last OID to process (or none).
CBlastOptions::EAPILocality m_Locality
API Locality of resulting options.
void SetWindowSize(int ws)
Sets WindowSize.
int GetFinalDbSeq()
Get the OID range end point.
void SetSegFilteringLocut(double m)
list< TGi > GetGiList()
Get the GI list.
string EProgramToTaskName(EProgram p)
Convert a EProgram enumeration value to a task name (as those used in the BLAST command line binaries...
bool HasSubjectMaskingType()
Get Subject Maksing Type (soft/hard)
void SetIgnoreUnsupportedOptions(bool ignore)
Set the 'ignore unsupported options' flag.
SBlast4ParamFinder(EBlastOptIdx opt_idx)
T & GetRef()
Get the reference to the stored value.
CBlast4Field & m_Target2Find
bool m_IgnoreQueryMasks
Indicated that query masks have already been collected.
string m_Program
Program value for blast4 protocol.
void SetMBTemplateType(unsigned char type)
SOptional< TMaskList > m_QueryMasks
The query masking locations.
void SetGapTrigger(double g)
void SetDbGeneticCode(int gc)
void SetMBTemplateLength(unsigned char len)
void SetFilterString(const char *f, bool clear=true)
Sets FilterString.
CRef< CBlastOptionsHandle > GetSearchOptions(const objects::CBlast4_parameters *aopts, const objects::CBlast4_parameters *popts, const objects::CBlast4_parameters *fopts, string *task_name=NULL)
Build and return options as a CBlastOptionsHandle.
list< CRef< objects::CBlast4_mask > > TMaskList
List of Blast4 masks.
void SetMaskAtHash(bool val=true)
void SetBestHitScoreEdge(double score_edge)
void SetDustFilteringLevel(int m)
bool HaveNegativeGiList()
Check whether a negative GI list is specified.
EProgram ProgramNameToEnum(const std::string &program_name)
Map a string into an element of the ncbi::blast::EProgram enumeration (except eBlastProgramMax).
void SetDustFiltering(bool val=true)
void SetSegFiltering(bool val=true)
string m_MbIndexName
Which megablast BLAST DB index name to load.
void SetSegFilteringWindow(int m)
void x_ApplyInteractions(CBlastOptionsHandle &boh)
Apply values directly to BlastOptions object.
void SetGappedMode(bool m=true)
Sets GappedMode.
string GetEntrezQuery()
Get the Entrez query.
SOptional< list< TTaxId > > m_NegativeTaxidList
The negative tax id list (or none).
void SetPercentIdentity(double p)
Sets PercentIdentity.
void SetCutoffScore(int s)
Sets CutoffScore.
void SetSmithWatermanMode(bool m=true)
string GetDbFilteringAlgorithmKey()
Get the database filtering algorithm key.
bool operator()(const CRef< CBlast4_parameter > &rhs)
void SetLongestIntronLength(int l)
for linking HSPs with uneven gaps
bool m_PerformCulling
Whether to perform culling.
bool HasDbFilteringAlgorithmId()
Check whether a database filtering algorithm ID is specified.
bool HaveQueryMasks()
Check whether query masks are specified.
void SetMaxHspsPerSubject(int m)
void SetCullingLimit(int s)
bool m_IgnoreUnsupportedOptions
Should this class quietly ignore unsupported options.
bool Have()
Check whether the value has been set.
bool HaveFinalDbSeq()
Check whether an OID range end point is specified.
void SetRepeatFiltering(bool val=true)
Turns on repeat filtering using the default repeat database, namely kDefaultRepeatFilterDb.
void SetMatchReward(int r)
#define GI_FROM(T, value)
#define ITERATE(Type, Var, Cont)
ITERATE macro to sequence through container elements.
#define TAX_ID_FROM(T, value)
#define NCBI_THROW(exception_class, err_code, message)
Generic macro to throw an exception, given the exception class, error code and message string.
bool NotEmpty(void) const THROWS_NONE
Check if CRef is not empty â pointing to an object and has a non-null value.
uint32_t Uint4
4-byte (32-bit) unsigned integer
TThisType & SetToOpen(position_type toOpen)
#define END_NCBI_SCOPE
End previously defined NCBI scope.
#define USING_SCOPE(ns)
Use the specified namespace.
#define END_SCOPE(ns)
End the previously defined scope.
#define BEGIN_NCBI_SCOPE
Define ncbi namespace.
#define BEGIN_SCOPE(ns)
Define a new scope.
static string IntToString(int value, TNumToStringFlags flags=0, int base=10)
Convert int to string.
static string & ToLower(string &str)
Convert string to lower case â string& version.
TBig_integer GetBig_integer(void) const
Get the variant data.
const TCutoff & GetCutoff(void) const
Get the variant data.
bool IsQuery_mask(void) const
Check if variant Query_mask is selected.
TInteger GetInteger(void) const
Get the variant data.
const TValue & GetValue(void) const
Get the Value member data.
TBoolean GetBoolean(void) const
Get the variant data.
bool IsBig_integer_list(void) const
Check if variant Big_integer_list is selected.
E_Choice Which(void) const
Which variant is currently selected.
const TBig_integer_list & GetBig_integer_list(void) const
Get the variant data.
const TString & GetString(void) const
Get the variant data.
TReal GetReal(void) const
Get the variant data.
const TInteger_list & GetInteger_list(void) const
Get the variant data.
bool IsCutoff(void) const
Check if variant Cutoff is selected.
const TQuery_mask & GetQuery_mask(void) const
Get the variant data.
bool IsE_value(void) const
Check if variant E_value is selected.
TStrand_type GetStrand_type(void) const
Get the variant data.
TE_value GetE_value(void) const
Get the variant data.
bool IsReal(void) const
Check if variant Real is selected.
void SetFrom(TFrom value)
Assign a value to From data member.
ENa_strand
strand of nucleic acid
const TYPE & Get(const CNamedParameterList *param)
EBlastOptIdx
Index of remote BLAST options.
@ eBlastOpt_WordThreshold
@ eBlastOpt_MismatchPenalty
@ eBlastOpt_Web_StepNumber
@ eBlastOpt_CompositionBasedStats
@ eBlastOpt_SubjectBestHit
@ eBlastOpt_NegativeTaxidList
@ eBlastOpt_QueryGeneticCode
@ eBlastOpt_SegFilteringHicut
@ eBlastOpt_QueryCovHspPerc
@ eBlastOpt_GapXDropoffFinal
@ eBlastOpt_DustFilteringLevel
@ eBlastOpt_OutOfFrameMode
@ eBlastOpt_MBTemplateLength
@ eBlastOpt_BestHitOverhang
@ eBlastOpt_PercentIdentity
@ eBlastOpt_SegFilteringWindow
@ eBlastOpt_IgnoreMsaMaster
@ eBlastOpt_WindowMaskerTaxId
@ eBlastOpt_GapExtensionCost
@ eBlastOpt_GapOpeningCost
@ eBlastOpt_DbFilteringAlgorithmKey
@ eBlastOpt_MaxHspsPerSubject
@ eBlastOpt_SmithWatermanMode
@ eBlastOpt_GapExtnAlgorithm
@ eBlastOpt_EvalueThreshold
@ eBlastOpt_RepeatFilteringDB
@ eBlastOpt_Web_RunPsiBlast
@ eBlastOpt_NegativeGiList
@ eBlastOpt_DomainInclusionThreshold
@ eBlastOpt_BestHitScoreEdge
@ eBlastOpt_LongestIntronLength
@ eBlastOpt_DustFilteringLinker
@ eBlastOpt_DbFilteringAlgorithmId
@ eBlastOpt_DustFiltering
@ eBlastOpt_DbGeneticCode
@ eBlastOpt_RepeatFiltering
@ eBlastOpt_SegFilteringLocut
@ eBlastOpt_MBTemplateType
@ eBlastOpt_EffectiveSearchSpace
@ eBlastOpt_SumStatisticsMode
@ eBlastOpt_RequiredStart
@ eBlastOpt_GapTracebackAlgorithm
@ eBlastOpt_SubjectMaskingType
@ eBlastOpt_DustFilteringWindow
@ eBlastOpt_InclusionThreshold
Declares the CRemoteBlast class.
static SLJIT_INLINE sljit_ins msg(sljit_gpr r, sljit_s32 d, sljit_gpr x, sljit_gpr b)
Finder class for matching CBlast4_parameter.
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4