Thread: help needed so i can start my c++ coding..please

  1. #1
    Registered User
    Join Date
    Mar 2012
    Location
    Caribbean
    Posts
    3

    help needed so i can start my c++ coding..please

    BELOW IS QUESTION DESCRIPTION AND THE UML DIAGRAMS THAT I HAVE MANAGED TO COME UP WITH BASED ON MY UNDERSTANDING. CAN SOMEONE PLEASE REVIEW IT AND TELL ME IF THE CLASSES ARE CORRECT PLEASE....

    URGENTLY NEED ASSISTANCE!!!!!!!!!!!

    THANKS!!!!!!!!!!!!!!!!!!!!!


    Make use of inheritance, polymorphism, dynamic-binding, encapsulation, data abstraction, persistence through file handling and defensive programming using exception handling techniques.
    Description
    DigiCel, Lime and Flow currently offer business telephone service, each with its own method of billing for calls, to corporate clients in Jamaica. DigiCel offers prepaid and postpaid fixed unit systems using its cellular telephone network. For its prepaid systems, DigiCel allows the user to add call credit to a DigiCel prepaid telephone number by purchasing call credit cards in denominations of $100, $200, $500 and $1000. Each call credit card has a unique 13-digit card number. To add the call credit, one dials asterisk, one, two, one, asterisk, followed by the 13-digit number followed by the number sign, e.g. *121*123456789012#. If its the first time for the month that credit is being added, a bonus of $100 is also added to the phone number. If its a public holiday, the amount of credit being added is doubled.
    Calls are billed at $10 per minute to other DigiCel phones, and $14 per minute to other telephone networks. When a call is placed, the appropriate amount for each minute is deducted from the telephone number's account until the prepaid call credit is finished or the telephone call is terminated.
    For its postpaid system, DigiCel allows the user to place calls to any number using its postpaid telephone. Calls are billed at $8 per minute to other DigiCel phones, and $12 per minute to other telephone networks. When a call is placed from a DigiCel postpaid telephone, the appropriate amount for the total minutes spent on the call is added to the telephone number's account. At the end of the month, the telephone bill for that telephone number is generated and sent to the customer who then makes a payment to clear the bill.
    All DigiCel fixed unit telephone numbers begin with the prefixes 618, 619, 648 or 649.
    Lime offers prepaid and postpaid fixed unit systems using its cellular telephone network, as well as landline telephones. For its prepaid fixed systems, Lime allows the user to add call credit to a Lime OOP Group Project 2011-2012 Semester Two 1 of 3 prepaid telephone number by purchasing call credit cards in denominations of $100, $200, $500 and $1000. Each call credit card has a unique 12-digit card number. To add the call credit, one dials asterisk, one, two, one, asterisk, followed by the 12-digit number followed by the number sign, e.g
    *121*123456789012#. If it’s the first time for the month that credit is being added, a bonus of $100 is also added to the phone number. If its a public holiday, the amount of credit being added is doubled.
    Calls are billed at $10 per minute to other Lime phones, and $14 per minute to other telephone networks. When a call is placed, the appropriate amount for each minute is deducted from the telephone number's account until the prepaid call credit is finished or the telephone call is terminated.
    For its postpaid system, Lime allows the user to place calls to any number using its postpaid telephone.
    Calls are billed at $8 per minute to other Lime phones, and $12 per minute to other telephone networks.
    When a call is placed from a Lime postpaid telephone, the appropriate amount for the total minutes spent on the call is added to the telephone number's account. At the end of the month, the telephone bill for that telephone number is generated and sent to the customer who then makes a payment to clear the bill.
    All Lime fixed unit telephone numbers begin with the prefixes 210, 310, 312, 313 or 314. Lime landline numbers begin with the prefixes 920, 754, 968, 928 or 927.
    Flow offers prepaid and postpaid fixed unit systems using its cellular telephone network. For its prepaid systems, Flow allows the user to add call credit to a Flow prepaid telephone number by purchasing call credit cards in denominations of $100, $200, $500 and $1000. Each call credit card has a unique 12-digit card number. To add the call credit, one dials asterisk, one, two, one, asterisk, followed by the 12-digit number followed by the number sign, e.g. *121*123456789012#. If it’s the first time for the month that credit is being added, a bonus of $100 is also added to the phone number.
    If it’s a public holiday, the amount of credit being added is doubled. Calls are billed at $10 per minute to other Flow phones, and $14 per minute to other telephone networks. When a call is placed, the appropriate amount for each minute is deducted from the telephone number's account until the prepaid call credit is finished or the telephone call is terminated.
    All Flow fixed unit telephone numbers begin with the prefixes 620, 622, 630, 631, 632 or 633.
    On all telephone networks, calls to designated emergency numbers do not attract a charge. These numbers are Fire – 110, Ambulance 110, Police 119, Crime Stop Air/Sea Rescue – 119, or Office of Disaster Preparedness and Emergency Management – 906-9674.
    ComTech has designed a smart corporate telephone (SCT) system that allows the user to dial a number and it will place the call on the most cost effective network. The system will keep trace of all calls and associated costs each month, and be able to display reports on call activity.
    You have been hired to develop the software for the ComTech SCT, using object oriented design and programming principles.
    Code:
    ________________________________
    Network //(is a){Aggregate}PARENT CLASS
    _________________________________
    - Network : string
    - ServType: string
    - callStart : int
    - callEnd: int
    - maxCallTime:int
    __________________________________
    +setNo ( )
    +type()
    //has code telling name and type
    __________________________________
    ---------------------------------------
    __________________
    Digicel //IS A CHILD OF NETWORK
    __________________
    +setNo(): int
    +type(): string
    __________________
    ----------------------------
    __________________
    Lime //IS A CHILD OF NETWORK
    ___________________
    +setNo(): int
    +type(): string
    ___________________
    ------------------------------
    ___________________
    Flow //IS A CHILD OF NETWORK
    ____________________
    +setNo(): int
    +type(): string
    _____________________
    -------------------------------
    _____________________
    Phone //(many)MAYNOR MAY NOT BE CONTAINED IN NETWORK
    _____________________
    # phoneNo : int
    #network: string
    _____________________
    +makeCall( )
    +endCall( )
    +checkBalance ( )
    _____________________
    --------------------------------
    ________________________
    RandCalc //(dependent)IS A CHILD OF NETWORK
    ________________________
    Generate ( )
    //generates suffix 4 #s
    // generates phonecard
    ________________________
    ----------------------------------
    _____________________
    phoneCall(ONE)//MAY OR MAY NOT BE CONTAINED IN PHONE
    ______________________
    -callId: int
    -startTime: int
    -endTime: int
    _____________________
    +Connect( )
    +getTime( )
    +CalculateCost ( )
    _____________________
    1
    .
    .
    .
    *______________________
    .    Account //(many)MAY OR MAY NOT BE CONTAINED IN NETWORK
    ______________________
    # phoneNo : int
    #network: string
    _______________________
    +CalcCost ( )
    +checkBalance ( )
    ________________________
    
    
    -----------------------------------------------------------------
    
    
    _________________________
    service //{abstract} PARENT CLASS
    _________________________
    # callStart : int
    # callEnd: int
    # maxCallTime:int
    __________________________
    + getService(ch)
    + setNo(): int//getNo
    + type(): string{abstract}
    ___________________________
    ----------------------------------
    ___________________________
    digicel//IS A CHILD OF SERVICE
    ___________________________
    +setNo(): int
    +type(): string
    ___________________________
    -----------------------------------
    ___________________________
    lime//IS A CHILD OF SERVICE
    ___________________________
    +setNo(): int
    +type(): string
    ___________________________
    --------------------------------------
    ___________________________
    flow//IS A CHILD OF SERVICE
    ___________________________
    +setNo(): int
    +type(): string
    ___________________________

  2. #2
    3735928559
    Join Date
    Mar 2008
    Location
    RTP
    Posts
    838
    you certainly dont' come close to handling all the information laid out in your problem statement, so no. as a matter of style, you should not have different type names that differ only in capitalization - the fact that you felt the need to do that should be a red flag that you have not factored the information well.

    ALSO WHY ARE YOU SHOUTING!?!?!?!

  3. #3
    Registered User
    Join Date
    Mar 2012
    Location
    Caribbean
    Posts
    3
    i'm sorry didn't mean for my text to come off as shouting but to mean i need urgent help....u said i didn't interpret the question well so can u help me out as to wat i missed...i know that a CalcBonus method is missing from the parent class....

  4. #4
    3735928559
    Join Date
    Mar 2008
    Location
    RTP
    Posts
    838
    well, for one, what is the distinction between service and network? from what i can understand, and what you put above, i don't see any need to separate them.

    you didn't document how you're going to handle different rates when calling between networks, or what kind of plan a particular phone uses.

  5. #5
    Registered User
    Join Date
    Mar 2012
    Location
    Caribbean
    Posts
    3
    They are the same thing. the bottom one is just a representation without the whole account and phone classes.
    A checknum method should be in place to compare numbers so that if there is a call between networks the rates will be calculated differently. The method called type will tell the particular plan whether postpaid or prepaid. Does what I'm saying make sense?

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Hints needed to start developing for WinCE
    By BrownB in forum Tech Board
    Replies: 0
    Last Post: 05-17-2006, 09:14 AM
  2. return to start coding?
    By talnoy in forum C++ Programming
    Replies: 1
    Last Post: 01-26-2006, 03:48 AM
  3. Coding Problem-Help needed
    By taimurdar in forum C Programming
    Replies: 4
    Last Post: 07-07-2005, 09:47 AM
  4. how to start coding for this ?
    By codomaniac in forum Networking/Device Communication
    Replies: 1
    Last Post: 11-23-2004, 03:40 PM
  5. help with coding...
    By ahming in forum C Programming
    Replies: 6
    Last Post: 04-26-2004, 08:08 AM

Tags for this Thread