USE VISUAL PARADIGM Consider how you would make a class diagram for a property r
ID: 3679033 • Letter: U
Question
USE VISUAL PARADIGM
Consider how you would make a class diagram for a property rental management program.
Model your answers on a class diagram.
- The class Client has attributes name and address with methods setName and setAddress
- The class Property with attributes address, safety_checks, rent_value, repairs_required and occupied.
- The classes Landlord and Tenant are both subclasses of Client. In addition to the other attributes Landlord has attribute property. Tenant has attributed credit_checked
Explanation / Answer
In class diagram,we have to give all information about the given entities and establish relationship among them.Here Landlord,Tenant,Client and Property are the entities.For each entity,we have to give their attribute and methods.For each attribute,we have to specify their data type also.All these are done inside the box specified for entities.Entities,Methods and attributes are seperated by a line inside the box specified forentities.All the entities have different kinds of relation between them.They are 1:N,1:1,M:N and so on.Here as I specified in the diagram,we can see that there exists many clients for many property ,so the relation is M:N.Similar relationships of different kinds is established. For example,There are many clients but only 1 Landlord and 1 Tenant in each client.similarly here we can also establish 1:1 relation between property and landlord and 1:N relationship between property and tenant.
Related Questions
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.