KXA Exam Template
Pages: 6
Questions: 10
UNIVERSITY OF TASMANIA
EXAMINATIONS FOR DEGREES AND DIPLOMAS
October–November 2018
KIT506 Software Application Design and
Implementation
First and Only Paper
Ordinary Examination
Examiners: Dr Julian Dermoudy and Amanda Lunt
Time Allowed: THREE (3) hours
Reading Time: FIFTEEN (15) minutes
Instructions:
There is a total of 180 marks available. Attempt ALL questions. Each
question is work 18 marks.
The answers must be written in the booklet provided.
Student ID No: _________________
2 KIT506 Software Application Design and Implementation
Continued…
Question 1.
Consider the following excerpt from an RTM for software to manage paint colour
selection. Write the action–software reaction table that would be part of the structured
scenario for this use case.
Entry Para Requirement Type Use Case
201 7.3.1 The user will choose a colour and obtain a
hardcopy swatch (print of colour)
SW UC20 Print
Swatch
202 7.3.1 The action is started by pressing a “Choose”
button
SWC
20
203 7.3.2 The user will be shown a colour wheel SWC
20
204 7.3.2 The user selects a colour from the colour wheel SWC
20
205 7.3.3 If the printer has paper then a colour swatch is
produced
SWC
20
206 7.3.3 If the printer does not have paper then an
error message is displayed
SWC
20
[18 marks]
Question 2.
Education Australia needs you to design a database for their organisation. After
conducting some analysis, you have collected the following information:
• Students can be studying at Kindergarten, Primary School, High School, College,
or University level
• Children belong to a school which has a name
• Children can hold the capability to be an A, B, or C student
• Each level has a time limit (1 year for Kindergarten, 6 years for Primary School, 4
years for High School, 2 years for College, and 3 years for University) and the
child can determine how many more years remain in that level
• Each child has preferred activities which they can describe (i.e. produce a string).
Activities vary according to section and by the child’s preferences
• Preferences are named and may be writing or mathematics or art or ICT. Each
child has a single preference although preferences can be shared by many
children
• Preferences can be counted to determine the number of children with that
preference. This action returns a whole number between 0% and 100%.
Draw a UML class diagram that best describes the above information. Include attributes
and methods that are mentioned in these classes. (Treat actions, like explained or
counted, etc as methods.) Include multiplicities, enumerations, specialisation, and so
one, where relevant.
[18 marks]
3 KIT506 Software Application Design and Implementation
Continued…
Question 3.
Draw a UML sequence diagram to show what happens when the following classes are
executed.
class Program {
static void Main(string[] args) {
A a = new A();
B b = new B{ Thing = a };
C c = new C();
b.Run2();
c.Show(a);
}
}
class A {
public void Run(C c) {
c.Show(this);
}
}
class B {
public A Thing { get; set; }
public void Run() {
Run2(Thing);
}
public void Run2(A) {
C c = new C();
a.Run(c);
}
}
class C {
public void Show(A a) { /* code to be written */ }
}
[18 marks]
Question 4.
a. What is the Model-View-Controller design pattern and what are the
benefits of using it?
[6 marks]
b. Why do we use design patterns and what advantages and disadvantages
does their use provide.
[6 marks]
c. Describe two design patterns (other than Model-View-Controller), draw
them, and explain what they are used for.
[6 marks]
4 KIT506 Software Application Design and Implementation
Continued…
Question 5.
Consider the following class diagram. Write C# code to declare the classes and
enumerations contained within the diagram. Do not include using or namespace
declarations in your answer.
You may assume that all required namespaces are available. Each attribute must be a
public, auto-generated property. Any methods you write should be stubs, with an
appropriate header but no code within their body { }.
[18 marks]
Question 6.
In parts (a)–(c) below suppose there exists a class called Birds that represents the birds
found in a typical nature reserve. Each bird has three public properties: Name (a
string), Flies (a bool), and WingSpan (a double) in centimetres.
a. Assuming the following declaration of a collection of Birds
List
that has been filled with Bird objects, write a LINQ expression that selects
those birds which can fly.
[6 marks]
b. Further suppose that there exists a MySQL database with a table called
WildBirds that has a string-valued column title, a double-valued
column wings, a boolean-valued column flighted, and a string-valued
column entitled colour. Write a suitable SQL query to retrieve the
information necessary to create Bird objects from the information in the
WildBirds table.
[6 marks]
c. Now, assuming that a MySqlDataReader called rdr has been created
using the query you defined in (b), and that it has been executed and its
Read() method called to load the first result. Write a single C# statement
«enumeration»
Nature
Essay
Program
Design
Unit
+Name: String
+Kind: Nature
+Assess(a: Task): void
HardTask
+Cheat(): void
Task
+Number: int
+Difficulty: int
Read(): void
2..* 1
comprises
EasyTask
+DoItYourself(): void
5 KIT506 Software Application Design and Implementation
Continued…
to instantiate a Bird object using the data retrieved and assign it to a
variable called b.
[6 marks]
Question 7.
a. Assume a WPF Window uses a Grid layout with two columns and three
rows. Write a fragment of XAML to create a TextBlock with the name
“sampleText” that occupies all of the top-right cell in the grid. Have the
TextBlock display the text “Trump for President”. Include only those
properties that are necessary to achieve this behaviour. Do not write the
XAML for the containing Grid.
[9 marks]
b. Consider the following excerpt from the XAML for an application’s main
Window. Draw a low-fidelity sketch of the GUI it defines. It should be
approximately to scale, but does not need to be exact.
[9 marks]
Question 8.
a. What is black box testing and when would you use it instead of white box
testing?
[6 marks]
b. What is white box testing and when would you use it instead of black box
testing?
[6 marks]
6 KIT506 Software Application Design and Implementation
c. Describe some non-execution testing schemes and explain their
advantages.
[6 marks]
Question 9.
a. In the .NET Framework, what is LINQ and what benefits does it provide to
software development? (Write three to five sentences in total.)
[6 marks]
b. Describe the purpose of and benefits from using Data Templates in XAML.
[6 marks]
c. With regard to WPF and XAML, what is data binding and what are some of
the benefits it provides? Include an example of how data binding may be
used.
[6 marks]
Question 10.
Consider the following use-case-based test for the application developed in your
assignments, and answer the questions that appear below the table.
Description Selecting a unit from this list should bring up a list of classes for that
unit, ordered chronologically.
Type and Use
Case
SW UC24_User_selects_Unit
Criteria Clicking on a unit from the list of units should display the classes for
that unit
Method White box test:
1. When the Unit list is displayed…
2. Select a unit from the list
3. Check the displayed details to ensure those displayed are the list of
classes for that unit
Outcome Fail
a. Can the “Fail” shown as the outcome be trusted? Why/why not?
[6 marks]
b. Based on your knowledge of the HRIS, are there enough test methods in
this test case? If not, what additional methods or steps would you add?
[6 marks]
c. When in the software development lifecycle can use-case-based tests be
developed?
[6 marks]
Question 1.
Question 2.
Question 3.
Question 4.
Question 5.
Question 6.
Question 7.
Question 8.
Question 9.
Question 10.