Changes between Version 7 and Version 8 of BASE_BOOK_COMMONS_R0
- Timestamp:
- 12/19/08 18:17:06 (16 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
BASE_BOOK_COMMONS_R0
v7 v8 53 53 = Design = 54 54 55 The Book object model consists of three parts: 56 * Model - in package org.sophie2.base.model.book 57 * View - in package org.sophie2.main.view.book 58 * Logic - in package org.sophie2.main.view.logic 55 The Book object model is stored in module org.sophie2.base.model.book. Here's the class diagram for the main classes:[[BR]] 56 [[Image(source:/trunk/sophie2-platform/doc/uml-design-diagrams/Book-Object-Model.png)]] 57 58 Each book contains zero or more pages that can be accessed by the page() method in the Book class. Other properties of the book are also stored in the model - the current page, the page size, the title, the version and the container file. These all can be accessed by methods of the Book class, as seen in the diagram. There are additional methods for creating/deleting books and for reordering the pages. 59 60 The pages are represented by the Page class. Each page has associated styles - represented by BackgroundStyle, BorderStyle and ShadowStyle classes. The page contains 0 or more frames, represented by the Frame class. More thorough description of these should be provided in the [wiki:BASE_MODEL_PAGE_ELEMENTS_R0] task. 59 61 60 62 The basic actions for books are found in the following classes:[[BR]] 61 63 [source:/trunk/sophie2-platform/modules/org.sophie2.base.model.book/src/main/java/org/sophie2/base/model/book/Book.java Book.java][[BR]] 62 [source:/trunk/sophie2-platform/modules/org.sophie2.main.view/src/main/java/org/sophie2/main/view/book/BookView.java BookView.java][[BR]] 63 [source:/trunk/sophie2-platform/modules/org.sophie2.main.view/src/main/java/org/sophie2/main/view/logic/BookLogic.java BookLogic.java] 64 [source:/trunk/sophie2-platform/modules/org.sophie2.base.model.book/src/main/java/org/sophie2/base/model/book/Page.java Page.java][[BR]] 64 65 65 * These classes provide functionality for: 66 Some of the actions stated in the analysis section are provided by the BookLogic class - such as adding/removing pages since this depends on the BookView. 67 68 * Currently we have the following functionality for books: 66 69 * Creating and deleting books. 67 70 * Adding/removing/reordering the pages of a book. … … 73 76 * other things might be implemented in the next revisions of this task. 74 77 75 Here's the class diagram for these classes:[[BR]]76 [[Image(source:/trunk/sophie2-platform/doc/uml-design-diagrams/Book-Object-Model.png)]]77 78 78 Unit tests can be found here:[[BR]] 79 79 [source:/trunk/sophie2-platform/modules/org.sophie2.base.model.book/src/test/java/org/sophie2/base/model/book/BookUnitTest.java BookUnitTest.java][[BR]] 80 80 [source:/trunk/sophie2-platform/modules/org.sophie2.base.model.book/src/test/java/org/sophie2/base/model/book/PageUnitTest.java PageUnitTest.java][[BR]] 81 [source:/trunk/sophie2-platform/modules/org.sophie2.main.view/src/test/java/org/sophie2/main/view/logic/AppBookPageLogicUnitTest.java AppBookPageLogicUnitTest.java][[BR]]82 [source:/trunk/sophie2-platform/modules/org.sophie2.main.view/src/test/java/org/sophie2/main/view/logic/BookLogicUnitTest.java BookLogicUnitTest.java][[BR]]83 [source:/trunk/sophie2-platform/modules/org.sophie2.main.view/src/test/java/org/sophie2/main/view/book/BookViewUnitTest.java BookViewUnitTest.java][[BR]]84 81 85 82 = Implementation =