Next: Beispiel (forts.)
Up: Objekte, Klassen, Variable, Funktionen,
Previous: Elementfunktionen
Erzeugen Sie die Textdatei Account_DEF.h mit folgendem Inhalt:
class Account {
public:
Account();
float account_balance(void); // return the balance
float withdraw( const float ); // withdraw from account
void deposit( const float ); // deposit into account
private:
float the_balance; // the outstanding balance
};
| © 1997 Gottfried Rudorfer, C++-AG, Lehrveranstaltungen, Abteilung für Angewandte Informatik, Wirtschaftsuniversität Wien, 3/19/1998 |