CAnnotCompareDS Class Reference

Search Toolkit Book for CAnnotCompareDS

#include <annot_compare_ds.hpp>

Inheritance diagram for CAnnotCompareDS:

Inheritance graph
[legend]
Collaboration diagram for CAnnotCompareDS:

Collaboration graph
[legend]
List of all members.

Detailed Description

CAnnotCompareDS.

Definition at line 60 of file annot_compare_ds.hpp.

IwxTableModel implementation

virtual int GetNumRows () const
 Returns the number of rows in the model.
virtual int GetNumColumns () const
 Returns the number of columns in the model.
virtual wxString GetColumnName (int aColIx) const
 Returns a default name for the column using spreadsheet conventions: A, B, C, .
virtual wxString GetColumnType (int aColIx) const
 Tries to extract actual type from row 0 value if it exists.
virtual wxVariant GetValueAt (int i, int j) const
 DECLARE_EVENT_MAP ()
void x_DeleteAllJobs ()
void x_BackgroundJob (IAppJob *job)
virtual void x_OnAppJobNotification (CEvent *evt)
CRef< objects::CScope > m_Scope
TRows m_Rows
CAppJobDispatcher::TJobID m_ActiveJob
 control of background loading
CEventHandlerm_Listener

Public Types

typedef vector< SRowTRows

Public Member Functions

 CAnnotCompareDS ()
 CAnnotCompareDS (objects::CScope &scope)
void Clear ()
objects::CScope & GetScope () const
const TRowsGetData () const
size_t GetRows (void) const
const SRowGetRow (size_t row_idx) const
void DumpTextReport (CNcbiOstream &ostr) const
 dump a text report of the comparisons
void RegisterListener (CEventHandler *listener)
 register a listener to respond to background job completion events
void OnAJNotification (CEvent *evt)
 handle background job completion events
float GetProgress () const
 return progress indicator
void Update ()

Classes

struct  SRow


Member Typedef Documentation

typedef vector<SRow> CAnnotCompareDS::TRows
 

Definition at line 95 of file annot_compare_ds.hpp.


Constructor & Destructor Documentation

CAnnotCompareDS::CAnnotCompareDS  )  [inline]
 

Definition at line 98 of file annot_compare_ds.hpp.

CAnnotCompareDS::CAnnotCompareDS objects::CScope &  scope  ) 
 


Member Function Documentation

void CAnnotCompareDS::Clear  ) 
 

Definition at line 91 of file annot_compare_ds.cpp.

References m_Rows, and x_DeleteAllJobs().

Referenced by CAnnotCompare_LocationDS::Update(), and CAnnotCompare_AlignDS::Update().

CAnnotCompareDS::DECLARE_EVENT_MAP  )  [protected]
 

void CAnnotCompareDS::DumpTextReport CNcbiOstream ostr  )  const
 

dump a text report of the comparisons

keep sets of statistics

count of identical locations

count of identical sequences (genomic)

count of identical products

count of identical loc + seq

count of identical loc + prod

count of identical seq + prod

count of identical loc + seq + prod

counts of feature subtypes with match counts

first set: comparison

register counts per feature type

keep a count per subtype of the features present

note features not found

note counts per feature subtype, with emphasis on particular feature subtypes

first, dump a stat on total comparisons for this feature type

ostr << iter->first; if (it->second != 1) { ostr << "s"; } ostr << " ";

Definition at line 104 of file annot_compare_ds.cpp.

References _ASSERT, CLabel::eDefault, CAnnotCompare::eLocation_3PrimeExtension, CAnnotCompare::eLocation_3PrimeExtraExon, CAnnotCompare::eLocation_5PrimeExtension, CAnnotCompare::eLocation_5PrimeExtraExon, CAnnotCompare::eLocation_Complex, CAnnotCompare::eLocation_DifferentStrand, CAnnotCompare::eLocation_Missing, CAnnotCompare::eLocation_MissingExon, CAnnotCompare::eLocation_Overlap, CAnnotCompare::eLocation_RegionOverlap, CAnnotCompare::eLocation_Same, CAnnotCompare::eLocation_Subset, CAnnotCompare::eLocationMask, CAnnotCompare::eSequence_SameProduct, CAnnotCompare::eSequence_SameSeq, CAnnotCompare::eSequenceMask, CSeq_feat_Base::GetData(), CLabel::GetLabel(), CSeq_id_Handle::GetSeqId(), ITERATE, m_Rows, and m_Scope.

virtual wxString CAnnotCompareDS::GetColumnName int  aColIx  )  const [inline, virtual]
 

Returns a default name for the column using spreadsheet conventions: A, B, C, .

.. Z, AA, AB, etc. If column cannot be found, returns an empty name. AnyType has a type of string.

There is one static instance of string inside, so it is refilled every next call. It is enough for drawing purposes, but if someone needs more, (s)he should implement more.

Reimplemented from CwxAbstractTableModel.

Definition at line 134 of file annot_compare_ds.hpp.

virtual wxString CAnnotCompareDS::GetColumnType int  aColIx  )  const [inline, virtual]
 

Tries to extract actual type from row 0 value if it exists.

