NCBI C++ ToolKit
Public Member Functions | Private Attributes | Friends | List of all members

Search Toolkit Book for CLocalBlast

Class to perform a BLAST search on local BLAST databases Note that PHI-BLAST can be run using this class also, one only need to configure it as a regular blastp or blastn search and set the pattern in the CBlastOptionsHandle object. More...

#include <algo/blast/api/local_blast.hpp>

+ Inheritance diagram for CLocalBlast:
+ Collaboration diagram for CLocalBlast:

Public Member Functions

 CLocalBlast (CRef< IQueryFactory > query_factory, CRef< CBlastOptionsHandle > opts_handle, const CSearchDatabase &dbinfo)
 Constructor with database description. More...
 
 CLocalBlast (CRef< IQueryFactory > query_factory, CRef< CBlastOptionsHandle > opts_handle, CRef< CLocalDbAdapter > db)
 Constructor with subject adapter (. More...
 
 CLocalBlast (CRef< IQueryFactory > query_factory, CRef< CBlastOptionsHandle > opts_handle, BlastSeqSrc *seqsrc, CRef< IBlastSeqInfoSrc > seqInfoSrc)
 Constructor with database description. More...
 
CRef< CSearchResultSetRun ()
 Executes the search. More...
 
TInterruptFnPtr SetInterruptCallback (TInterruptFnPtr fnptr, void *user_data=NULL)
 Set a function callback to be invoked by the CORE of BLAST to allow interrupting a BLAST search in progress. More...
 
TSearchMessages GetSearchMessages () const
 Retrieve any error/warning messages that occurred during the search. More...
 
Int4 GetNumExtensions ()
 Retrieve the number of extensions performed during the search. More...
 
BlastDiagnosticsGetDiagnostics ()
 Get the diagnostics structure (deep copy, needs to be deleted by caller) More...
 
- Public Member Functions inherited from CObject
 CObject (void)
 Constructor. More...
 
 CObject (const CObject &src)
 Copy constructor. More...
 
virtual ~CObject (void)
 Destructor. More...
 
CObjectoperator= (const CObject &src) THROWS_NONE
 Assignment operator. More...
 
bool CanBeDeleted (void) const THROWS_NONE
 Check if object can be deleted. More...
 
bool IsAllocatedInPool (void) const THROWS_NONE
 Check if object is allocated in memory pool (not system heap) More...
 
bool Referenced (void) const THROWS_NONE
 Check if object is referenced. More...
 
bool ReferencedOnlyOnce (void) const THROWS_NONE
 Check if object is referenced only once. More...
 
void AddReference (void) const
 Add reference to object. More...
 
void RemoveReference (void) const
 Remove reference to object. More...
 
void ReleaseReference (void) const
 Remove reference without deleting object. More...
 
virtual void DoNotDeleteThisObject (void)
 Mark this object as not allocated in heap – do not delete this object. More...
 
virtual void DoDeleteThisObject (void)
 Mark this object as allocated in heap – object can be deleted. More...
 
void * operator new (size_t size)
 Define new operator for memory allocation. More...
 
void * operator new[] (size_t size)
 Define new[] operator for 'array' memory allocation. More...
 
void operator delete (void *ptr)
 Define delete operator for memory deallocation. More...
 
void operator delete[] (void *ptr)
 Define delete[] operator for memory deallocation. More...
 
void * operator new (size_t size, void *place)
 Define new operator. More...
 
void operator delete (void *ptr, void *place)
 Define delete operator. More...
 
void * operator new (size_t size, CObjectMemoryPool *place)
 Define new operator using memory pool. More...
 
void operator delete (void *ptr, CObjectMemoryPool *place)
 Define delete operator. More...
 
virtual void DebugDump (CDebugDumpContext ddc, unsigned int depth) const
 Define method for dumping debug information. More...
 
- Public Member Functions inherited from CDebugDumpable
 CDebugDumpable (void)
 
virtual ~CDebugDumpable (void)
 
void DebugDumpText (ostream &out, const string &bundle, unsigned int depth) const
 
void DebugDumpFormat (CDebugDumpFormatter &ddf, const string &bundle, unsigned int depth) const
 
void DumpToConsole (void) const
 
- Public Member Functions inherited from CThreadable
 CThreadable (void)
 Default ctor. More...
 
virtual ~CThreadable (void)
 Our virtual destructor. More...
 
virtual void SetNumberOfThreads (size_t nthreads)
 Mutator for the number of threads. More...
 
size_t GetNumberOfThreads (void) const
 Accessor for the number of threads to use. More...
 
bool IsMultiThreaded (void) const
 Returns true if more than 1 thread is specified. More...
 

Private Attributes

CRef< IQueryFactorym_QueryFactory
 Query factory from which to obtain the query sequence data. More...
 
CRef< CBlastOptionsm_Opts
 Options to use. More...
 
CRef< SInternalDatam_InternalData
 Internal core data structures which are used in the preliminary and traceback stages of the search. More...
 
CRef< CBlastPrelimSearchm_PrelimSearch
 Object which runs the preliminary stage of the search. More...
 
CRef< CBlastTracebackSearchm_TbackSearch
 Object which runs the traceback stage of the search. More...
 
CRef< CLocalDbAdapterm_LocalDbAdapter
 Local DB adaptor (if one was) passed to constructor. More...
 
CRef< IBlastSeqInfoSrcm_SeqInfoSrc
 User-specified IBlastSeqInfoSrc implementation (may be used for non-standard databases, etc.) More...
 
TSearchMessages m_Messages
 Warnings and error messages. More...
 

Friends

class ::CBlastFilterTest
 
class CBl2Seq
 

Additional Inherited Members

- Public Types inherited from CObject
enum  EAllocFillMode { eAllocFillNone = 1, eAllocFillZero, eAllocFillPattern }
 Control filling of newly allocated memory. More...
 
typedef CObjectCounterLocker TLockerType
 Default locker type for CRef. More...
 
typedef CAtomicCounter TCounter
 Counter type is CAtomiCounter. More...
 
typedef TCounter::TValue TCount
 Alias for value type of counter. More...
 
- Public Types inherited from CThreadable
enum  { kMinNumThreads = 1 }
 Never have less than 1 thread. More...
 
- Static Public Member Functions inherited from CObject
static NCBI_NORETURN void ThrowNullPointerException (void)
 Define method to throw null pointer exception. More...
 
static NCBI_NORETURN void ThrowNullPointerException (const type_info &type)
 
static EAllocFillMode GetAllocFillMode (void)
 
static void SetAllocFillMode (EAllocFillMode mode)
 
static void SetAllocFillMode (const string &value)
 Set mode from configuration parameter value. More...
 
- Static Public Member Functions inherited from CDebugDumpable
static void EnableDebugDump (bool on)
 
- Static Public Attributes inherited from CObject
static const TCount eCounterBitsCanBeDeleted = 1 << 0
 Define possible object states. More...
 
static const TCount eCounterBitsInPlainHeap = 1 << 1
 Heap signature was found. More...
 
static const TCount eCounterBitsPlaceMask
 Mask for 'in heap' state flags. More...
 
static const int eCounterStep = 1 << 2
 Skip over the "in heap" bits. More...
 
static const TCount eCounterValid = TCount(1) << (sizeof(TCount) * 8 - 2)
 Minimal value for valid objects (reference counter is zero) Must be a single bit value. More...
 
static const TCount eCounterStateMask
 Valid object, and object in heap. More...
 
- Protected Member Functions inherited from CObject
virtual void DeleteThis (void)
 Virtual method "deleting" this object. More...
 
- Protected Attributes inherited from CThreadable
size_t m_NumThreads
 Keep track of how many threads should be used. More...
 

Detailed Description

Class to perform a BLAST search on local BLAST databases Note that PHI-BLAST can be run using this class also, one only need to configure it as a regular blastp or blastn search and set the pattern in the CBlastOptionsHandle object.

Definition at line 61 of file local_blast.hpp.

Member Function Documentation

TInterruptFnPtr CLocalBlast::SetInterruptCallback ( TInterruptFnPtr  fnptr,
void *  user_data = NULL 
)
inline

Set a function callback to be invoked by the CORE of BLAST to allow interrupting a BLAST search in progress.

Parameters
fnptrpointer to callback function [in]
user_datauser data to be attached to SBlastProgress structure [in]
Returns
the previously set TInterruptFnPtr (NULL if none was provided before)

Definition at line 100 of file local_blast.hpp.

References _ASSERT.

Referenced by CBlastAligner::GenerateAlignments(), and CBl2Seq::x_InitCLocalBlast().

Friends And Related Function Documentation

friend class ::CBlastFilterTest
friend

Definition at line 142 of file local_blast.hpp.

friend class CBl2Seq
friend

Definition at line 143 of file local_blast.hpp.

Member Data Documentation

CRef<SInternalData> CLocalBlast::m_InternalData
private

Internal core data structures which are used in the preliminary and traceback stages of the search.

Definition at line 124 of file local_blast.hpp.

Referenced by GetDiagnostics(), GetNumExtensions(), Run(), and CBl2Seq::RunEx().

CRef<CLocalDbAdapter> CLocalBlast::m_LocalDbAdapter
private

Local DB adaptor (if one was) passed to constructor.

Definition at line 133 of file local_blast.hpp.

Referenced by Run().

TSearchMessages CLocalBlast::m_Messages
private

Warnings and error messages.

Definition at line 140 of file local_blast.hpp.

Referenced by GetSearchMessages(), and Run().

CRef<CBlastOptions> CLocalBlast::m_Opts
private

Options to use.

Definition at line 120 of file local_blast.hpp.

Referenced by Run().

CRef<CBlastPrelimSearch> CLocalBlast::m_PrelimSearch
private

Object which runs the preliminary stage of the search.

Definition at line 127 of file local_blast.hpp.

Referenced by Run().

CRef<IQueryFactory> CLocalBlast::m_QueryFactory
private

Query factory from which to obtain the query sequence data.

Definition at line 117 of file local_blast.hpp.

Referenced by Run().

CRef<IBlastSeqInfoSrc> CLocalBlast::m_SeqInfoSrc
private

User-specified IBlastSeqInfoSrc implementation (may be used for non-standard databases, etc.)

Definition at line 137 of file local_blast.hpp.

Referenced by Run().

CRef<CBlastTracebackSearch> CLocalBlast::m_TbackSearch
private

Object which runs the traceback stage of the search.

Definition at line 130 of file local_blast.hpp.

Referenced by Run().


The documentation for this class was generated from the following files:
Modified on Sat Apr 22 17:02:35 2017 by modify_doxy.py rev. 533848