Lecture 3 - UML Diagrams Flashcards

1
Q

What does UML stand for

A

Unified Modelling Language

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

What are the 2 types of views in UML?

A
  • Static view
  • Dynamic view
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What does a dynamic view show in a UML diagram?

A

Focuses on how the system works

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What does a static view show in a UML diagram?

A

Focuses on what the system is

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

TF: Class diagrams are a type of dynamic view

A

False. Type of static view

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

TF: Sequence diagrams are a type of dynamic view

A

True

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

What are the three categories of UML diagrams?

A
  • Structural
  • Behavioural
  • Interaction
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

Class, component, object are part of what category of UML diagrams?

A

Structural

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

Activity, state machine, use case are part of what category of UML diagrams?

A

Behavioural

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Communication (collaboration), sequence, interaction overview, timing are part of what category of UML diagrams?

A

Interaction

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

Which category of UML diagram is concerned with the structure of the system?

A

Structural UML diagrams

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

Which category of UML diagram is concerned with the behavioural features of a system?

A

Behavioural UML diagrams

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

Which category of UML diagram is concerned with how objects interact with each other?

A

Interaction UML diagrams

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

What are the two components of a Use Case Diagram?

A
  • Actors
  • Use cases
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

What do Actors represent in Use Case Diagram?

A

Roles, type of user of the system

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

What do Use cases represent in a Use Case Diagram?

A

A sequence of interaction for a type of functionality / summary of scenarios

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
17
Q

TF: Use case model is only a partial description of the functionality of the system

A

False. It is a complete description

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
18
Q

Use cases are useful to… (3)

A
  • Determine requirements
  • Communicate with clients
  • Generate test cases
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
19
Q

TF: Class diagrams display what interacts with each other and what happens when they do interact

A

False. Just display what interacts with each other (classes and their relationships)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
20
Q

Attributes and operations of each class are found in…

A

Class diagrams

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
21
Q

What is the only mandatory item in a class diagram?

A

Class name

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
22
Q

A class in UML diagram is divided into three parts, which are…

A
  1. Class name
  2. Class attributes (variables)
  3. Class operations (methods)
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
23
Q

What does the ‘-‘ modifier represent in UML class notation?

A

Private

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
24
Q

What does the ‘+’ modifier represent in UML class notation?

A

Public

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
25
Q

What does the ‘#’ modifier represent in UML class notation?

A

Protected

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
26
Q

How is static represented in UML class notation?

A

Underline

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
27
Q

How is an abstract class represented in UML class notation?

A

By writing the name in italics

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
28
Q

What is an aggregation and how is it represented in UML class notation?

A

Association where one class belongs to a collection (e.g. Instructor part of a Faculty). Represented by an empty diamond on side of the collection

29
Q

What is a composition and how is it represented in UML class notation?

A

Strong form of aggregation where component cannot exist without aggregate. Represented by a solid diamond on side of the collection

30
Q

What is inheritance and how is it represented in UML class notation?

A

A link indicating parent child relationships between two classes (car is child of vehicle). Represented by a triangle pointing to parent

31
Q

What is Binary Association?

A

Association where both entities know about each other (both classes can interact with each other)

32
Q

What is Unary Association?

A

Association where Class A knows about Class B, but Class B knows nothing about Class A (person knows an address, but address doesn’t know anything about the person)

33
Q

TF: Object diagram is a snapshot of objects in a system at a specific point in time

A

True

34
Q

What are the three possible focuses of Object Diagrams?

A
  1. Interactions
  2. Message passing
  3. Operation
35
Q

What is the format of an object diagram?

A
  • instance name : class name (usually underlined)
  • attributes and values
36
Q

What type of diagram displays the structural relationship of components of a software system?

A

Component diagrams

37
Q

TF: Components communicate with each other using interfaces

A

True

38
Q

What is a package in UML diagrams?

A

A collection of logically related UML elements

39
Q

How do package diagrams organize complex class diagrams?

A

By grouping classes together

40
Q

What do dotted lines represent in package diagrams?

A

Package dependencies

41
Q

What makes a package dependent on another?

A

If changes in one package can possibly force changes on another package

42
Q

What type of diagram depicts a static view of the run-time configuration of hardware nodes and the software components that run those nodes?

A

Deployment diagram

43
Q

TF: Deployment diagrams only show the hardware for your system

A

False. Also show the software installed on that hardware

44
Q

Interaction diagrams describe…

A

how objects collaborate

45
Q

TF: Interaction diagrams are static

A

False. They are dynamic

46
Q

Is a sequence diagram static or dynamic?

A

Dynamic

47
Q

What type of diagram describes a single scenario executing in the system?

A

Sequence diagram

48
Q

What level of the UML class diagram is sequence diagram most useful?

A

Specification level

49
Q

What are the key parts of a sequence diagram? (3)

A
  • Participant
  • Message
  • Axes of sequence diagram
50
Q

What is a participant in a sequence diagram?

A

Object or entity that acts in diagram

51
Q

What is a message in a sequence diagram?

A

Communication between participant objects (method call)

52
Q

What does the axes represent in a sequence diagram? (vertical and horizontal)

A
  • Vertical: time (going down represents moving forward in time)
  • Horizontal: which object/participant is acting
53
Q

How do you represent objects in a sequence diagram?

A

Squares with object type (optionally can add object name before the type in form objectName: className)

54
Q

What do the vertical dashed lines represent in sequence diagrams?

A

Object’s lifeline

55
Q

How is the creation of new objects represented in sequence diagrams?

A

Arrow with ‘new’ written above it

56
Q

How is the deletion of an object represented in sequence diagram?

A

X at the bottom of object’s lifeline

57
Q

TF: Sequence diagrams are language-agnostic (not specific to a programming language)

A

True.

58
Q

The type of diagram used to model the dynamic behaviour and use case is called…

A

Communication diagram

59
Q

TF: Communication diagram more focused on showing the collaboration of objects rather than the time sequencing

A

True

60
Q

TF: Activity diagrams are the object-oriented equivalent of flow charts and data-flow diagrams

A

True

61
Q

What are the 5 elements that make up an activity diagram?

A
  • States
  • Swim lanes
  • Branch
  • Fork
  • Start and end
62
Q

What are states in an activity diagram?

A

Describe what is being processed (indicated by boxes with rounded corners)

63
Q

What are swim lanes in an activity diagram?

A

Indicate which object is responsible for what activity

64
Q

What are branches in an activity diagram?

A

Transition that branch (indicated by a diamond)

65
Q

What are forks in an activity diagram?

A

Transition of a single incoming flow into multiple concurrent flows (indicated by solid bars)

66
Q

How is the start of an activity diagram represented?

A

Filled circle

67
Q

How is the end of an activity diagram represented?

A

Filled circle with a ring around

68
Q

What type of diagram shows the different states of an entity and how an entity responds to various events by changing from one state to another?

A

State transition diagrams