Terms Flashcards
(160 cards)
<p>Primitive Data Types
| </p>
<p>Boolean, char, byte, short, int, long, float, and double.</p>
<p>Fields/Member variables/Instance Variables</p>
<p>A \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_ is a variable that is defined outside of any methods but inside of a class.</p>
Belong to each instance of the object.
Held in slots on the heap associated with their instances.
Maintain the state of their object.
<p>Reference Data Types</p>
<p>Reference variables used to access objects.
Declared to be a specific type(Car, Dog, String, Array, ect) which cannot be changed.
Can reference any object of the declared type.</p>
<p>Java</p>
<p>A multithreaded, architecture-neutral, portable, object-oriented, interpreted, dynamic, programming language first developed by Sun Microsystems in 1995.</p>
<p>The four principle concepts of Object Oriented Programming</p>
<p>Abstraction, Polymorphism, Inheritance, and Encapsulation. (A-PIE)</p>
<p>String</p>
<p>A complex type, meaning that is is a class. It has several built in methods that you can use to perform tasks. The difference is that you do not have to use new to build it.</p>
<p>Methods</p>
<p>A collection of statements that are grouped together to perform an operation.</p>
<p>Method Overloading</p>
<p>When a class has two or more methods by the same name but different parameters. Different functionality based on the parameters. </p>
<p>Control Flow/Conditional Statements</p>
<p>Decision making structures have one or more conditions to be evaluated or tested by the program.
If: An if statement consists of a boolean expression followed by one or more statements.
If Else: An if statement can be followed by an optional else statement, which executes when the boolean expression is false.
Nested If: You can use one if or else if statement inside another if or else if statement(s).
Switch: A switch statement allows a variable to be tested for equality against a list of values.</p>
<p>Loop Control</p>
<p>Allows us to execute a statement or group of statements multiple times.
While: Repeats a statement or group of statements while a given condition is true. It tests the condition before executing the loop body.
For: Execute a sequence of statements multiple times and abbreviates the code that manages the loop variable.
Do While: Like a while statement, except that it tests the condition at the end of the loop body.</p>
<p>Break Statement</p>
<p>Terminates the loop or switch statement and transfers execution to the statement immediately following the loop or switch</p>
<p>Class</p>
<p>A template/blueprint that describes the behavior/state that the object of its type supports.</p>
<p>Local Variables</p>
<p>Variables defined inside methods, constructors or blocks. The variable will be declared and initialized within the method and the variable will be destroyed when the method has completed.</p>
<p>Instance Variables</p>
<p>Variables within a class but outside any method. These variables are initialized when the class is instantiated. Can be accessed from inside any method, constructor or blocks of that particular class.</p>
<p>Static Class Variables/Fields</p>
<p>Variables declared within a class, outside any method, with the static keyword. They have the same value in any instance of the class. Static, as in locked down.</p>
<p>Constructors</p>
<p>Each time a new object is created, at least one \_\_\_\_\_\_\_ will be invoked. The main rule of \_\_\_\_\_\_\_\_\_ is that they should have the same name as the class. A class can have more than one \_\_\_\_\_\_\_\_.</p>
<p>Package</p>
<p>A collection of related classes/interfaces.</p>
<p>Import Statements</p>
<p>The \_\_\_\_\_\_\_\_\_\_\_\_ \_\_\_\_\_\_\_\_\_\_\_\_ in Java is used to refer to classes which are declared in other packages to be accessed without referring to the full package name.</p>
<p>Inheritance</p>
<p>The process where one class acquires the properties (methods and fields) of another. With the use of \_\_\_\_\_\_\_\_ the information is made manageable in a hierarchical order.
Denoted by the keywords "extends" for a class and "implements" for an interface".
Creates an IS-A relationship. The class that inherits from another class IS-A type of that other class.
Makes code DRYer.</p>
<p>Polymorphism</p>
<p>The ability of an object to take on many forms. The ability of child classes to define their own behavior while also sharing some functionalities with the parent class by using the "extends" keyword.
Any Java object that can pass more than one IS-A test is considered to be \_\_\_\_\_\_\_\_. In Java, all Java objects are \_\_\_\_\_\_\_\_ since any object will pass the IS-A test for their own type and for the class Object.
Also applies to overloaded methods, since they are methods that have multiple forms.</p>
<p>Composition</p>
<p>When an instance of a class is a field of another.
The class with and instance of another as a field is said to have a HAS-A relationship with that other class.</p>
<p>Encapsulation</p>
<p>One of the four fundamental OOP concepts. The other three are inheritance, polymorphism, and abstraction.
A mechanism of wrapping the data (variables) and code acting on the data (methods) together as a single unit. In \_\_\_\_\_\_\_\_, the variables of a class will be hidden (private) from other classes, and can be ACCESSED only through the methods of their current class. Therefore, it is also known as data hiding.
Requires getters and setters to access the variables.
Helps make code maintainable, flexible, and extensible.</p>
<p>Inner Class</p>
<p>A class within another class. Used when a class only makes sense in the context of another class.</p>
Two Types: Local Inner Classes and Anonymous Inner Classes.
<p>Abstraction</p>
<p>A process of HIDING implementation details, only the functionality will be shown. In other words, we have the information on what the object/method does instead of how it does it.
Makes code easier to read and understand and makes code DRYer. </p>
Abstract Class
1) _________ ________ may or may not contain ________ methods, i.e., methods without body ( public void get(); ) 2) But, if a class has at least one _______ method, then the class must be declared ________. 3) If a class is declared _______, it cannot be instantiated. 4) To use an ________ ______, you have to inherit it from another class, provide implementations to the abstract methods in it. 5) If you inherit an _________ ______, you have to provide implementations to all the ________ methods in it.
Interfaces
A reference type in Java, it is similar to class. It is a collection of abstract methods. A class implements an __________, thereby inheriting the abstract methods of the ___________. Along with abstract methods, an ________ may also contain constants, default methods, static methods, and inner classes. Method bodies exist only for default methods and static methods. Writing an _______ is similar to writing a class. But a class describes the attributes and behaviors of an object. And an _______ contains behaviors that a class implements. Unless declared abstract, any class that implements an ___________ must define all of the methods inside that ___________.
Algorithms
These are the methods that perform useful computations, such as searching and sorting, on objects that implement collection interfaces. The _________ are said to be polymorphic: that is, the same method can be used on many different implementations of the appropriate collection interface.
Arrays
A data structure which stores a fixed-size sequential collection of elements of the same type. An ______ is used to store a collection of data, but it is often more useful to think of an _______ as a collection of variables of the same type.
Boxing
Converting primitive data types into object is called ________, and this is taken care by the compiler.
Unboxing
Converting objects types into primitive data types is called ___________, and this is taken care by the compiler.
Generics
Stand-Alone Application
A program that does not require an operating systems services to run.
JavaFx
A set of graphics and media packages that enables developers to design, create, test, debug, and deploy rich client applications that operate consistently across diverse platforms.
I/O Streams
A stream can be defined as a sequence of data. There are two kinds of Streams __________: Used to read data from a source. __________: Used for writing data to a destination.
Application Control Interface (API)
A set of routines, protocols, and tools for building software applications. Specify how software components should interact. Provide the building blocks of programs. In Java, this is a set of pre-written packages, classes, and interfaces with their respective methods, fields, and constructors. (JVM)
Exceptions
A problem that arises during the execution of a program. When an ________ occurs the normal flow of the program is disrupted and the program/Application terminates abnormally, which is not recommended, therefore, these exceptions are to be handled.
Databases
A repository of information managed by a ________ engine which ensures integrity of data and fast access to the data.
Regular Expressions
A special sequence of characters that helps you match or find other strings or sets of strings, using a specialized syntax held in a pattern. They can be used to search, edit, or manipulate text and data.
Object
An instance of a Class, with states and behaviors.
Three steps of object creation
1. Declaration with a object type and name 2. Instantiation with the "new" keyword 3. Initialization with a call to a constructor.
Object Oriented Programming (OOP)
Instead of a procedural list of actions, ___ is modeled around objects that interact with each other. Classes generate objects and define their structure, like a blueprint. The objects interact with each other to carry out the intent of the computer program.
Platform Independent
When Java is compiled, it is not compiled into platform specific machine, rather into _____________ ____________ byte code. This byte code is distributed over the web and interpreted by the Virtual Machine (JVM) on whichever platform it is being run on.
Architecture-Neutral
Java compiler generates an _____________________ object file format, which makes the compiled code executable on many processors, with the presence of Java runtime system.
Portable
Being architecture-neutral and having no implementation dependent aspects of the specification makes Java __________.
Multi-Threaded
A program contains two or more parts that can run concurrently and each part can handle a different task at the same time making optimal use of the available resources specially when your computer has multiple CPUs. By definition, multitasking is when multiple processes share common processing resources such as a CPU. ___________ extends the idea of multitasking into applications where you can subdivide specific operations within a single application into individual threads. Each of the threads can run in parallel. The OS divides processing time not only among different applications, but also among each thread within an application. ___________ enables you to write in a way where multiple activities can proceed concurrently in the same program.
Interpreted
Java byte code is translated on the fly to native machine instructions and is not stored anywhere. The development process is more rapid and analytical since the linking is an incremental and light-weight process.
Dynamic
Java programs can carry extensive amount of run-time information that can be used to verify and resolve accesses to objects on run-time.
Modifiers
Keywords used during declaration that can change the variable/method/class behavior. Two types: - Access modifiers - Non-access modifiers
Model-View-Controller (MVC)
An architecture used to develop flexible web applications. The _____________________________________ pattern results in separating the different aspects of the application (input logic, business logic, and UI logic), while providing a loose coupling between these elements. The _____ Encapsulates the application data (generally POJOs). The ____ renders the model data and generates HTML output. The _________ processes user requests before building a model and passing it to the ____ to be rendered.
Structured Query Language (SQL)
A domain specific language used for designing and managing data in a Relational Database.
RDBMS
Relational Database Management System
Representational State Transfer Application Programming Interface (REST API)
A ____ ___ is one built on the ____ architecture which uses HTTP requests to GET, PUT, POST, and DELETE data.
Java Database Connectivity (JDBC)
An API for Java that specifies how a client may access a database.
H2
An RDBMS written in Java that can support both in-memory (temporary during runtime) and persistent databases.
Java Persistence API (JPA)
A Java specification for accessing, persisting, and managing data between Java objects/classes and Relational Databases.
CRUD Repository
Create, Read, Update, Delete
Document Object Model (DOM)
A platform and language neutral interface that allows programs and scripts to dynamically access and update the content, structure, and style of a document.
Content Delivery Network (CDN)
A geographically distributed network of proxy servers and their data centers. The goal is to distribute service spatially relative to end-users to provide high availability and high performance.
Data Warehouse (DW or DWH)
A central repository of integrated data from one or more disparate sources. Store current and historical data in one place. Used for reporting and data analysis.
Lean Managment
An approach to running an organization that supports the concept of continuous improvement, a long-term approach to work that systematically seeks to achieve small, incremental changes in processes in order to improve efficiency and quality. More and more value, less and less waste.
Thymeleaf
A modern server-side Java Template Engine for both web and standalone environments, capable of processing HTML, XML, JavaScript, CSS, and even plain text.
"private" Modifier
An access modifier which makes the class/method/ variable only visible to the class it's in. The most restrictive access modifier. Helps with encapsulation. _______ variables need getters and setters to access them.
"public" Modifier
An access modifier which makes the class/method/ variable visible to every class, even ones outside the package via an import.
"protected" Modifier
An access modifier which makes the class/method/ variable only visible to its class, other classes in its package, and any subclasses of its class in other packages.
"static" Modifier
A non-access modifier which makes the declaration more general than instance specific. Variables/methods declared ______ exist outside of instances of the class. The values of the _____ variables/methods are the same in any instance of the class. Can be accessed independently of any class instance. ______ variables are also called "class variables".
"final" Modifier
A non-access modifier which doesn't allow a variable to be reassigned to another object. The state of the object that the variable is assigned to may still be changed. When used on a method, that method cannot be overridden by any subclass. ``` Immutable class means that once an object is created, we cannot change its content. Along with being declared final, an immutable class has to have all data members declared final, a parameterized constructor, getter methods for all variables, and no setters.
```The Default Modifier
In use when no modifier keyword is present on a class/method/variable. Makes the class/method/variable accessible to all classes in the package. (same as protected)
"abstract" Modifier
A non-access modifier which makes JVM wait for subclasses to implement the methods/classes.
Wrapper Classes
All the ________ ________ (Integer, Long, Byte, Double, Float, Short) are subclasses of the abstract class Number. The object of the _______ _______ contains or wraps its respective primitive data type. It allows us to convert primitive into object and object into primitive.
Overriding
A method has the same method name, return type, number of parameters, modifier etc. Uses @______ notation. One method _______ the functionality of another method.
Subclass
The class which inherits the properties of another class. Also called a child-class.
Superclass
The class whose properties are inherited. Also called a parent-class.
The Diamond Problem
A problem entailing one class inheriting multiple forms of a single method, which is called multiple inherentance. Dealt with by using object associations.
Dependency
Denotes the reliance of one class upon another to work. For example, when a class has a method which uses an instance of another class in its operation.
What are the differences between an abstract class and an interface.
A class can only extend one abstract class, but can extend multiple interfaces. An abstract class can hold non-abstract methods, while an interface cannot. An abstract class can hold instance variables while an interface cannot. An abstract class can have any visibility while an interface must be public. An abstract class can contain constructors while an interface cannot.