inheritance 1 Flashcards

1
Q

is a mechanism that enables one class to acquire all the behaviors and attributes of another class

A

Inheritance

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

A _______ ______ is a visual tool that provides you with an overview of a class.

A

class diagram

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

class diagram consists of a ______ divided into ____

A

rectangle
three sections

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

the top section contains the ____ of the class,

A

name

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

the middle section contains the________.

A

names and data types of the attributes,

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

the bottom section contains the ________.

A

methods

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

Only the ______, ________, _______, are provided in the diagram

A

method return type, name, and arguments

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

is a class that is used as a basis for inheritance

A

Base class

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

is a class that inherits from a base class.

A

Derived class

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

A derived class always _____ case or example of the more general base class.

A

“is a(n)”

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

“Is a” describes _______, but “has a” describes ______.

A

inheritance
containment

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

Two types of containment:

A

Composition
Aggregation

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

the relationship in which a class contains one or more members of another class, when those members would not continue to exist without the object that contains them.

A

composition

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

the relationship in which a class contains one or more members of another class, when those members would continue to exist without the object that contains them.

A

aggregation

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

Synonyms to base class: _______

A

superclass & parent class

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

Synonyms to derived class: __________

A

subclass & child class