Posted: July 25th, 2024
In this homework you will develop software models for a system designed to support a business. You will choose the business and the main functionality of the system as part of Task 1 below. This choice is important as the models you will develop in the remaining tasks must match with your choice.
CO7207 Generative Development 2023: Homework (HW1)
Due date:
Friday 3rd March 2023 @ 17:00
Submission: Blackboard: Assessment and Feedback >> Homework (HW1)
Weight: 50%
This is an
individual assignment. To avoid plagiarism or collusion, you
should not be working together on this coursework. Any plagiarism or collusion will result in a serious penalty.
https://le.ac.uk/policies/regulations/senate-regulations/senate-regulation-11/part-b
Late submission will result in a penalty as per the senate regulations.
https://le.ac.uk/policies/regulations/senate-regulations/senate-regulation-7
In this homework you will develop software models for a system designed to support a business. You will choose the business and the main functionality of the system as part of Task 1 below. This choice is important as the models you will develop in the remaining tasks must match with your choice.
There are a total of 80 marks on offer across 4 tasks in this homework. Your mark will be a percentage (e.g., 100% = 80 marks, 50% = 40 marks, etc.).
This is a video that explains this coursework in detail (link when ready)
.
Download the “gendev.hw1.zip” file available on Blackboard. Import this project into Eclipse (via “File -> Import… -> Existing Projects into Workspace -> (o) Select archive file -> … -> Finish”). Solve all tasks within this project. After completing all tasks, you can then export this project as a zip file, and upload to Blackboard.
· The file “scratchpad.xml” should be used in the creation of all diagrams via
https://app.diagrams.net
(see the
help video on Blackboard
)
· Do not delete any files from “gendev.hw1.zip” – if you do, the best way to fix this is to re-download a fresh copy of the zip and begin again
· When you have completed all tasks in the “gendev.hw1” project – you should then export this as a zip file (via “File -> Export -> General -> Archive File -> To archive file -> [enter a name] -> Finish”)
· A single zip file must be submitted (you can submit as many times as you like, but only the last attempt will be marked)
· Files that do not follow the naming requirement, or that do not compile, will not be marked
· The “sanity check” file can be used to help you check that the submission is correct – but pay attention to what it outputs!
Firstly, you must choose a business that you will model. Please describe this business, list its stakeholders (e.g. customers, staff, etc), list the important information about the business entities (e.g. products and services), and informally describe the main use cases and activities of the business. Do NOT write this as a list, it should be written in sentences and paragraphs.
If you choose a business discussed in class and your diagrams are very similar, you work could be considered as plagiarism.
Finding a business description online and submitting it here (even with changes) will be considered as plagiarism.
Submission
· Place your description into the file “task1_description/description.txt” (see the help video linked above)
· This description should be within 100-200 words and cover enough information for you to answer Tasks 2-4 below.
Marking Criteria
· Identifying the main stakeholders (e.g. actors)
[2 marks]
· Identifying business entities (e.g. classes)
[4 marks]
· Describing use cases and activities
[4 marks]
· The word limit can be increased by 10% without penalty. Every further 10% after this leads to a removal of 10% of the highest possible mark. For example, 218 words is fine; 265 words would lead to -3 marks. Please ensure good use of language and grammar, and that your description matches the system you later develop.
You should create your behaviour models individually. Submitting work that is similar to that of another student, or similar to an online resource, will be treated as plagiarism (resulting in a score of 0 for HW1).
Part a) Use Case Diagram
Create a Use Case diagram for the system supporting your chosen business (as described in Task 1 above).
[12 marks]
Submission
· Create the diagram using
https://app.diagrams.net and the provided scratchpad.xml (see the help video above).
· Export the diagram
·
Do NOT compress the diagram – deselect “compressed” under “File -> Properties”
· Name this diagram “usecase.drawio” and store this in the folder “task2_usecase”
Marking Criteria
· Identifying at least 6 meaningful Use Cases (1 mark each)
[6 marks]
· Correct and non-trivial participation of actors in Use Cases (at least one example of more than one actor involved in a Use Case) (0.5 mark each)
[3 marks]
· Correct use of at least one <> and <> (1 mark for extend, 1 mark for include)
[2 marks]
· Good use of generalisation for Use Cases or actors
[1 mark]
Part b) Activity Diagram
Create one activity diagram for the system supporting your chosen business (as described in Task 1 above).
[12 marks]
Submission
· Create the diagram using
https://app.diagrams.net and the provided scratchpad.xml (see the help video above).
· Export the diagram
·
Do NOT compress the diagram – deselect “compressed” under “File -> Properties”
· Name this diagram “activity.drawio” and store this in the folder “task2_activity”
Marking Criteria
· Identifying at least 6 meaningful actions (1 mark each)
[6 marks]
· At least 2 correct uses of decision nodes including guards on outgoing arrows (2 marks each)
[4 marks]
· At least one correct use of a fork and a join node
[2 marks]
The class diagram you create in EMF should be created individually. Submitting any code, or a class diagram, that is similar to that of another student or an online resource, will be treated as plagiarism (and result in a score of 0 for HW1).
The following tasks will require the use of Eclipse and the Eclipse Modelling Framework. The previous lab sessions will help you with learning the necessary techniques.
Part a) Class Diagram
Using EMF, design a class diagram for the system of your chosen business. Use role names and multiplicities on all association ends.
[17 marks]
Part b) OCL Invariants
Add three meaningful OCL class invariants to the Ecore model that follow your description in Task 1. Do this using the OCLinEcore editor (
see here for details
). The names of invariants must start with “inv1”, “inv2”, and “inv3” respectively.
[9 marks]
Submission
· Create your class diagram in the existing file “model/hw1.aird”
· Add the OCL invariants to “model/hw1.ecore” via the OCLinEcore editor (names beginning “inv1”, “inv2”, and “inv3” respectively).
Marking Criteria
· Class Diagram
· Identify at least 5 classes with correct and meaningful class names (1 mark each)
[5 marks]
· Use generalisations at least two times (1 mark each)
[2 marks]
· Use at least one abstract class
[1 mark]
· Use of attributes (at least one per class)
[5 marks]
· At least 4 correct associations with association role names and non-trivial multiplicities (not all * or 0..*) (1 mark each)
[4 marks]
· OCL class invariants
· Use attributes
[1 mark]
· Use of navigation leading to a single instance
[1 mark]
· Use of navigation leading to a set of instances
[1 mark]
· Use navigation via multiple associations
[1 mark]
· Use of if-then-else
[1 mark]
· Use of comparison operator (e.g. “”)
[1 mark]
· Use of size(), exists(), forall() (1 mark each)
[3 marks]
The instances and invariants produced here should be created individually and should not match (or be similar) to that of another student or online resource. Any such case will be treated as plagiarism (and result in a score of 0 for HW1).
You will now continue your use of EMF, this time focusing on instances.
Part a) Instance of Ecore Model (Object Diagram)
Using EMF API (and not the editor plugin), add code to “gendev.hw1/Task4.java” that creates an instance of the Ecore Model (in other words, an Object Diagram). This should have at least 5 objects and 5 links and should be saved into XMI format.
[8 marks]
Part b) Instances of OCL Invariants
Using the Dynamic Instance Editor, create two instances per OCL invariant. One instance must satisfy the OCL invariant, while the other must violate the OCL invariant. All instances must be valid in the Class Diagram when ignoring the OCL invariants.
[12 marks]
Submission
· Instances of Ecore Model (Object Diagram)
· Implement the code in “src/gendev/hw1/Task4.java”
· Save the XMI to “task4_instance/instance.xmi”
· Instances of OCL Invariants
· “task4_instance/inv1_sat.xmi” (satisfying invariant “inv1…”)
· “task4_instance/inv1_fail.xmi” (violating invariant “inv1…”)
· “task4_instance/inv2_sat.xmi” (satisfying invariant “inv2…”)
· “task4_instance/inv2_fail.xmi” (violating invariant “inv2…”)
· “task4_instance/inv3_sat.xmi” (satisfying invariant “inv3…”)
· “task4_instance/inv3_fail.xmi” (violating invariant “inv3…”)
Marking Criteria
· Code to create the instance entered into “gendev.hw1/Task4.java”
[6 marks]
· Code to save the instance into XMI
[2 marks]
· Total of 6 OCL instances (2 marks each)
[12 marks]
Place an order in 3 easy steps. Takes less than 5 mins.