chapter 5, 6 and 7: oop finals Flashcards
The meaning of ___________ is to make sure that “sensitive” data is hidden from users.
ENCAPSULATION
It enables the use of existing class to define a new class.
Java Enheritance/Enheritance
A derived class is defined by adding instance variables and methods to an existing class. It
is also known as ________, __________, and __________.
subclass, child class, and descendant class.
The existing class that the derived class is built upon is called the _________. It is also called
superclass, parent class, and ancestor class.
base class
The derived class is _______ while the base class is _______.
Student, Person
The ________ class inherits the declared instance variables and public methods in the _________ class except its constructor.
Student, Person
A derived class has its own _________. It does not inherit any constructors from the base class.
Constructors
An __________ is an event that occurs during the execution of a program that disrupts the normal flow of instructions.
Exception
It is the process used to change the normal flow of code execution if a specified exception occurs.
Exception handling
Exceptions that occur during compilation are called _______________.
Checked exceptions
________________ are exceptions that occur during execution. These are also known as ___________.
Unchecked exceptions, runtime exceptions.
A ____________ is a block of code that might throw an exception that can be handled by a matching catch block.
Try block
A ____________ is a segment of code that can handle an exception that might be thrown by the try block that precedes it
Catch block
Only _______ try block is accepted in a program but there can be multiple catch blocks.
One (1)
The _________ contains statements which are executed whether or not an exception is thrown.
Finally block