// // Listing 1-3: Der "Verbraucher" der Konfigurationsdaten // #include "interface.h" #include "consumer.h" Consumer::Consumer(Interface *config) : configfile(config) { } void Consumer::load() { configfile->open("datei1.lst"); config1 = configfile->read(); config2 = configfile->read(); config3 = configfile->read(); configfile->close(); } void Consumer::process() { config1 += "/fertig"; config2 += "/fertig"; config3 += "/fertig"; } void Consumer::save() { configfile->open("datei1.lst"); configfile->write(config1); configfile->write(config2); configfile->write(config3); configfile->close(); }