NameReaderLocal Class Reference

#include <HashTableGeneric.h>

Inheritance diagram for NameReaderLocal:

Inheritance graph
[legend]
Collaboration diagram for NameReaderLocal:

Collaboration graph
[legend]
List of all members.

Public Member Functions

virtual ~NameReaderLocal ()
virtual const char * getSequenceName (SequenceNumber seqNum) const
virtual void getSequenceName (string &seqName, SequenceNumber seqNum) const
string & lastName ()
virtual void saveSequenceNames (ostream &nameFile)
virtual void loadSequenceNames (istream &nameFile)
virtual SequenceNumber size (void) const
void pop_back (void)

Detailed Description

Definition at line 69 of file HashTableGeneric.h.


Constructor & Destructor Documentation

virtual NameReaderLocal::~NameReaderLocal (  )  [inline, virtual]

Definition at line 72 of file HashTableGeneric.h.

00072 {}


Member Function Documentation

const char * NameReaderLocal::getSequenceName ( SequenceNumber  seqNum  )  const [virtual]

Reimplemented from NameReader.

Definition at line 1042 of file HashTableGeneric.cpp.

References SequenceAdapterWithOverlap::size().

01043 {
01044   //  assert(seqNum<size());
01045   if (seqNum <= size() )
01046   {
01047     return (*this)[seqNum-1].c_str();
01048   } // ~if
01049   return NULL;
01050 
01051 } // ~const char* NameReaderLocal::getSequenceName

Here is the call graph for this function:

void NameReaderLocal::getSequenceName ( string &  seqName,
SequenceNumber  seqNum 
) const [virtual]

Reimplemented from NameReader.

Definition at line 1054 of file HashTableGeneric.cpp.

References SequenceAdapterWithOverlap::size().

01055 {
01056   //  assert(seqNum<size());
01057   if (seqNum <= size() )
01058   {
01059     seqName = (*this)[seqNum-1];
01060     return;
01061   }
01062   seqName = "No sequence name stored for sequence.";
01063 } // ~NameReaderLocal::getSequenceName

Here is the call graph for this function:

string& NameReaderLocal::lastName (  )  [inline]

Definition at line 77 of file HashTableGeneric.h.

Referenced by HashTableTranslated::countWordsAndGetNames(), HashTableGeneric::countWordsAndGetNames(), and loadSequenceNames().

00078   { 
00079     string dummy = "";
00080     push_back(dummy); return back(); 
00081   }

Here is the caller graph for this function:

void NameReaderLocal::saveSequenceNames ( ostream &  nameFile  )  [virtual]

Reimplemented from NameReader.

Definition at line 1080 of file HashTableGeneric.cpp.

01081 {
01082   for ( vector<string>::iterator i = begin() ; 
01083         i != end() ; i ++ )
01084   {
01085     nameFile << *i << endl;
01086   }
01087 } // ~NameReaderLocal::saveSequenceNames( ostream& nameFile )

void NameReaderLocal::loadSequenceNames ( istream &  nameFile  )  [virtual]

Reimplemented from NameReader.

Definition at line 1089 of file HashTableGeneric.cpp.

References lastName(), and pop_back().

01090 {
01091   while( getline( nameFile, lastName() ) );
01092   pop_back();
01093     //    while( getline( nameFile,*(sequenceNames_.back() ) ) )
01094     //   {
01095     //    sequenceNames_.push_back( new string );
01096     //   } // ~while
01097 
01098     //    sequenceNames_.pop_back();
01099 
01100   //    pNameReader->loadSequenceNames( nameFile );
01101 
01102   //    monitoringStream_ << "Loaded in "  
01103   //          << size() 
01104   //          << " sequence names).\n";
01105 
01106 
01107 } // ~NameReaderLocal::loadSequenceNames( istream& inFile )

Here is the call graph for this function:

virtual SequenceNumber NameReaderLocal::size ( void   )  const [inline, virtual]

Reimplemented from NameReader.

Definition at line 85 of file HashTableGeneric.h.

00086   {
00087     return vector<string>::size();
00088   }

void NameReaderLocal::pop_back ( void   )  [inline]

Definition at line 89 of file HashTableGeneric.h.

Referenced by loadSequenceNames().

00090   {
00091     vector<string>::pop_back();
00092   }

Here is the caller graph for this function:


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