473,405 Members | 2,171 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,405 software developers and data experts.

need help on this inheritance problem about phones..

17
hi all.
i am just starting doing this idea of inheritance handphones of oop c++..
but this uml diagram below got some weird symbols like
inbox:string[N*]
mms_inbox:image[N]
what is it?
it sure is not c++..
any guide help to my questions..
below the uml is my handwritten coding from uml to brief c++...
is my coding ok?
can it be compilable?
even i have my doubts looking at how weird the uml is...
Handphone
-phoneNumber:string
-message: string
-credit:double
-sms_rate:double
-inbox:string[N*]
-object_counter:int
+<<constructor>> Handphone(no:string, cr:double, rate:double)
+smsEdit():void
+smsRead():void
+operator>>(recipient:Handphone&):void
+getCredit():double
+getObjCounter():int
+operator+(topUp:double): Handphone



Smartphone
-mms_message:image
-mms_inbox:image[N]
+operator>>(:Smartphone):void
+mmsRead():void
+mmsEdit():void
Fig. 2 Detail UML diagrams

here's my work...any comments ideas or something..i think it's ok..
Expand|Select|Wrap|Line Numbers
  1. class Handphone
  2. {
  3. private:
  4.  
  5. string phoneNumber;
  6. string message;
  7.  
  8. double credit;
  9.  
  10. string[N*] inbox;
  11.  
  12. int object counter;
  13.  
  14.  
  15.  
  16. public:
  17.  
  18. Handphone ( string no, double cr,double rate)
  19.  
  20. void smsEdit();
  21.  
  22. void smsRead();
  23.  
  24.  
  25. }
  26.  
  27.  
  28. Class Smartphone : public Handphone
  29. {
  30. private:
  31.  
  32. image mms_message;
  33. image[N] mms_inbox;
  34. public:
  35.  
  36. void operator>>(Smartphone &s);
  37.  
  38. void mmsRead();
  39.  
  40. void mmsEdit();
  41.  
  42.  
  43.  
  44.  
  45.  
  46. }
Oct 22 '09 #1
0 996

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: Thomas Weholt | last post by:
Hi, Is it at all possible to use python to make apps on cellular/mobile phones, using something like Jython etc. ? Hm ... ?? Thomas
2
by: AIM | last post by:
Error in msvc in building inheritance.obj to build hello.pyd Hello, I am trying to build the boost 1.31.0 sample extension hello.cpp. I can not compile the file inheritance.cpp because the two...
34
by: yensao | last post by:
Hi, I have a hard time to understand difference and similarities between Relational database model and the Object-Oriented model. Can somebody help me with this? Thank you in advance. ...
0
by: Carlos Eduardo Peralta | last post by:
Hello dotnet frineds: I make a decision in the 2001 year: i want to be a dotnet guru. I want to consume all my learning hours just learning this applications plataforms and NOT THE JAVA ONE. ...
22
by: ineedyourluvin1 | last post by:
Hello all! I've been looking for a way to strip characters from strings such as a comma. This would be great for using a comma as a delimiter. I show you what I have right now. ...
22
by: Matthew Louden | last post by:
I want to know why C# doesnt support multiple inheritance? But why we can inherit multiple interfaces instead? I know this is the rule, but I dont understand why. Can anyone give me some concrete...
17
by: Student | last post by:
Hi All, I have an assignment for my Programming language project to create a compiler that takes a C++ file as input and translate it into the C file. Here I have to take care of inheritance and...
5
by: Stefano Peduzzi | last post by:
Hi, I'm building an application where I've defined a custom class Customer. Customer can have many phones (defined by phoneType and phoneNumber). I want to check that a phoneNumber is not already...
0
by: U S Contractors Offering Service A Non-profit | last post by:
Brilliant technology helping those most in need Inbox Reply U S Contractors Offering Service A Non-profit show details 10:37 pm (1 hour ago) Brilliant technology helping those most in need ...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.