Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Question 1 (20 Points) Create a NetBeans project called Question 1. Then create a public class inside questionl package called Author according to the following

image text in transcribed
Question 1 (20 Points) Create a NetBeans project called "Question 1". Then create a public class inside questionl package called Author according to the following information (Make sure to check the UML diagram) Author -name:String -email:String -gender:char +Author(name:String, email:String, gender:char) +getName():String +getEmail):String +setEmail (email:String):void +getGender():char +tostring ):String . Three private instance variables: name (String), email (String), and gender (char of either 'm' or 'f'): - One constructor to initialize the name, email and gender with the given values . Getters and setters: get Name ), getEmail0 and getGender ). There are no setters for name and gender because these attributes cannot be changed. Now in your main method, create the following object from your class to test the Author constructor and call the public methods of the Author class. Override the toString ) to display name, age and gender of the author and show that it works in your test case. Test case

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Big Data Fundamentals Concepts, Drivers & Techniques

Authors: Thomas Erl, Wajid Khattak, Paul Buhler

1st Edition

0134291204, 9780134291208

More Books

Students also viewed these Databases questions

Question

=+c. Does it use short, concise sentences?

Answered: 1 week ago