Midterm exam

0.0(0)
studied byStudied by 0 people
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
Card Sorting

1/21

encourage image

There's no tags or description

Looks like no tags are added yet.

Study Analytics
Name
Mastery
Learn
Test
Matching
Spaced

No study sessions yet.

22 Terms

1
New cards

Classes

Blueprint for creating objects in Java.

2
New cards

Class Scope

The ability of methods in one object to access variables of another object within the same class.

3
New cards

Abstract Data Type

A data structure that defines a set of operators without specifying their implementation.

4
New cards

Instance Variables

Variables that are typically declared private within a class.

5
New cards

Constructor

A method used to initialize a newly created object.

6
New cards

Default Constructor

A constructor with no parameters that initializes object properties to default values.

7
New cards

Copy Constructor

A constructor that creates a new object as a copy of an existing object.

8
New cards

Public Class Members

Members that can be accessed from outside the class.

9
New cards

Private Class Members

Members that are only accessible within the class.

10
New cards

Getters and Setters

Methods that provide controlled access to private variables.

11
New cards

Composition

A design principle where a class contains instances of other classes.

12
New cards

toString Method

Method that converts an object to a String representation.

13
New cards

equals Method

Method that compares two objects for equality based on their content.

14
New cards

Inheritance

A mechanism where one class inherits attributes and methods from another class.

15
New cards

Subclass

A class that is derived from another class.

16
New cards

Super()

A keyword used to call the constructor of the parent class.

17
New cards

Overriding

Defining a subclass method with the same name and parameters as a method in the superclass.

18
New cards

Overloading

Defining multiple methods with the same name but different parameters.

19
New cards

Abstract Class

A class that cannot be instantiated and may contain abstract methods.

20
New cards

Abstract Method

A method declared without an implementation that must be implemented in subclasses.

21
New cards

Polymorphism

The ability of an object to take on multiple forms, typically through method overriding.

22
New cards

Example of Polymorphism

Animal mypet = new Dog();