Question at position 14 Consider the design of a system used to track and manage the items in a library. From discussions with librarians and other stakeholders you identified the following possible classes and fields. Book Fields of the Book class: library ID, name, description, data of acquisition, status, title, ISBN, category, authors, publisher, publication date DVD Fields of the DVD class: library ID, name, description, data of acquisition, status, title, actors, directors, genre, rating, length Recognizing that Books, DVDs, and other forms of library media all contain similar pieces of data/information that must be tracked and managed, you decide to create a Media class (see below) and use inheritance since it improves code re-usability. Media Fields of the Media class: library ID, name, description, data of acquisition, status Which would be the most appropriate way to utilize inheritance within your UML design?Media, Book, and Movie each as standalone class (not related by inheritance)Media as a superclass, with Book and Movie as subclasses of MediaMovie as a superclass, with Book as a subclass of Movie, and Media as a standalone classBook as a superclass, with Movie as a subclass of Book, and Media as a standalone class单项选择题

A

Media, Book, and Movie each as standalone class (not related by inheritance)

B

Media as a superclass, with Book and Movie as subclasses of Media

C

Movie as a superclass, with Book as a subclass of Movie, and Media as a standalone class

D

Book as a superclass, with Movie as a subclass of Book, and Media as a standalone class

登录即可查看完整答案

我们收录了全球超50000道真实原题与详细解析,现在登录,立即获得答案。

更多留学生实用工具

加入我们,立即解锁 海量真题独家解析,让复习快人一步!