Changes

Jump to: navigation, search

Project A2 20141 - OOP344

458 bytes added, 11:19, 14 March 2014
Responsibilities: Added child class data storage section
=== Responsibilities ===
CField is responsible for implementing the data setter/getter. As described above, it should have implement the functions:
* void* data() const
* void data(void*)
These functions should do nothing more than get and set an a private void* data member. Child classes should access the data member through the data getter and setter. ==== Child Class Data Storage ====All child classes use some kind of dynamically allocated memory. CLine needs to store a pointer to a dynamically allocated string that it modifies. CLabel and CButton both need to store a pointer to a dynamically allocated string that they display. When implementing these child classes, please use the above data functions to store and retrieve the pointer. '''If you do not, you will crash the a2 tester during some tests!'''
== CLabel ==

Navigation menu