Chapter 7

Questions for Chapter 6

1. How can you mark an attribute so that it will never change after it is first set?

A. +attrName

B. −attrName

C. attrName {readOnly}

D. attrName {query}

E. attrName {noChange}

F. attrName

2. How can you mark an attribute so that it has Class scope?

A. +attrName

B. −attrName

C. attrName {readOnly}

D. attrName {query}

E. attrName {noChange}

F. attrName

3. Which sort of ship would make a good Class?

A. Friendship

B. Leadership

C. Battleship

D. Transship

E. Ownership

4. Which sort of features can Instances have?

A. Slots

B. Parameters

C. Attributes

D. Faces

E. Operations

5. What letter labels an item that the query can change?

A. w

B. x

C. y

D. z

6. How does a DataType differ from a Class?

A. Only a DataType can ...

Get OCUP 2 Certification Guide now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.