Design a class named Pet which should have the following fields:The Pet class should also have the following methods:Once you have designed the class design a program that creates an object of the class and prompts the user to enter the name type and age of his pet. This data should be stored in the object. Use the objects accessor methods to retrieve the pets name type and age and display this data on the screen.You are to submit the following for the assignment:You canuse the generate dropdown to create example JAVA code based on your working logical flow chart to see what the code would look like.Remember to follow the guidelines of good program design. Make sure to use meaningful variable names and include comments as needed.