0% found this document useful (0 votes)
34 views5 pages

COS4017-BCoursework1 Specification 2023-24

The document provides instructions for a coursework assignment with two parts: 1) A use case diagram summarizing key functions and interactions of a mortgage management system. Students must define concepts, identify actors, and draw the diagram. 2) Programming and unit testing of a class to separate student records into files based on registration year. Students must implement the class, apply JUnit tests to one method, and prepare files and code for an oral presentation. The submission is one PDF merging the use case diagram response and programming/testing code. Strict adherence to instructions is required to avoid lost marks.

Uploaded by

Naeem Ahmed
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
34 views5 pages

COS4017-BCoursework1 Specification 2023-24

The document provides instructions for a coursework assignment with two parts: 1) A use case diagram summarizing key functions and interactions of a mortgage management system. Students must define concepts, identify actors, and draw the diagram. 2) Programming and unit testing of a class to separate student records into files based on registration year. Students must implement the class, apply JUnit tests to one method, and prepare files and code for an oral presentation. The submission is one PDF merging the use case diagram response and programming/testing code. Strict adherence to instructions is required to avoid lost marks.

Uploaded by

Naeem Ahmed
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 5

Software Design and Development

1st Coursework
Use Case Diagrams, Programming and Unit Testing

Handing out: Monday 14th February 2024

Handing in: 23:59, Sunday 17th March 2024

Important Information
This coursework, worth 50%, is an individual assignment. You must complete the work
yourself, without assistance from other students. Do not ask other students to help you, and
do not share code or any related materials with other students. All parts of your
submission will be checked for similarity to other student submissions. During the lab session on
21tst March 2024 you will present your work to lab demonstrators and will be asked to
explain various parts of your code.

Learning Outcomes
The first two out of three Learning Outcomes (LOs) are addressed by this coursework.

LO1:
a. discuss and apply fundamental theoretical concepts in software project development; --
use object-oriented approaches and rigorous testing (unit testing)
b. use basic principles of software design and express aspects of design in an
appropriate modelling language; -- UML notation (Use case diagrams)

LO2:
a. apply advanced OO analysis, design & programming concepts to construct reliable
software; -- OO analysis, design and programming; separation of concerns; unit testing
b. interpret and utilise software designs expressed in an appropriate modelling language; --
architectural and component design are transposed into appropriate classes and unit testing
follows the internal structure of the code
Introduction
The coursework assignment for this module requires you to complete two tasks outlined in this
document. The first task, “A. Use case diagram” [30%], will ask you to understand
the requirements of a system, described by a scenario, and define its key functions and
interactions with several stakeholders as a use case diagram. The second task, “B.
Programming and Unit Testing” [70%], will ask you to implement a class with several methods
and provide unit testing, using JUnit, for one of the methods.

The topics involved in this 1st Coursework are delivered, through lectures and lab sessions, as
follows:
• Java programming basics (FoP – semester 1)
• API on strings (week 1)
• Text I/O files (week 2)
• Exceptions (week 3)
• UML Use case diagrams (week 4)
• Unit testing & JUnit (week 5)

Carefully read the coursework assignment, pay attention to:


• Deadlines (Handing in: week 7; Oral presentation: week 8)
• The format of each of the deliverables (PDF, zip archive) associated with tasks A and B
• Each deliverable name
• Where you must upload your submission

Please ensure you follow the instructions provided precisely to avoid having marks deducted.

A. Use case diagram [30%]


Scenario. Every year, the Bank of Aire allows citizens to select from a number of possible
mortgage schemes for personal house buyers. The schemes are decided and coordinated by a
staff member, the Mortgage Manager. Each mortgage contract is then supervised by a staff
member, called the Risk and Compliance Officer, who offers mentorship and advice on
mortgage management and risk mitigation during the first year of the contract.

A web-based banking portal aimed at handling the process of managing mortgages has the
functions described below.

• The Mortgage Manager (MM) is able to add new customers to the bank’s database; and
update their details. MM can also add new employees (e.g., Risk and Compliance
Officers) to their team; and update their details. MM then manages an automatic
allocation of mortgage contract schemes to customers, based on their credit score and
banking history. When there are no available schemes that match a customer’s profile, a
suitable error message is displayed.
• Every customer is able to view a subset of schemes that are returned by the system as
options that match their credit profile.

• Risk and Compliance Officers are able to view the selected scheme for each customer.
They can also view the customers allocated to them for monitoring and mentorship.

Questions
A.1. Define the concepts of actor and use case. [5%]
A.2. Identify the actors and list them. [5%]
A.3. Draw a use case diagram showing the use cases, the actors, and their relationships, as
described by the scenario. [20%]

