Description for class Handphone
1. Constructor initializes the phoneNumber (default value 012345), credit (default value 50) and sms_rate (default value 2.5). It also increment the object_counter each time an object is created.
2. smsEdit() allows us to edit sms text freely up to 160 characters. After completing edit, the composed sms can be stored in the phone memory as message before being sent to the recipient.
3. smsRead()reads received messages from the inbox.
4. Operator>>()allows us to send sms message to intended recipient.However, here we can only specify the recipient by the object name, rather than the phone number. (It can be done but quite complicated. You are welcome to challenge it for extra marks!)
5. getCredit() checks the balance of the credit.
6. getObjCounter()checks the number of existing object.
7. operator+() tops up the credit with specified amount.
Class Smartphone
1. operator>>() allows us to send mms (text image) message to intended recipient. However, here we can only specify the recipient by the object name, rather than the phone number. (It can be done but quite complicated. You are welcome to challenge it for extra marks!). Please create your own interesting and innovative text image.
|---------------------------
|<<<<<<<>>>>>>>
|-----------------------
|*** )| | (***
|** )| | (**
| * )| | (**
Fig. 3. Sample text image
2. mmsRead()displays mms message (text image)
3. mmsEdit()loads text image from file.