Test1_Chapter28 Flashcards

(19 cards)

1
Q

Object-oriented programming

A

A paradigm based on the concept of wrapping pieces of data, and behaviour related to it, into special bundles called objects, which are constructed from a set of
“blueprints”, defined by a programmer, called classes.

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

Objects

A

Objects have attributes that describe their appearance. To refer to the combined value of all attributes, we refer to the state of an object.

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

Abstraction

A

It is the process to represent the appearance and behaviour of an object in a computer program.

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

Encapsulation

A

It refers to the packaging of data fields and behaviours into a single unit (class) so that
implementation details are hidden.

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

Polymorphism

A

It is the ability of a program to detect the actual class of an object and call its implementation
even if it is declared as an instance of a parent class or abstract class.

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

Interface

A

It declared members of a class excluding their details.

-This construct must be implemented

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

Abstract class

A

A class from which no instance can be created

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

Struct

A

-It is like a class but is saved on/in the heap

-Structs are value types

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

A Class

A

-It is saved on/in the stack

-Classes are reference types

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

Sealed class

A

Another class cannot inherit from a sealed class

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

New

A

This keyword is used to hide a member of the same name in the base class

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

Constructor

A

A method that is used when an instance of a class is created (object is instantiated)

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

Signature

A

The signature of a method refers to its name and the parameter types

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

Overloading

A

It refers to methods with the same name but with different signatures.

  • When called, the Parameter types will determine which version of a method will be executed.

-It is done through static polymorphism

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

Abstract method

A

-A method that has no implementation (body).

-Such a method must be overridden in derived
classes.

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

Virtual Method

A

A method that has an implementation and may be overridden in derived classes.

17
Q

Association

A

A relation between classes that denotes “uses” or “has a”

18
Q

Aggregation

A

A relation that
denotes “contains”