Object-Oriented Programming [Java]

0.0(0)
studied byStudied by 0 people
full-widthCall with Kai
GameKnowt Play
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
Card Sorting

1/48

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.

49 Terms

1
New cards

Three Fundamental Features of OOP

Encapsulation

Inheritance

Polymorphism

2
New cards

Encapsulation

An object-oriented technique in which the internal details of an object are "hidden" in order to simplify their use and reuse.

3
New cards

Inheritance

A relationship between two classes in which one class ( the subclass) inherits all of the properties and capabilities of another ( the superclass)

4
New cards

Polymorphism

Declaring a variable to have one type while it refers to an object of a subclass of that type.

5
New cards

Object-Oriented Analysis

A means of determining what aspects of a given problem can be viewed as objects in an eventual object-oriented design.

6
New cards

Object-Oriented Design

A software design method that models the characteristics of abstract or real objects using classes and objects.

7
New cards

Object-Oriented Programming

A programming technique that features objects, classes, encapsulation, interfaces, polymorphism, and inheritance.

8
New cards

Cohesion

Degree to which responsibilities of a given component are a meaningful unit

9
New cards

Cohesion vs Coupling

Greater cohesion reflects better design. Less coupling reflects better design.

10
New cards

Coupling

Degree to which one component must directly access the data of another component.

11
New cards

Roles

Sets of Responsibilities

12
New cards

Roles vs. Objects

They are the same when a given role is always played by the same object type.

13
New cards

Software Components

Reuse of code (e.g. Visual Basic, JavaBean)

14
New cards

Frameworks

Reuse of "plug-in" code (e.g. Java Swing)

15
New cards

Design Paterns

Reuse of Design

16
New cards

Agile Software Development

A philosophy of software development that embraces flexibility and agility. The design "evolves".

17
New cards

3 Means of Object-Object Access

- Parameter Passing

- Object declared in method

- Object is a member of another object through composition [subtype]

18
New cards

Is-a Relationship

Describes an inheritance relationship between two classes

19
New cards

Has-a Relationship

The relationship demonstrated by a class that contains another class.

20
New cards

Uses-a Relationship

Implemented-In-Terms-Of Relationship

21
New cards

Static Members

Known as "class variables", because there is only one unique value for all the objects of that same class.

22
New cards

This

Special reference that refers to the object in which it is used.

23
New cards

Super

Special reference that refers to the superclass of the object in which it is used.

24
New cards

Liskov Substitution Principle

Determine whether a subclass is a subtype

25
New cards

Protected Access

No outside classes can use this data field, except descendant classes. Defeats the purpose of OOP.

26
New cards

Upcasting

Type cast to the type of an ancestor class. Is usually done automatically.

27
New cards

Downcasting

Type cast to the type of a descendant class; may cause runtime errors.

28
New cards

Interfaces

A purely abstract class. Can only contain constants and method signatures.

29
New cards

Marker Interface

An interface with no methods or fields

30
New cards

Use Case Diagram

UML diagram that captures all actors (an individual or another system) and use cases involved with a system or product. Used to model user requirements.

31
New cards

Use Case

Functional requirement of a system as a sequence of steps.

32
New cards

Generalization (Base Use Case)

A way to indicate that a given use case is a variation of, or specific version of, another use case. [Closed Unfilled Arrow]

33
New cards

Extension

A way to indicate limited ways a use case can vary (e.g. Delete Message, current or all?) <>

34
New cards

Includes

A way to indicate steps that occur in more than one scenario. (e.g. Validate Pin)<>

35
New cards

Associated Scenario

The detailed steps of a use case.

36
New cards

Class Diagram

A visual representation of the relationships between classes.

37
New cards

Composition

Represents real-world whole-part relationships, e.g., an engine is a part of a car

38
New cards

Aggregation

Represents a class as a collection or container of other classes.

39
New cards

Dependency

Used to show that some UML element or a set of elements requires, needs or depends on other model elements for specification or implementation

40
New cards

Multiplicity

Minimum and maximum number of occurrences of one object for a single occurrence of related object

41
New cards

Role Name

Signifies the role that a participating entity type plays in each relationship instance. In some cases the same entity type participates more than once in a relationship type in different roles.

42
New cards

Sequence Diagram

A type of diagram that shows objects participating in interactions and the messages exchanged between them.

43
New cards

Singleton Pattern

This pattern ensures you have at most one instance of a class in your application

44
New cards

Iterator Pattern

The design pattern that provides a way to access the elements of an aggregate object sequentially without exposing the underlying representation.

45
New cards

Adapter Pattern

The design pattern that translates one interface for a class into a compatible interface.

46
New cards

Facade Pattern

Simplifies the interface of a group of classes. Hides the complexity of one or more classes behind a clean, well-lit facade. Makes an interface simple. Provides a unified interface to a set of interfaces in a subsystem.

47
New cards

Object-Oriented Analysis Stage

Determines the requirements of a system

Focus on what needs to be done (not how)

Carried out by a team of analysts

End product is a conceptual model

48
New cards

5 Design Principles

1) Major subsystems should be loosely coupled, allowing independence

2) Many-to-many relationships require an additional class

3) Avoid exposing details of business logic implementation to the user interface

4) Avoid exporting mutable objects

5) Avoid importing objects of an internal type in the system

49
New cards

Law of Demeter

"Single Dot Rule"

Long lists of method calls are attributed to bad design