1 /* $Id: dust_mask_app.hpp 168046 2009-08-11 18:00:49Z morgulis $ 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: Aleksandr Morgulis 27 * 28 * File Description: 29 * Header file for CDustMaskApplication class. 30 * 31 */ 32 33 #ifndef C_DUST_MASK_APPLICATION_H 34 #define C_DUST_MASK_APPLICATION_H 35 36 #include <corelib/ncbiapp.hpp> 37 38 #include <objmgr/seq_entry_handle.hpp> 39 40 #include <algo/dustmask/symdust.hpp> 41 42 #include <objtools/seqmasks_io/mask_writer.hpp> 43 #include <objtools/seqmasks_io/mask_reader.hpp> 44 45 BEGIN_NCBI_SCOPE 46 47 class CDustMaskApplication : public CNcbiApplication 48 { 49 public: 50 /// Application constructor CDustMaskApplication()51 CDustMaskApplication() { 52 CRef<CVersion> version(new CVersion()); 53 version->SetVersionInfo(1, 0, 0); 54 SetFullVersion(version); 55 } 56 57 static const char * const USAGE_LINE; 58 virtual void Init(void); 59 virtual int Run (void); 60 61 private: 62 CMaskWriter* x_GetWriter(); 63 CMaskReader* x_GetReader(); 64 65 typedef CSymDustMasker duster_type; 66 typedef duster_type::TMaskList::const_iterator it_type; 67 #if 0 68 typedef void (*out_handler_type)( 69 CNcbiOstream *, 70 const objects::CBioseq_Handle &, 71 const duster_type::TMaskList & ); 72 73 static void interval_out_handler( 74 CNcbiOstream * output_stream, 75 const objects::CBioseq_Handle & bsh, 76 const duster_type::TMaskList & res ); 77 static void acclist_out_handler( 78 CNcbiOstream * output_stream, 79 const objects::CBioseq_Handle & bsh, 80 const duster_type::TMaskList & res ); 81 static void fasta_out_handler( 82 CNcbiOstream * output_stream, 83 const objects::CBioseq_Handle & bsh, 84 const duster_type::TMaskList & res ); 85 static void write_normal( 86 CNcbiOstream * output_stream, 87 const objects::CSeqVector & data, 88 TSeqPos & start, TSeqPos & stop ); 89 static void write_lowerc( 90 CNcbiOstream * output_stream, 91 const objects::CSeqVector & data, 92 TSeqPos & start, TSeqPos & stop ); 93 #endif 94 }; 95 96 END_NCBI_SCOPE 97 98 #endif 99