on java please and write the main
Book title : String Mauthor String + Book (String String) + et Title: String getAuthor() String + toString(): String AudioBook duration int - narrator: String + AudioBook(String, Strine, int String) + get Duration(): int + Narrator): String + toString): String Written Bock Pages: int + Written Book(String String, int) get N Pages) int +.toString(): String EBook Printed ook - 158Nint hardcoverboolean Printed Boole(String, String, int int, boolean) + Printed Book(String String, int) getISSN)int get CoverType(): String toString(): String EBook/String, String, int, int) getSize(): int print): Printed Book tostne): String Book class: Attributes: title: the title of the book author: the author of the book Methods: Book(title: String, author: int): constructor getTitle(): this method returns the title of the book getAuthor(); this method returns the author of the book .toString(): returns the object's info in this format: 'Title: title, Author: author" AudioBook class: Attributes: duration: the length of the audio file in minutes narrator: the name of the person reading the book Methods: Audio Book(title: String, author: String, duration: int, narrator: String): constructor getDuration(): this method returns the duration of the audio book getNarrator(); this method returns the name of the narrator .toString(): returns the object's info in this format: "Title: title, Author: author, Format: Audio, Duration: duration, Narrator: narrator Written Book class: Attributes: nPages: the number of pages of the book Methods: WrittenBook(title: String, author: String, nPages: int): constructor getNPages (): this method returns the number of pages of the book .toString(): returns the object's info in this format: "Title: title, Author: author, Format: Written, number of pages: nPages" Printed Book class: Attributes: ISBN: the International Standard Book Number of the book hardcover: true if the book is hardcover, false otherwise Methods: PrintedBook(title: String, author: String, nPages: int, ISBN: int, hardcover: boolean): constructor PrintedBook title: String, author:String, nPages: int): constructor that initializes ISBN to 0 and hardcover to false getISBNO: this method returns the ISBN of the book getCoverType(); returns a string specifying if the book is hardcover or paperback toString(): returns the object's info in this format: 'Title: title, Author: author, Format: Written, number of pages: nPages, Printed, ISBN: ISBN hardcover/paperback EBook class: Attributes: size: the size of the ebook in MBS Methods: EBook(title: String, author: String, nPages: int, size: int): constructor getSize(): this method returns the size of the ebook print(): this method returns the current Ebook as an object of type PrintedBook .toString(): returns the object's info in this format: 'Title: title, Author: author, Format: Written, number of pages: nPages, Ebook, size: size MB Exercise: Translate into Java-code the previous classes