Answer the following statements true (T) or false (F)

1. Patterns are so general they need not make assumptions about the application to which it is being applied.
2. Patterns can help organize the presentation and understanding of ideas about software.
3. The Adaptor pattern transforms a class by layering a new interface over the class.
4. The Adaptor pattern changes the class it modifies when it layers a new interface over the class.
5. UML has annotations for inheritance and data flow.


1. To be substantive, each pattern must make assumptions about its application. The iterator pattern applies to very nearly all containers, but to apply the iterator pattern to a container, the iterator designer must know the structure of the container. You don’t create efficient random access iterators for a doubly linked list.
2. True.
Consider the types of iterator and the several iterator related member functions of the containers. If we had different names and concepts for what we now call begin() and end() member functions, and so on, we might be overwhelmed. With the organization of the iterator patterns, it is easier to remember the details. In fact the iterator pattern is part of a larger pattern, the Container-Iterator pattern.
3. True
Typically, the stack and queue template adapter containers by default modify the interface of the deque container. These adapters hide the deque interface, and provide interface appropriate to stack and queue respectively.
4. False
The Adapter Pattern does not change the class it uses. For example, the stack and queue adapter container classes pass the underlying container as a template parameter. The container type is used as a type for a variable within the container. The class is not changed.
5. True.
Inheritance is of importance in OOP, as is the flow of data between classes. Notation is provided.

Computer Science & Information Technology

You might also like to view...

In database terminology, a link between two tables is called a(n) ____.

A. active join B. relationship C. import D. export

Computer Science & Information Technology

A background ________ is a slide background fill variation that combines theme colors in different intensities or patterns

Fill in the blank(s) with correct word

Computer Science & Information Technology

In SharePoint, the ________ setting is important when team members in different countries are trying to coordinate their schedules for meetings and other events

A) time zone B) locale C) time format D) sort order

Computer Science & Information Technology

A(n) _____ reader can be wired or wireless and could attach to a tablet or other mobile device

Fill in the blank(s) with correct word

Computer Science & Information Technology