Question: Instructions: Begin by creating a new Java project in Eclipse, named according to the lab guidelines - project name should be abc 1 2 3

Instructions:
Begin by creating a new Java project in Eclipse, named according to the lab guidelines - project name should be abc123-lab1, where abc123 is your UTSA ID.
Create the following new Java classes, in the default package:
ComedyClubMember.java
RegularMember.java
VIPMember.java
ComedyClub.java
Place Lab1.java Download Lab1.javaOpen this document with ReadSpeaker docReaderclass in the default package within your project. Lab1.java has a main method and will be the class to run our application. Follow the remaining instructions for each class in this lab in order to get your code to compile - do not change the given class. Note that this code will not compile until you have completed the requirements of this lab. There will be syntax errors until all dependencies (classes and methods) are implemented. Once your code compiles, you will be able to examine the output of your program. The output of your program must match the format of the sample below. This sample is the result of running the Lab1.java class with the given main method.
The Average Laughter Intensity in UTSA Club: 5.33
Comedy Club Name: Alamo Number of Current Members: 3 Club Members:
* Regular Club Member name: Sara Mate, laughterIntensity: 2, Phone Number: Not provided, Membership End Date: 02-29-2024, Discount Coupouns: true
* VIP Club Member name: Dan Gutman, laughterIntensity: 10, Phone Number: 521-098-7667, Free Drinks: 2, Guest Passes: 8
* VIP Club Member name: Norman Fin, laughterIntensity: 1, Phone Number: 521-098-7667, Free Drinks: 2, Guest Passes: 10
More Details:
ComedyClubMember.java
This class will represent a comedy club member, which we will define as having:
name (String): the name of the club member (e.g., Michael Scott)
membershipType (String): the type of membership (e.g., Regular, VIP)
laughterIntensity (int): a measure of how intensely the member laughs during performances
phoneNumber (String): the phone number of the member (e.g.,210-987-6543)
A constructor that initializes all variables
Getters and setters for all variables
A toString() method which returns a String representation of a comedy club member
This class will be abstract, and the RegularMember and VIPMember classes will extend it.
RegularMember.java
This class will represent a regular member, which will be a type of ComedyClubMember and we will define as having:
membershipEndDate (String): the date when the membership ends (e.g.,01-01-2025)
hasDiscountCoupoun (boolean): an indicator to whether the member has discount coupons
A constructor that initializes all instance variables, and any other constructors as needed
Getters and setters for all variables
A toString() method which returns a String representation of a regular member
VIPMember.java
This class will represent a VIPMember object, which will be a type of ComedyClubMember and we will define as having:
numFreeDrinks (int): the number of free drinks the member has
numGuestPasses (int) the number of free guest passes the member has
A constructor that initializes all instance variables, and any other constructors as needed
Getters and setters for all variables
A toString() method which returns a String representation of a VIP member
ComedyClub.java
This class will represent a ComedyClub, defined as having:
A name for the club represented as a String (e.g., UTSA)
An array of ComedyClubMember objects
A constructor that initializes the club name and the club members array
A constructor that initializes the club name and populates the club members array, and any other constructors as needed
An addMemeber() method which takes in a single ComedyClubMember object, adds it to that club, and doesnt return anything. All clubs can contain at most 100 members. Once full, no additional contacts can be added.
A removeMemeber() method which takes in a single ComedyClubMember object and removes it from the club.
Getters and setters for all variables
A toString() method which returns a String representation of a club
Note: This lab is meant to review regular arrays in Java, no other data structure may be used to store the objects required. (No ArrayLists are permitted, for example).
Submitting Your Lab:
When you have finished programming, create a zip file of the project and submit it on Canvas
right-click on your project in Eclipse
Click "Export"
Under "General" choose "Archive File"
Ensure your project name is selected in the top left listing of projects (only the project you need to submit). Ensure all required files are included.
Under "To archive file", select a place to save your file and name your zip file (for labs, follow the abc123-labX.zip convention)
Upload only the zip file to Canvas (here)

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!