MatchPolicyDNAProtein Class Reference

#include <QueryManager.h>

Inheritance diagram for MatchPolicyDNAProtein:

Inheritance graph
[legend]
Collaboration diagram for MatchPolicyDNAProtein:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 MatchPolicyDNAProtein (HashTablePackedProtein &subjectTable)
virtual void operator() (WordSequence &querySeqFwd, MatchStore &store, MatchAlgorithm &findMatch)

Protected Attributes

HashTablePackedProteinsubjectTable_

Detailed Description

Definition at line 284 of file QueryManager.h.


Constructor & Destructor Documentation

MatchPolicyDNAProtein::MatchPolicyDNAProtein ( HashTablePackedProtein subjectTable  ) 

Definition at line 228 of file QueryManager.cpp.

References MatchPolicy::addMatch_, gMaxBasesPerWord, MatchPolicy::queryWordLength_, and MatchPolicy::subjectTable_.

00228                                          :
00229 MatchPolicy( subjectTable ),
00230 subjectTable_( subjectTable )
00231 {
00232   queryWordLength_ = gMaxBasesPerWord;
00233   subjectTable_.setQueryTranslatedDNA();
00234 
00235   addMatch_ = new MatchAdderCodonProtein(subjectTable_);
00236 
00237 } // ~MatchPolicyDNAProtein::MatchPolicyDNAProtein


Member Function Documentation

void MatchPolicyDNAProtein::operator() ( WordSequence querySeqFwd,
MatchStore store,
MatchAlgorithm findMatch 
) [virtual]

Implements MatchPolicy.

Definition at line 242 of file QueryManager.cpp.

References MatchPolicy::addMatch_, WordSequence::getNumBasesInLast(), HashTableGeneric::getWordLength(), gMaxBasesPerWord, gNumReadingFrames, MatchAdder::link(), MatchPolicy::queryWordLength_, reverseComplement(), MatchAdder::setQueryForward(), MatchAdder::setQueryReverse(), MatchAdder::setQuerySize(), and MatchPolicy::subjectTable_.

00244 {
00245 
00246   addMatch_->link(store);
00247   addMatch_->setQueryForward();
00248 
00249   addMatch_->setQuerySize( ((querySeqFwd.size()-1) * gMaxBasesPerWord )
00250       + querySeqFwd.getNumBasesInLast() );
00251 
00252   WordSequence querySeqRev;
00253   reverseComplement
00254     ( querySeqFwd, querySeqRev, 
00255       queryWordLength_ ); 
00256 
00257   //  cout << "MPDP: doing fwd" << endl;
00258 
00259   addMatch_->setQueryForward();
00260 
00261   findMatch( querySeqFwd, *addMatch_, subjectTable_,
00262              gNumReadingFrames * subjectTable_.getWordLength() ); 
00263 
00264   //  cout << "MPDP: doing rev" << endl;
00265 
00266   addMatch_->setQueryReverse();
00267 
00268   findMatch( querySeqRev, *addMatch_, subjectTable_,
00269              gNumReadingFrames * subjectTable_.getWordLength() );
00270 
00271 
00272 } // ~void MatchPolicyDNAProtein::operator()

Here is the call graph for this function:


Member Data Documentation

HashTablePackedProtein& MatchPolicyDNAProtein::subjectTable_ [protected]

Reimplemented from MatchPolicy.

Definition at line 295 of file QueryManager.h.


The documentation for this class was generated from the following files:
Generated on Fri Dec 21 13:18:39 2007 for ssaha by  doxygen 1.5.2