academic program class java 1

The AcademicProgram Class

The AcademicProgram class is what is called a super class.

  1. The attributes (use encapsulation)
    1. String name;
    2. int minimumNumberOfCredits;
    3. ArrayList<Course> requiredCourses;
  2. two constructors
    • one complete with all parameters, one for each attribute
    • one with no parameters
      • the default values should be
        • name – blank String (no spaces)
        • minimumNumberOfCredits – 0
        • requiredCourses – a new ArrayList<Course>
  3. a toString() method that will display information about the object
    • you can use the Netbeans automatic builder format
  4. The “get/set” methods
    • no special requirements.

The app Class

Create and display an AcademicProgram object with 3 courses (see below).

name: “Special Studies in Cyber Security”

minimumNumberOfCredits: 9

courses: 3 Course objects

  1. using the default/no parameter constructor
  2. using these values
    1. name – “Cyber”, “100”, “h”
    2. genEd – “IL” (the GenEd object returned with the find method in GenEdData)
    3. description – “Computer Systems Literacy”
    4. credits_min_per_course – 3
    5. credits_max_per_course – 9
    6. credits_maximum – 99
    7. preReq – use the default constructor for CourseName
    1. name – “CYBER”, “262”, “”
    2. genEd – “GS” (the GenEd object returned with the find method in GenEdData)
    3. description – “Cyber-Defense Studio”
    4. credits_min_per_course – 3
    5. credits_max_per_course – 9
    6. credits_maximum – 99
    7. preReq – “Cyber”, “100”, “”

Displaying

  • display the name and minimumNumberOfCredits
  • display each course in a single line
    • use the special string sequence “n” to add a new line to the display

Below a sample output (including part of the necessary code in app)

lab06_new_output.png

 
Do you need a similar assignment done for you from scratch? We have qualified writers to help you. We assure you an A+ quality paper that is free from plagiarism. Order now for an Amazing Discount!
Use Discount Code "Newclient" for a 15% Discount!

NB: We do not resell papers. Upon ordering, we do an original paper exclusively for you.