29 vector<string> lang, genre, subject;
30 int numChars, numWords, numSentences, numDifficultWords;
36 : authorName(
""), authorBirth(0), authorDeath(0),
37 title(
""), lang(), genre(), subject(),
38 numChars(0), numWords(0), numSentences(0), numDifficultWords(0),
39 url(
""), downloads(0) {
42 Book(
const string& authorName,
int authorBirth,
int authorDeath,
43 const string& title,
const vector<string>& lang,
const vector<string>& genre,
44 const vector<string>& subject,
int numChars,
int numWords,
45 int numSentences,
int numDifficultWords,
const string& url,
47 : authorName(authorName), authorBirth(authorBirth), authorDeath(authorDeath),
48 title(title), lang(lang), genre(genre), subject(subject),
49 numChars(numChars), numWords(numWords), numSentences(numSentences), numDifficultWords(numDifficultWords),
50 url(url), downloads(downloads) {
57 this->authorName = authorName;
64 this->authorBirth = authorBirth;
71 this->authorDeath = authorDeath;
84 void setLang(
const vector<string>& lang) {
99 this->subject = subject;
113 this->numChars = numChars;;
120 this->numWords = numWords;
127 this->numSentences = numSentences;
131 return numDifficultWords;
134 this->numDifficultWords = numDifficultWords;
142 this->downloads = downloads;
A Book object, used along with the books data source.
Definition: Book.h:24
void setAuthorBirth(int authorBirth)
Definition: Book.h:63
int getNumWords() const
Definition: Book.h:116
void setSubject(const vector< string > &subject)
Definition: Book.h:98
void setTitle(const string &title)
Definition: Book.h:77
vector< string > getGenre() const
Definition: Book.h:88
void setAuthorDeath(int authorDeath)
Definition: Book.h:70
void setGenre(const vector< string > &genre)
Definition: Book.h:91
string getTitle() const
Definition: Book.h:74
Book(const string &authorName, int authorBirth, int authorDeath, const string &title, const vector< string > &lang, const vector< string > &genre, const vector< string > &subject, int numChars, int numWords, int numSentences, int numDifficultWords, const string &url, int downloads)
Definition: Book.h:42
void setURL(const string &url)
Definition: Book.h:105
void setNumSentences(int numSentences)
Definition: Book.h:126
string getURL() const
Definition: Book.h:102
void setAuthorName(const string &authorName)
Definition: Book.h:56
void setNumDifficultWords(int numDifficultWords)
Definition: Book.h:133
int getNumSentences() const
Definition: Book.h:123
Book()
Definition: Book.h:35
void setDownloads(int downloads)
Definition: Book.h:141
void setLang(const vector< string > &lang)
Definition: Book.h:84
int getAuthorBirth() const
Definition: Book.h:60
int getAuthorDeath() const
Definition: Book.h:67
string getAuthorName() const
Definition: Book.h:53
vector< string > getSubject() const
Definition: Book.h:95
vector< string > getLang() const
Definition: Book.h:81
int getNumDifficultWords() const
Definition: Book.h:130
int getNumChars() const
Definition: Book.h:109
void setNumChars(int numChars)
Definition: Book.h:112
int getDownloads() const
Definition: Book.h:137
void setNumWords(int numWords)
Definition: Book.h:119
Support for drawing Bar charts.
Definition: alltypes.h:4