Deck 20: Patterns and Uml
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Unlock Deck
Sign up to unlock the cards in this deck!
Unlock Deck
Unlock Deck
1/22
Play
Full screen (f)
Deck 20: Patterns and Uml
1
A pattern is a design principle that solves a problem that occurs over and over.
True
2
UML was designed by Grady Booch,Ivar Jacobson,and James Rumbaugh,based on Simula 68,SmallTalk,C++ and Java.
False
3
Describe the sorting pattern.Discuss the Selection sort routines in terms of this pattern.
Sort array
1)Get split point and Split two parts
2)Sort first part(recursive)
3)Sort second part (recursive)
4)Join sorted parts.
1)Get split point and Split two parts
2)Sort first part(recursive)
3)Sort second part (recursive)
4)Join sorted parts.
4
Patterns can help organize the presentation and understanding of ideas about software.
Unlock Deck
Unlock for access to all 22 flashcards in this deck.
Unlock Deck
k this deck
5
Design patterns are restricted to particular programming languages,of which C++ is one.
Unlock Deck
Unlock for access to all 22 flashcards in this deck.
Unlock Deck
k this deck
6
UML is a standard that is maintained by the Object Management Group,a nonprofit organization that promotes the use of object-oriented techniques.
Unlock Deck
Unlock for access to all 22 flashcards in this deck.
Unlock Deck
k this deck
7
The UML class diagram is a rectangle that has three sections.Fill in the members with necessary symbols for public,protected and private members.
class Square
{
public:
// unlisted members
void resize(double newSide);
void move(Pair point);
protected:
void erase();
// other members
private:
double side;
Pair topRtCorner;
};
Put your answer here:

class Square
{
public:
// unlisted members
void resize(double newSide);
void move(Pair
protected:
void erase();
// other members
private:
double side;
Pair
};
Put your answer here:

Unlock Deck
Unlock for access to all 22 flashcards in this deck.
Unlock Deck
k this deck
8
UML class diagrams by themselves are not of much utility.
Unlock Deck
Unlock for access to all 22 flashcards in this deck.
Unlock Deck
k this deck
9
Describe the sorting pattern.Discuss the Merge sort routines in terms of this pattern.
Unlock Deck
Unlock for access to all 22 flashcards in this deck.
Unlock Deck
k this deck
10
If what you need is not in UML,you can add features to UML.
Unlock Deck
Unlock for access to all 22 flashcards in this deck.
Unlock Deck
k this deck
11
UML has annotations for inheritance and data flow.
Unlock Deck
Unlock for access to all 22 flashcards in this deck.
Unlock Deck
k this deck
12
Patterns are so general they need not make assumptions about the application to which it is being applied.
Unlock Deck
Unlock for access to all 22 flashcards in this deck.
Unlock Deck
k this deck
13
UML provides no facility for describing libraries.
Unlock Deck
Unlock for access to all 22 flashcards in this deck.
Unlock Deck
k this deck
14
The Adaptor pattern transforms a class by layering a new interface over the class.
Unlock Deck
Unlock for access to all 22 flashcards in this deck.
Unlock Deck
k this deck
15
UML requires that the programmer understand every detail and dark corner of C++ to be useful.
Unlock Deck
Unlock for access to all 22 flashcards in this deck.
Unlock Deck
k this deck
16
Describe the sort pattern.Discuss the quick sort routines in terms of this pattern.
Unlock Deck
Unlock for access to all 22 flashcards in this deck.
Unlock Deck
k this deck
17
Give at least two STL containers that fit the Adapter Pattern as described in the text.
Unlock Deck
Unlock for access to all 22 flashcards in this deck.
Unlock Deck
k this deck
18
Given the class definition,give the class diagram.
class Pair
{
public:
Pair();
Pair(double,double);
void setFirst(double);
void setSecond(double);
double getFirst();
double getSecond();
protected:
double first;
double second;
};
Put your answer here:

class Pair
{
public:
Pair();
Pair(double,double);
void setFirst(double);
void setSecond(double);
double getFirst();
double getSecond();
protected:
double first;
double second;
};
Put your answer here:

Unlock Deck
Unlock for access to all 22 flashcards in this deck.
Unlock Deck
k this deck
19
The Adaptor pattern changes the class it modifies when it layers a new interface over the class.
Unlock Deck
Unlock for access to all 22 flashcards in this deck.
Unlock Deck
k this deck
20
UML is graphical language for designing programs.
Unlock Deck
Unlock for access to all 22 flashcards in this deck.
Unlock Deck
k this deck
21
Describe a GUI file manager in a windowing system in terms of the Model-View-Controller model.A file manager might be the Windows Explorer under MS Windows.
Unlock Deck
Unlock for access to all 22 flashcards in this deck.
Unlock Deck
k this deck
22
Describe the queue in terms of the Model-View-Controller pattern.
Unlock Deck
Unlock for access to all 22 flashcards in this deck.
Unlock Deck
k this deck