~/talk

OOP vs Data Oriented Programming: Which One to Choose?

slides:none on file

Compares an order-processor example where extensibility comes from an interface (PaymentMethod using dependency inversion) to a third-party trade example where polymorphic hierarchies are awkward and Java’s newer features—sealed interfaces, records, and pattern matching on records—replace factories and parallel auditor hierarchies. Demonstrates identical behavior but far less boilerplate, immediate compilation errors when a new trade subtype appears, and recommends OOP when owning the hierarchy and data-oriented patterns when processing external data, favoring polymorphism or data patterns by context.

AI-written summary · about

  1. 0:00Introduction to OOP vs DOP
  2. 10:40Essence of OOP with polymorphism
  3. 20:38Challenges with third-party classes
  4. 33:14Parallel hierarchy problems
  5. 43:55Data-oriented approach with pattern matching
  6. 54:28Pros and cons of DOP
  7. 59:37Choosing simplicity over dogma
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.