1/46
Looks like no tags are added yet.
Name | Mastery | Learn | Test | Matching | Spaced |
|---|
No study sessions yet.
Object-oriented programming
A programming paradigm based on the concept of "objects," which are instances of classes that encapsulate data and methods. It emphasizes principles such as inheritance, encapsulation, and polymorphism to create modular and reusable code.
Constructor
Java declaration that provides the initialization logic for new objects
Object reference
The value stored in a variable which refers to an object
Field
Java declaration that provides state (data memory) for objects
Method
Java declaration that provides behavior (executable logic) for objects
Class
Java declaration that provides an overall blueprint for creating instances of a particular type of object - such as instance of a pizza order
Primitive
A type of value such as int, double, char, or boolean that can be held within a variable
Static
When declaring a field, what java keyword should be used to indicate that the field is a storage area for the class itself, rather than a separate storage area within each instance of the class?
A reference (or pointer) to the object
When an object is given as a method argument, what is actually passed?
The signatures ad documented behavior of public constructors, methods and sometimes fields in a class or class library
What best defines the meaning of API?
Garbage collection
Aggregation
What is the unified modeling language (UML) term for an association of objects with a whole-part relationship? (also has-a relationship)
String.format() method
Create.a string where literal components are interspersed with the values of other primitive types (which are converted to strings as necessary)
StringBuilder
Efficiently create a large string that is composed of many smaller strings appended together
A “parse” method of a numeric wrapper class
Convert a string to double or int
String.split() method
Tokenize a string
String.indexOf
Locate the first occurrence of one (smaller) string within another
Dynamic binding
When a language (like Java) selects the method to be called based on the object being referenced - not based on the type (class) of the variable used for the call
Overriding
Defining a more specialized version of a method than the one that was defined in a superclass
Overloading
Creating multiple methods with the same name, but different signatures (parameter types)
Inheritance
In object-oriented languages like Java, defining a (child) class that extends another (parent) class - thus creating a more specialized version of the parent class
Polymorphism
Term for referencing different types of objects with the same variable. Java allows this as long as each object being referenced “IS-A” instance of the type of the variable
Abstract
A method definition without a body - such definitions require subclasses to provide a complete method definition that does include a body. Also describes a class containing such method definition
Subclass
A (child) class that extends another class by inheritance
super
The keyword used to call a constructor or method of a parent class
interface
The keyword used to define a named group of abstract methods which can be implemented by diverse classes
try
The java keyword that defines a block of statements in which exceptions might be raised
catch
The keyword that defines a block of statements to be executed when a specific exception is raised
@Test
The annotation which indicates that a method is a Unit test
instanceof
The keyword used to create a boolean expression that tests an object’s type or supertype
extends
Java keyword used to define a class as inheriting from another class
implements
Keyword used in a class definition to guarantee that the class defines every (abstract) method from an interface - by providing a body with logic for each of the interface’s methods
Throwable
Parent class of all exceptions and errors - thus representing any type of anomalous condition that could be raised by a Java program
abstract
The method definition keyword used in a superclass to establish the signature and return type of a method - but not implement it
final
Keyword stating that a variable or field will not be changed after first initialization
Immutable
An object, field, or variable whose value cannot be changed
Is-A
object-modeling (UML) term which describes a relationship among two categories (like Dog and Animal) where the first represents a more specialized category of the second
Superclass
a (parent) class being extended by inheritance
Annotation
extra metadata to specific declarations for use by the compiler
or other tools - for example noting that a method is a Junit test.
private
declare that a field or method cannot be accessed by code from any other classes.
handle
The general term for responding to an anomalous condition which was triggered in some method call (possibly nested several levels deep).
Traceback
The term for a list of method names and Java file line numbers where a problem arose during program execution. The list of methods shows the nested method calls that were being executed when the failure occurred.
Error
Parent class for various system problems (such as misconfigured software and running out of memory) that cannot (reasonably) be handled by a Java program.
Exception
Parent class for anomalous conditions which a program could try to handle. The Java class name matches the term we typically use to refer to them.
RuntimeException
The parent class for unchecked exceptions in Java.
throw
The java keyword that is used to raise an anomalous condition such as an exception.
throws
The java keyword which declares that a method can raise certain exceptions without handling them itself - thus making these exceptions the responsibility of all callers to handle.