Set the last name only. Set the first name only. Set the middle name. Check whether a given last name is the same as the last name of this person. Check whether a give first name is the same as the first name of this person. Check whether a given middle name is the same as the middle name of this person. Add the method equals that returns true if two objects contains the same first and last name. Add the method makeCopy that copies the instance of variables of a Person object into another Person object. Add the method getCopy that creates and returns the address of the object, which is a copy of another Person Object. Write the definition of the methods of the class Person to implement the operation of this Class Write a program that tests various operation of the Class Pers

Computer Networking: A Top-Down Approach (7th Edition)
7th Edition
ISBN:9780133594140
Author:James Kurose, Keith Ross
Publisher:James Kurose, Keith Ross
Chapter1: Computer Networks And The Internet
Section: Chapter Questions
Problem R1RQ: What is the difference between a host and an end system? List several different types of end...
icon
Related questions
Question
  1. Read the class Person to store the name a person we discuss in the class (source is Person.java attached in the assignment). As we can see that the methods we included merely set the name and print the name of a person. Redefine the class person so that, in addition to what existing Class does, you can
  • Set the last name only.
  • Set the first name only.
  • Set the middle name.
  • Check whether a given last name is the same as the last name of this person.
  • Check whether a give first name is the same as the first name of this person.
  • Check whether a given middle name is the same as the middle name of this person.
  • Add the method equals that returns true if two objects contains the same first and last name.
  • Add the method makeCopy that copies the instance of variables of a Person object into another Person object.
  • Add the method getCopy that creates and returns the address of the object, which is a copy of another Person Object.
  • Write the definition of the methods of the class Person to implement the operation of this Class
  • Write a program that tests various operation of the Class Person.
Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 3 steps with 1 images

Blurred answer
Recommended textbooks for you
Computer Networking: A Top-Down Approach (7th Edi…
Computer Networking: A Top-Down Approach (7th Edi…
Computer Engineering
ISBN:
9780133594140
Author:
James Kurose, Keith Ross
Publisher:
PEARSON
Computer Organization and Design MIPS Edition, Fi…
Computer Organization and Design MIPS Edition, Fi…
Computer Engineering
ISBN:
9780124077263
Author:
David A. Patterson, John L. Hennessy
Publisher:
Elsevier Science
Network+ Guide to Networks (MindTap Course List)
Network+ Guide to Networks (MindTap Course List)
Computer Engineering
ISBN:
9781337569330
Author:
Jill West, Tamara Dean, Jean Andrews
Publisher:
Cengage Learning
Concepts of Database Management
Concepts of Database Management
Computer Engineering
ISBN:
9781337093422
Author:
Joy L. Starks, Philip J. Pratt, Mary Z. Last
Publisher:
Cengage Learning
Prelude to Programming
Prelude to Programming
Computer Engineering
ISBN:
9780133750423
Author:
VENIT, Stewart
Publisher:
Pearson Education
Sc Business Data Communications and Networking, T…
Sc Business Data Communications and Networking, T…
Computer Engineering
ISBN:
9781119368830
Author:
FITZGERALD
Publisher:
WILEY