Information Modelling Flashcards
Soon it will all be over...
When modelling a library give an example of an actor, object, attribute, event and relationship?
Possible examples
Actors: borrower, clerk Objects: book, journal, magazine Attributes: name of book, name of author, date of loan Event: borrow, issue, discharge, reserve Relationship: loan, reservation
What is the redundancy in the following model and how should it be fixed?
Book (Object) - Literature for borrowing
Name of Book (Attribute) - The name of the book
Name of Book (Attribute) - The name of the author
Borrower (Actor) - Member of the library
Borrow (Event) - Take a book out from the library
Issue (Event) - Loan a book to a member
Loan (Relationship) - When a member borrows a book
Discharge (Event) - Cancels a loan
Date of loan (Attribute) - The end of the loaning period
Borrow and issue describe the same concept so we can just delete borrow and use issue to describe both.
Where is the missing information in the following model and how should it be fixed?
Book (Object) - Literature for borrowing
Name of Book (Attribute) - The name of the book
Name of Book (Attribute) - The name of the author
Borrower (Actor) - Member of the library
Borrow (Event) - Take a book out from the library
Issue (Event) - Loan a book to a member
Loan (Relationship) - When a member borrows a book
Discharge (Event) - Cancels a loan
Date of loan (Attribute) - The end of the loaning period
The date of the loan refers to the end of the loaning period but no start is specified. We fix this by adding a new attribute and amending date of loan as follows.
Issue date of loan (Attribute) - The start of the loan period
Due date of loan (Attribute) - The end date of the loan
What is the ambiguity in the following model and how should it be fixed?
Book (Object) - Literature for borrowing
Name of Book (Attribute) - The name of the book
Name of Book (Attribute) - The name of the author
Borrower (Actor) - Member of the library
Borrow (Event) - Take a book out from the library
Issue (Event) - Loan a book to a member
Loan (Relationship) - When a member borrows a book
Discharge (Event) - Cancels a loan
Date of loan (Attribute) - The end of the loaning period
The name of the book has the same name referring to two different attributes. We can fix this by renaming them to Title of Book and Author of Book.
Title of Book (Attribute) - The name of the book
Author of Book (Attribute) - The name of the author
What is a class and how is it represented?
A class is the type of all ‘X’s or the group that all ‘X’s belong to. It is drawn as a rectangular box with the label inside using CapitalCase. We can write a more detailed view in a box underneath showing the attributes of the class and another box underneath that one listing the events associated with it.