Book Shelf
Loading...
Searching...
No Matches
bookfactory.h
Go to the documentation of this file.
1
10#ifndef BOOKFACTORY_H
11#define BOOKFACTORY_H
12
13class Book;
14class QDate;
15class QString;
16
17#include <QStringList>
18
19
25{
26public:
32 static BookFactory &getInstance();
33
43 Book *createBook(const QString &title, const QStringList &authors, const QString &isbn, const QDate &publicationDate);
44
45private:
46 BookFactory(); // Private constructor
47 BookFactory(const BookFactory&) = delete; // Prevent copy-construction
48 BookFactory &operator=(const BookFactory&) = delete; // Prevent assignment
49};
50
51#endif // BOOKFACTORY_H
The BookFactory class is a factory class for creating Book objects.
Definition bookfactory.h:25
Book * createBook(const QString &title, const QStringList &authors, const QString &isbn, const QDate &publicationDate)
Create a Book object.
Definition bookfactory.cpp:22
static BookFactory & getInstance()
Get the Instance object.
Definition bookfactory.cpp:16
The Book class represents a book object.
Definition book.h:23