The answers to these questions must be provided in a pdf file where:


(i) the first line of this file contains your full name, followed by UoB number;
(ii) the second line is “Use case diagram”; then
(iii) the answers to the above questions. Each answer is preceded by the question.

Note 1. Follow the instructions to avoid having marks deducted.

Marking scheme
A.1. Define the concepts of actor and use case. Correct definition [5%]
A.2. Identify the actors and list them. All the actors presented by the scenario [5%]
A.3. Draw a use case diagram showing the use cases, the actors, and their relationships,
as described by the scenario. Correct and complete set of actors and use cases [10%];
correct relationships [10%]

B. Programming and Unit Testing [70%]


The BCS Student Chapter at the University of Bradford, registered in 2021, 2022, 2023 and 2024
maintains a text file containing the names of the society’s officers (e.g., Treasurer,
Secretary, etc.). For each student, a line in the file bcs.txt stores the UoB number, full name,
and role of the BCS member, separated by a space. The first two digits of the UoB number must
be one of 21, 22, 23 or 24.

You are asked to implement a class, called YearlyOfficers, that will reorganise the records of the
bcs.txt file into four text files, bcs21.txt, bcs22.txt, bcs23.txt, bcs24.txt containing
students from bcs.txt registered with the Society in 2021, 2022, 2023, 2024, respectively.

YearlyOfficers class will contain the following methods:


(i) openFiles() that will open the above mentioned files (bcs.txt, bcs21.txt, bcs22.txt,
bcs23.txt and bcs24.txt);
(ii) separateOfficers() that will read from the input text file, record by record (line by line),
writing into the appropriate output text file (officers registered in 2021, 2022 and 2023
will be stored in bcs21.txt, bcs22.txt, bcs23.txt and bcs24.txt, respectively), and
also counting the number of officers in each output file;
(iii) closeFiles() closing the above mentioned files and displaying the number of officers in
each of the bcs21.txt, bcs22.txt, bcs23.txt and bcs24.txt files.

It is expected that appropriate API handling strings will be used in connection with UoB numbers
and adequate Text I/O operations. When the first two digits of the UoB number are not
in the specified range then an exception is thrown, and preferably the error is recorded in an
error log file.

Questions

B.1. Implement the YearlyOfficers class and show by running it that it separates the
bcs.txt file by using the above-mentioned methods. [30%]

B.2. Apply unit testing, using JUnit, to the separateOfficers() method. Identify a minimal test set,
as a set of records in testOfficers.txt for testing this method and insert it, as comment, at the
beginning of the testing method. The output files will be testOfficers21.txt,
testOfficers22.txt, testOfficers23.txt and testOfficers24.txt. [20%]

B.3. Oral presentation of the implementation and unit testing. Apart from the Java source code
and JUnit, you should prepare a bcs.txt file, which includes at least two students per each year
and 10 overall, and testOfficers.txt file with minimum number of records, as they appear at
the beginning of the unit testing code. [20%]

The answers to questions B.1 and B.2 will be provided in a pdf file, where:
(i) the first line contains your full name, followed by UoB number, as Java comment; then
(ii) the Java solution to B.1 and unit testing code and testing file, as mentioned above (B.2).

For the oral presentation on 21st March (B.3), you should have prepared: (i) the Java code (B.1)
and bcs.txt file; (ii) JUnit code and testOfficers.txt. These must be the same with the java
code and JUnit testing code saved in the pdf file, as answers to questions B.1 and B.2.

Note 2. Follow the instructions precisely to avoid having marks deducted.

Note 3. The answers for sections A (Use Case Diagram) and B (Programming and Unit
Testing) must be merged into one single pdf file, with contents of the pdf file associated
with A first, followed by Section B. The final pdf file is Name_Coursework1.pdf, where
Name is your full name, as it appears on the first line of the file. For example, if on the first
line it appears John Smith (followed by UoB) then the file Name is
JohnSmith_Coursework1.pdf

Note 4. The file Name_Coursework1.pdf must be uploaded onto Canvas by


the given deadline.
Marking scheme
B.1. Running code [10%]; adequate string APIs, text I/O methods, exceptions [10%]; correct
results and comments regarding the APIs, text I/O methods and exceptions [10%]

B.2. Correct unit testing approach (correct testing assertion) [7%]; covering all the cases [7%];
minimal test set provided [6%]

B.3. Oral presentation covering correct functionality [5%]; correct unit testing [5%]; correct
answers to questions [10%]. If basic questions are not answered then this might impact on
previous marks.

NB. in case of similarities with other submissions or lack of awareness of own code, a mark of 0
(zero) is recorded.

You might also like