id, title, category, status, canonical_id, aliases, duplicate_of, source_trust_level, confidence_score, verification_status, tags, raw_sources, last_reinforced, github_commit, tech_stack
id
title
category
status
canonical_id
aliases
duplicate_of
source_trust_level
confidence_score
verification_status
tags
raw_sources
last_reinforced
github_commit
tech_stack
wiki-2026-0508-object-oriented-programming
Object-Oriented Programming (OOP)
10_Wiki/Topics
verified
self
OOP
Object Oriented Programming
객체지향
객체지향 프로그래밍
none
A
0.95
applied
oop
programming-paradigm
design
architecture
2026-05-10
pending
language
framework
java-typescript-cpp
multi
Object-Oriented Programming (OOP)
매 한 줄
"매 data + behavior를 object로 묶고, polymorphism으로 동작을 추상화하는 패러다임." . Simula 67 (1967) → Smalltalk (1972) → C++ (1985) → Java (1995) → 매 mainstream. 2026 현재는 OO + FP hybrid가 dominant — Java records, Kotlin data class, TypeScript readonly class, Rust trait이 그 증거.
매 핵심
매 4 pillar
Encapsulation : 매 internal state hide, expose behavior — private field + public method.
Inheritance : 매 reuse + specialize — 단 favor composition over inheritance (GoF).
Polymorphism : 매 same interface, different impl — virtual dispatch · duck typing.
Abstraction : 매 essential 만 expose — interface · abstract class.
매 SOLID (Robert C. Martin)
S ingle Responsibility — 매 class one reason to change.
O pen/Closed — 매 extend without modify.
L iskov Substitution — 매 subtype substitutable.
I nterface Segregation — 매 small focused interfaces.
D ependency Inversion — 매 depend on abstraction.
매 응용
Domain-Driven Design — Entity, Value Object, Aggregate.
GUI framework — Component hierarchy (React class component, Qt widget).
Game engine — Entity-Component-System (modern hybrid).
💻 패턴
Encapsulation — invariant 보장
Polymorphism — strategy
Composition over inheritance
Abstract class + template method
Modern hybrid — record (Java 21) / data class
Trait-based OOP (Rust)
매 결정 기준
상황
Approach
Domain with complex invariants
OOP + DDD entities/VO
Pure data transformation
FP (immutable + pure functions)
Plug-in / extensibility
Interface + DI
State machine
OOP class with explicit states
Hot loop, ECS scale
Data-Oriented (avoid virtual dispatch)
기본값 : hybrid OOP+FP — value objects immutable, services with interfaces, pure functions for transforms.
🔗 Graph
🤖 LLM 활용
언제 : business domain modeling, framework/library design, GUI hierarchy, plug-in architecture.
언제 X : hot numerical loop (DOD better), pure transform pipeline (FP cleaner), 1-file script.
❌ 안티패턴
God Object : 매 모든 책임 한 class — SRP 위반.
Anemic Domain Model : data only, behavior in service — OOP 무력화.
Deep inheritance (4+ levels) : 매 fragile base class.
Premature interface : 매 single impl을 interface로 — YAGNI.
Setter everywhere : 매 invariant 깨짐 — immutable + factory.
🧪 검증 / 중복
Verified (GoF Design Patterns 1994, Martin Clean Code 2008, Evans DDD 2003, Java/Kotlin/Rust 2026 docs).
신뢰도 A.
Duplicates: 객체_지향_프로그래밍(OOP).md, 객체_지향_프로그래밍_Object-Oriented_Programming,_OOP.md should redirect here.
🕓 Changelog
날짜
변경
2026-05-08
Phase 1
2026-05-10
Manual cleanup — canonical OOP doc (4 pillars + SOLID + modern hybrid)