VersificationMgr::Book Class Reference

#include <versificationmgr.h>

Collaboration diagram for VersificationMgr::Book:
Collaboration graph
[legend]

List of all members.

Classes

class  Private

Public Member Functions

 Book (const char *longName, const char *osisName, const char *prefAbbrev, int chapMax)
 Book (const Book &other)
 Book ()
int getChapterMax () const
const char * getLongName () const
const char * getOSISName () const
const char * getPreferredAbbreviation () const
int getVerseMax (int chapter) const
Bookoperator= (const Book &other)
 ~Book ()

Private Member Functions

void init ()

Private Attributes

unsigned int chapMax
SWBuf longName
SWBuf osisName
Privatep
SWBuf prefAbbrev

Friends

struct BookOffsetLess
class System

Detailed Description

Definition at line 87 of file versificationmgr.h.


Constructor & Destructor Documentation

VersificationMgr::Book::Book (  )  [inline]

Definition at line 108 of file versificationmgr.h.

00108 { init(); }

VersificationMgr::Book::Book ( const Book other  ) 

Definition at line 214 of file versificationmgr.cpp.

00214                                             {
00215     longName = other.longName;
00216     osisName = other.osisName;
00217     prefAbbrev = other.prefAbbrev;
00218     chapMax = other.chapMax;
00219     init();
00220     (*p) = *(other.p);
00221 }

VersificationMgr::Book::Book ( const char *  longName,
const char *  osisName,
const char *  prefAbbrev,
int  chapMax 
) [inline]

Definition at line 111 of file versificationmgr.h.

00111                                                                                               {
00112             this->longName = longName;
00113             this->osisName = osisName;
00114             this->prefAbbrev = prefAbbrev;
00115             this->chapMax = chapMax;
00116             init();
00117         }

VersificationMgr::Book::~Book (  ) 

Definition at line 234 of file versificationmgr.cpp.

00234                             {
00235     delete p;
00236 }


Member Function Documentation

int VersificationMgr::Book::getChapterMax (  )  const [inline]

Definition at line 122 of file versificationmgr.h.

00122 { return chapMax; }

const char* VersificationMgr::Book::getLongName (  )  const [inline]

Definition at line 119 of file versificationmgr.h.

00119 { return longName.c_str(); }

const char* VersificationMgr::Book::getOSISName (  )  const [inline]

Definition at line 120 of file versificationmgr.h.

00120 { return osisName.c_str(); }

const char* VersificationMgr::Book::getPreferredAbbreviation (  )  const [inline]

Definition at line 121 of file versificationmgr.h.

00121 { return prefAbbrev.c_str(); }

int VersificationMgr::Book::getVerseMax ( int  chapter  )  const

Definition at line 239 of file versificationmgr.cpp.

00239                                                        {
00240     chapter--;
00241     return (p && (chapter < (signed int)p->verseMax.size()) && (chapter > -1)) ? p->verseMax[chapter] : -1;
00242 }

void VersificationMgr::Book::init (  )  [private]

Definition at line 125 of file versificationmgr.cpp.

00125                                 {
00126     p = new Private();
00127 }

VersificationMgr::Book & VersificationMgr::Book::operator= ( const Book other  ) 

Definition at line 223 of file versificationmgr.cpp.

00223                                                                         {
00224     longName = other.longName;
00225     osisName = other.osisName;
00226     prefAbbrev = other.prefAbbrev;
00227     chapMax = other.chapMax;
00228     init();
00229     (*p) = *(other.p);
00230     return *this;
00231 }


Friends And Related Function Documentation

friend struct BookOffsetLess [friend]

Definition at line 89 of file versificationmgr.h.

friend class System [friend]

Definition at line 88 of file versificationmgr.h.


Member Data Documentation

unsigned int VersificationMgr::Book::chapMax [private]

Maximum chapters in book

Definition at line 103 of file versificationmgr.h.

book name

Definition at line 94 of file versificationmgr.h.

OSIS Abbreviation

Definition at line 97 of file versificationmgr.h.

Definition at line 90 of file versificationmgr.h.

Preferred Abbreviation

Definition at line 100 of file versificationmgr.h.


The documentation for this class was generated from the following files:

Generated on 18 Mar 2013 for The SWORD Project by  doxygen 1.6.1