Otherwise returns typeid(int) [anyway it is of no use in abcence of data]

Reimplemented from CwxAbstractTableModel.

Definition at line 136 of file annot_compare_ds.hpp.

const CAnnotCompareDS::TRows & CAnnotCompareDS::GetData  )  const
 

Definition at line 426 of file annot_compare_ds.cpp.

References m_Rows.

virtual int CAnnotCompareDS::GetNumColumns  )  const [inline, virtual]
 

Returns the number of columns in the model.

A CTableControl uses this method to determine how many columns it should create and display by default.

Implements CwxAbstractTableModel.

Definition at line 132 of file annot_compare_ds.hpp.

virtual int CAnnotCompareDS::GetNumRows  )  const [inline, virtual]
 

Returns the number of rows in the model.

A CTableControl uses this method to determine how many rows it should display. This method should be quick, as it is called frequently during rendering.

Implements CwxAbstractTableModel.

Definition at line 130 of file annot_compare_ds.hpp.

float CAnnotCompareDS::GetProgress  )  const
 

return progress indicator

Definition at line 84 of file annot_compare_ds.cpp.

References CAppJobDispatcher::GetInstance(), CAppJobDispatcher::GetJobProgress(), and m_ActiveJob.

const CAnnotCompareDS::SRow & CAnnotCompareDS::GetRow size_t  row_idx  )  const
 

Definition at line 438 of file annot_compare_ds.cpp.

References _ASSERT, and m_Rows.

size_t CAnnotCompareDS::GetRows void   )  const
 

Definition at line 432 of file annot_compare_ds.cpp.

References m_Rows.

CScope & CAnnotCompareDS::GetScope  )  const
 

Definition at line 420 of file annot_compare_ds.cpp.

References m_Scope.

virtual wxVariant CAnnotCompareDS::GetValueAt int  i,
int  j
const [inline, virtual]
 

Implements CwxAbstractTableModel.

Definition at line 138 of file annot_compare_ds.hpp.

void CAnnotCompareDS::OnAJNotification CEvent evt  ) 
 

handle background job completion events

void CAnnotCompareDS::RegisterListener CEventHandler listener  ) 
 

register a listener to respond to background job completion events

Definition at line 98 of file annot_compare_ds.cpp.

References m_Listener.

void CAnnotCompareDS::Update  )  [inline]
 

Reimplemented in CAnnotCompare_AlignDS, and CAnnotCompare_LocationDS.

Definition at line 122 of file annot_compare_ds.hpp.

Referenced by CAnnotCompareWidget::Update().

void CAnnotCompareDS::x_BackgroundJob IAppJob job  )  [protected]
 

Definition at line 331 of file annot_compare_ds.cpp.

References CAppJobDispatcher::GetInstance(), LOG_POST, m_ActiveJob, and CAppJobDispatcher::StartJob().

Referenced by CAnnotCompare_LocationDS::Update(), and CAnnotCompare_AlignDS::Update().

void CAnnotCompareDS::x_DeleteAllJobs  )  [protected]
 

this is fine - job probably already finished

Definition at line 345 of file annot_compare_ds.cpp.

References CAppJobDispatcher::DeleteJob(), CAppJobException::eEngine_UnknownJob, CAppJobException::eUnknownJob, CAppJobDispatcher::GetInstance(), LOG_POST, and m_ActiveJob.

Referenced by Clear().

void CAnnotCompareDS::x_OnAppJobNotification CEvent evt  )  [protected, virtual]
 

Definition at line 381 of file annot_compare_ds.cpp.

References _ASSERT, IAppJob::eCompleted, CEventHandler::ePool_Parent, CViewEvent::eWidgetDataChanged, CAppJobNotification::GetJobID(), CAppJobNotification::GetResult(), CAppJobNotification::GetState(), m_ActiveJob, CFeatCompare_Result::m_Rows, m_Rows, and CEventHandler::Send().


Member Data Documentation

CAppJobDispatcher::TJobID CAnnotCompareDS::m_ActiveJob [protected]
 

control of background loading

Definition at line 148 of file annot_compare_ds.hpp.

Referenced by GetProgress(), x_BackgroundJob(), x_DeleteAllJobs(), and x_OnAppJobNotification().

CEventHandler* CAnnotCompareDS::m_Listener [protected]
 

Definition at line 149 of file annot_compare_ds.hpp.

Referenced by RegisterListener().

TRows CAnnotCompareDS::m_Rows [protected]
 

Definition at line 145 of file annot_compare_ds.hpp.

Referenced by Clear(), DumpTextReport(), GetData(), GetRow(), GetRows(), and x_OnAppJobNotification().

CRef<objects::CScope> CAnnotCompareDS::m_Scope [mutable, protected]
 

Definition at line 143 of file annot_compare_ds.hpp.

Referenced by DumpTextReport(), and GetScope().


The documentation for this class was generated from the following files:
Generated on Wed Dec 9 07:49:50 2009 for NCBI C++ ToolKit by  doxygen 1.4.6
Modified on Wed Dec 09 08:18:49 2009 by modify_doxy.py rev. 173732