Laboratory assignments step 3

Objectives for Lab 1-2

After lab 1 (A Text handler), you have enhanced your skills in dynamic management of objects and variables. In connection with this, you have specifically been practicing on file management and C-strings. You have also dealt with necessary pointer operations, and appropriate use of both constructor and destructor.

In lab 2 (A Framework) you’ve got to implement the inheritance mechanism in a small framework based on two specified interface (the abstract base classes IGame and IPlayer). For this purpose, you have created one or more adaptation classes (subclasses) for games that can be plugged into the framework. Also implementing the optional task, that is, a Wrapper class to the supplied CrapGame, will make it easier for you, if wanting to reuse a previously created game.

As introduction to laboratory work on inheritance and polymorphism – study the class diagram and the demo application VehicleRegistry in the zipped project found in the right menu. This completed application demonstrates a small framework with an abstract base class (Vehicle) and its two subclasses (Car and Truck), using polymorphic behavior to implement a simple vehicle registry.

Instructions

Both labs are mandatory to perform. The solutions shall meet the requirements specified in lab instructions and work flawless with test programs or pre-defined files that are supplied with labs (see materials in the right menu).

Welcome to CoursePress

en utav Linnéuniversitets lärplattformar. Som inloggad student kan du kommunicera, hålla koll på dina kurser och mycket mer. Du som är gäst kan nå de flesta kurser och dess innehåll utan att logga in.

Läs mer lärplattformar vid Linnéuniversitetet

Student account

To log in you need a student account at Linnaeus University.

Read more about collecting your account

Log in LNU