Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Create a new class called CustomerRecord. This class describes a companys customer and is derived from PersonRecord (below). It contains the following additional fields: customerID

Create a new class called CustomerRecord. This class describes a companys customer and is derived from PersonRecord (below). It contains the following additional fields:

customerID a customer ID (type: String)

creditCardType a credit card type (ex: Visa, MC, Amex, etc.) (type: String)

creditCardNumber a credit card number (type: String)

creditCardDate a credit card date (ex: 12/19) (type: String)

 Create the new class with the above fields, a constructor, and getters and setters. (Use the Generate  capability in IntelliJ IF possible) public class PersonRecord { private PersonName name; private Address address; private PhoneNumber homePhone; private PhoneNumber workPhone; private PhoneNumber cellPhone; // Constructor  public PersonRecord(PersonName name, Address address, PhoneNumber homePhone, PhoneNumber workPhone, PhoneNumber cellPhone) { this.name = name; this.address = address; this.homePhone = homePhone; this.workPhone = workPhone; this.cellPhone = cellPhone; } // Accessors / Mutators  public PersonName getName() { return name; } public void setName(PersonName name) { this.name = name; } public Address getAddress() { return address; } public void setAddress(Address address) { this.address = address; } public PhoneNumber getHomePhone() { return homePhone; } public void setHomePhone(PhoneNumber homePhone) { this.homePhone = homePhone; } public PhoneNumber getWorkPhone() { return workPhone; } public void setWorkPhone(PhoneNumber workPhone) { this.workPhone = workPhone; } public PhoneNumber getCellPhone() { return cellPhone; } public void setCellPhone(PhoneNumber cellPhone) { this.cellPhone = cellPhone; }

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

Databases Organizing Information Digital And Information Literacy

Authors: Greg Roza

1st Edition

1448805929, 978-1448805921

More Books

Students also viewed these Databases questions

Question

What is a cathode ray?

Answered: 1 week ago

Question

10-17 Could Nasty Gal have avoided bankruptcy? Explain your answer.

Answered: 1 week ago

Question

8. Providing support during instruction.

Answered: 1 week ago