chore: Add course material
This commit is contained in:
@@ -0,0 +1,19 @@
|
||||
#include <iomanip>
|
||||
#include <iostream>
|
||||
|
||||
#include "CompanyEntry.h"
|
||||
#include "EntryVisitor.h"
|
||||
|
||||
CompanyEntry::CompanyEntry(std::string name, std::string category, std::string phone)
|
||||
: Entry(name), _category(category), _phone(phone) {}
|
||||
|
||||
void CompanyEntry::print(std::string indent) const {
|
||||
|
||||
std::cout << indent << "Company: " << getName() << " <" << _category << "> " << _phone << '\n';
|
||||
}
|
||||
|
||||
std::string CompanyEntry::getPhone() const { return _phone; }
|
||||
|
||||
std::string CompanyEntry::getCategory() const { return _category; }
|
||||
|
||||
void CompanyEntry::accept(EntryVisitor &v) const { v.visit(*this); }
|
||||
Reference in New Issue
Block a user