CO4403: Referral Coursework 1 Assignment 2019-20
Deadline: Midnight 7th August 2020
Weighting: 50% of Overall Module Mark
This is a referral assignment meaning the maximum mark you can achieve is 50% and you must achieve a mark of 50% in order to pass.
Learning outcomes tested in this assignment:
Explain and use key programming constructs to create correct and efficient programs
Design, and implement Object-Oriented programs
Develop technical software solutions to complex problems
1. Design Task – 10%
Write your full name down the ‘A’ column in the table below one character in each row omitting spaces and punctuation. If you full name is not long enough just repeat it. The combination of column A and B give you the names of classes and methods to use in your assignment. For example, if your name was ‘Daniel …’ this would give you DParentClass, aChild1Class, nChild2Class etc
Parent Class, stores an array of type String and an array of type int
Child Class 1 inherits from Parent Class, stores an array of type double
Child Class 2 inherits from Parent Class, stores an array of type long
Public method in Parent Class, 2x int as parameters, returns a String
Public method in Parent Class, 2x String as parameters, returns an int
Public method in Child Class 1, 2x float as parameters, returns a double
Public method in Child Class 1, 3x String as parameters, returns a double
Private method in Child Class 1, 2x Double as parameters, returns a long
Public method in Child Class 2, 2x boolean as parameters, returns a String
Private method in Child Class 2, 2x String as parameters, returns a String
Public method in Child Class 2, 3x long as parameters, returns a String
Using the information from the table above hand-draw a UML Class diagram on paper, ensure that:
· you use the correct notation for relationships between classes,
· class names are correct,
· method names are correct,
· method parameters/return types are correct,
· class instance variables are correct,
· variables are named appropriately,
· access modifiers are shown where appropriate, you are free to choose which modifier to apply where this is not mentioned in the table above.
You do not need to include class constructors in your UML diagram. Take a photo of your UML diagram and submit it through blackboard.
2. Development Task – 35%
You need to work through the following series of tasks in order; your mark will depend on your progress and the quality of the work you have done. You only need to submit your finished code after you have completed all tasks.
Task 1: Implement the UML Class diagram you have created in Java code, ensure the classes are in separate files.
Task 2: Create a driver program that creates instances of all classes, calls all methods with appropriate parameters, and outputs the results to the console.
Task 3: Add code into each method to act on the parameters and use them to generate an appropriate return value. You need to decide how to do this based on the parameters and return type of a method. For example, if given ‘3x String as parameters, returns a double’ you could convert all Strings to doubles (using Double.parseDouble or similar) and then return the highest.
Task 4: Add constructor methods to each of the 3 classes and use them to initialize instance variables.
Task 5: Extend Task 3 so the class instance variables are acted upon (ie data added and retrieved) in at least one method in each class.
Task 6: Ensure your driver program demonstrates that you have completed all the tasks, particularly that the methods act on given parameters (Task 3) and that methods act upon class instance variables (Task 5)
You will be expected to submit your entire source code (and Eclipse project). Your code must be commented, and you must include a separate document of references to any resources you used in the development of your application (books, web sites, forums etc).
3. Video Demo – 5%
Once your development is complete you must create a video demonstration which explains and justifies how you implemented task 3 and task 5 using the output of your driver program to demonstrates that your code works successfully. This should be a screen capture video with voice-over of your explanation. This demo is worth 5% and must be no longer than 5 minutes. The video demo is critical part of the assignment where you show how you have met the marking criteria.
Part 1 – Design (Worth 10% of this Assignment)
To obtain 5% you must have produced something recognizable as a UML class which aligns with the brief.
To obtain 10%, you will have produced a correctly constructed UML diagram showing relationships between classes and correct class/method names with only very minor mistakes.
Part 2 – Development Task (Worth 35% of this Assignment)
To obtain 10% you must have completely implemented your given UML diagrams into Java objects, your code must compile and have a driver program which creates objects and calls methods.
To obtain 25%, in addition to the above, you must have completed Task 3 successfully (with only very minor mistakes) and evidenced application of key Java programming constructs (such as if conditional or for loops).
To obtain 35%, in addition to the above, you must have completed all tasks successfully (with only very minor mistakes). Implementations of tasks 3 and 5 will show understanding and application of key Java programming constructs. Your source code will be appropriately organized and commented.
Part 3 –Demo (5% of this Assignment)
To obtain 5% for the demo you must have demonstrated a working and interactive Java SE application conforming to the assignment specification and clearly explain key technical aspects of Java code applied in the implementation tasks 3 and 5.
Submission of assignment work
Submit all your code, video demo, and any other documentation on Blackboard by the deadline at the top of this document.