Create a program with classes and objects to provide greater flexibility, modularity, and reusability for developing Java applications: Java programing Assignment, UNIKL, Malaysia
University | Universiti Kuala Lumpur (UniKL) |
Subject | Java programing |
Course Outcome to achieve:
CLO 2 — Create a program with classes and objects to provide greater flexibility, modularity, and reusability for developing Java applications
Objective: At the end of the session, students will be able to
- Implement advanced class features; Abstract class, Interfaces
- Differentiate the use of different access modifier
Are You Searching Answer of this Question? Request Malaysian Writers to Write a plagiarism Free Copy for You.
Complete the following steps:
1. Create the Pet Interface. The Pet Interface must satisfy the LAIL diagram above
2. Create the Animal class. The Animal class must satisfy the UML diagram above.
- Declare a protected integer Instance variable called legs which records the number of legS for this animal
- Define a protected constructor that initializes the legs instance variable (use this operator)
- Declare an abstract method Eat()
- Declare a concrete method Walk() that prints out something about how the animals walk (including the number of legs)
3. Create the Spider class
- Define a no-argument constructor that calls the superclass constructor to specify that all spiders have eight legs
- Override the Eat method (write a description of how and what spiders eat)
4. Create the Cat class
- This class must Include a String instance variable to store the name of the pet
- Define a constructor that takes one String parameter that specifies the cat’s name. This constructor must also call the superclass constructor to specify that all cats have four legs
- Implement the Pet interface methods
- Override the Eat method (write a description of how and what cats eat)
- Override the Walk method (write description on how catwalk includes numbers of the leg) • Override the Play method (write description on how to cat play)
5. Create the HelloPet class
- This class must include a String instance variable to store the name of the pet (virtual pet)
- Implement the Pet interface methods
- Override the Play method (write a description on how to play with a virtual pet)
6. Create the Test class
- Add the main method to create and manipulate instances of the classes that you have created previously
Get Solution of this Assessment. Hire Experts to solve this assignment for you Before Deadline.
Get Help By Expert
If you’re looking for a trustworthy writer to do my assignment cheap, then our experts can help. Our professional team of brilliant writers is always available and ready to offer any type of programming assignment assistance as per the university deadlines.
Recent Solved Questions
- UCS422 to demonstrate the ability to investigate security management issues in corporate organizations: CYBERSECURITY FOR NON-COMPUTING SCIENCES Case Study, UiTM, Malaysia
- LAW 3711: Mee Lan left RM 3000 for the maintenance of aged and poor people at Gunung Ledang: Equity & Trusts II Assignment, IIUM, Malaysia
- KT34103: Hand, foot, and mouth disease is a mild, contagious viral infection common in young children. The enteroviruses that cause HFMD: Artificial Intelligence Case Study, UMS, Malaysia
- Super-resolution methods for enhancing Google Maps satellite images. Google map is a great website for us to get satellite images: Research Methods Assignment, UPM, Malaysia
- We are extremely happy and proud to receive “Great Place to Work” certification: managing organisation Case Study, OUM, Malaysia
- provide students with the opportunity to display their understanding of children’s attachment: child development theories Case Study, OUM, Malaysia
- A fire struck out at Kemaman Bitumen Company Sdn Bhd located at Teluk Kalong Industrial Area: Process Safety Management Assignment, UTP, Malaysia
- SBFS1103: The objectives of the assignment are to expose learners to critical thinking, decision-making skills and enhance the learners: Thinking Skills and Problem Solving Essay, OUM, Malaysia
- TEE206/05: Briefly explain the importance of binary number systems in digital electronics: Digital Electronics Assignment, WOU, Malaysia
- Ability to use Proteus Simulation Software to simulate electric circuits and measure electrical quantities: Electronic Assignment, MMU, Malaysia