20 lines
626 B
C++
20 lines
626 B
C++
#include "Musikinstrument.h"
|
|
#include <iostream>
|
|
using namespace std;
|
|
|
|
Musikinstrument::Musikinstrument() {
|
|
this->name = "Irgendein Musikinstrument";
|
|
cout << "Konstruktor: Musikinstrument()" << endl;
|
|
}
|
|
Musikinstrument::Musikinstrument(string name) {
|
|
this->name = name;
|
|
cout << "Konstruktor: Musikinstrument(string name): " << name << endl;
|
|
}
|
|
Musikinstrument::~Musikinstrument() {
|
|
cout << "Destruktor: ~Musikinstrument : " << name << endl;
|
|
}
|
|
void Musikinstrument::spielen() const {
|
|
cout << "Irgentein Musikinstrument erklingt irgentwie" << endl;
|
|
}
|
|
string Musikinstrument::liefereName() const { return this->name; }
|