net_blast_reqmega.hpp
上传用户:yhdzpy8989
上传日期:2007-06-13
资源大小:13604k
文件大小:5k
- /*
- * ===========================================================================
- * PRODUCTION $Log: net_blast_reqmega.hpp,v $
- * PRODUCTION Revision 1000.2 2004/04/12 19:27:59 gouriano
- * PRODUCTION PRODUCTION: UPGRADED [CATCHUP_003] Dev-tree R1.6
- * PRODUCTION
- * ===========================================================================
- */
- #ifndef GUI_CORE_ALGO_NET_BLAST___NET_BLAST_REQMEGA__HPP
- #define GUI_CORE_ALGO_NET_BLAST___NET_BLAST_REQMEGA__HPP
- /* $Id: net_blast_reqmega.hpp,v 1000.2 2004/04/12 19:27:59 gouriano Exp $
- * ===========================================================================
- *
- * PUBLIC DOMAIN NOTICE
- * National Center for Biotechnology Information
- *
- * This software/database is a "United States Government Work" under the
- * terms of the United States Copyright Act. It was written as part of
- * the author's official duties as a United States Government employee and
- * thus cannot be copyrighted. This software/database is freely available
- * to the public for use. The National Library of Medicine and the U.S.
- * Government have not placed any restriction on its use or reproduction.
- *
- * Although all reasonable efforts have been taken to ensure the accuracy
- * and reliability of the software and data, the NLM and the U.S.
- * Government do not and cannot warrant the performance or results that
- * may be obtained by using this software or data. The NLM and the U.S.
- * Government disclaim all warranties, express or implied, including
- * warranties of performance, merchantability or fitness for any particular
- * purpose.
- *
- * Please cite the author in any work or product based on this material.
- *
- * ===========================================================================
- *
- * Authors: Clifford Clausen, Michael DiCuccio
- *
- * File Description:
- * CAlgoPlugin_BlastReqn -- passes nucleotide Blast requests to megablast
- */
- #include <gui/core/algo.hpp>
- #include <gui/core/version.hpp>
- #include <objects/seq/Bioseq.hpp>
- #include "net_blast_req_base.hpp"
- BEGIN_NCBI_SCOPE
- class CAlgoPlugin_BlastReqmega : public CAlgorithm<CAlgoPlugin_BlastReqmega>
- , public CNetBlastReq_Base
- {
- public:
- // call RunCommand on base class
- void RunCommand(objects::CPluginMessage& msg);
- // FinalizeArgs() retrieves the list of valid databases and
- // adds a constraint to manage these
- void FinalizeArgs(objects::CPluginMessage& msg);
- // standard info boilerplate
- static void GetInfo(objects::CPluginInfo& info);
- };
- inline
- void CAlgoPlugin_BlastReqmega::FinalizeArgs(objects::CPluginMessage& msg)
- {
- CNetBlastReq_Base::FinalizeArgs(msg);
- }
- inline
- void CAlgoPlugin_BlastReqmega::RunCommand(objects::CPluginMessage& msg)
- {
- CNetBlastReq_Base::RunCommand(msg);
- }
- inline
- void CAlgoPlugin_BlastReqmega::GetInfo(objects::CPluginInfo& info)
- {
- info.Reset();
- // version info macro
- info.SetInfo(CPluginVersion::eMajor, CPluginVersion::eMinor, 0,
- string(__DATE__) + " " + string(__TIME__),
- "CAlgoPlugin_BlastReqmega",
- "Alignments/Net BLAST/Mega BLAST",
- "Find sequences similar to query sequence",
- "");
- // command info
- CPluginCommand& cmd =
- info.SetCommands().AddAlgoCommand(eAlgoCommand_run);
- cmd.AddArgument("nucleotide", "Nucleotide to blast",
- CSeq_loc::GetTypeInfo());
- cmd.SetConstraint("nucleotide",
- ((*CPluginValueConstraint::CreateSeqMol()),
- CSeq_inst::eMol_dna,
- CSeq_inst::eMol_rna,
- CSeq_inst::eMol_na));
- cmd.AddDefaultArgument("subject", "Database for search",
- CPluginArg::eString, "nr");
- cmd.AddDefaultArgument("word", "Word size",
- CPluginArg::eInteger, "16");
- cmd.AddDefaultArgument("expect", "Expect Value",
- CPluginArg::eDouble, "2e4");
- cmd.AddOptionalArgument("query", "Limit by Entrez Query",
- CPluginArg::eString);
- //
- // hidden arguments - internal consumption only
- //
- cmd.AddDefaultArgument("service", "BLAST service",
- CPluginArg::eString, "megablast");
- cmd["service"].SetHidden(true);
- cmd.AddDefaultArgument("prog", "BLAST program",
- CPluginArg::eString, "blastn");
- cmd["prog"].SetHidden(true);
- }
- END_NCBI_SCOPE
- /*
- * ===========================================================================
- * $Log:
- *
- *
- * ===========================================================================
- */
- #endif // GUI_CORE_ALGO_NET_BLAST___NET_BLAST_REQMEGA__HPP