Nicolai Parlog
Data-Oriented Programming - Version 1.1
#1about 2 minutes
Introducing the four principles of data-oriented programming
Data-oriented programming (DOP) is a paradigm that models programs as a series of transformations on data, guided by four key principles.
#2about 5 minutes
Modeling a GitHub crawler page type example
An example of a GitHub crawler is used to explore how to model a complex page data type with various states and required operations.
#3about 2 minutes
Using Java records for immutable and transparent data
Java records are the ideal choice for modeling immutable data, and compact constructors can be used to ensure deep immutability for collection fields.
#4about 3 minutes
Modeling data alternatives using sealed interfaces and records
Sealed interfaces create a closed type hierarchy, allowing you to precisely model "either/or" relationships between different record types representing distinct data states.
#5about 3 minutes
How to make illegal data states unrepresentable
By combining a precise type hierarchy with validation in record constructors, you can prevent the creation of invalid object states within your domain model.
#6about 6 minutes
Separating operations from data using pattern matching
Operations are moved out of data records and implemented externally using switch expressions with pattern matching to deconstruct and act on the data.
#7about 4 minutes
Ensuring maintainability with compiler exhaustiveness checks
Switching over sealed types is safe because the compiler enforces exhaustiveness, issuing a compile error if a new subtype is added but not handled.
#8about 3 minutes
Comparing data-oriented programming to the visitor pattern
Data-oriented programming provides a more ergonomic alternative to the classic visitor pattern and is useful for modeling complex return types.
Related jobs
Jobs that call for the skills explored in this talk.
tree-IT GmbH
Bad Neustadt an der Saale, Germany
€54-80K
Intermediate
Senior
Java
TypeScript
+1
Matching moments
03:31 MIN
The value of progressive enhancement and semantic HTML
WeAreDevelopers LIVE – You Don’t Need JavaScript, Modern CSS and More
02:33 MIN
Why you might not need JavaScript for everything
WeAreDevelopers LIVE – You Don’t Need JavaScript, Modern CSS and More
08:07 MIN
Exploring modern JavaScript performance and new CSS features
WeAreDevelopers LIVE – AI, Freelancing, Keeping Up with Tech and More
05:28 MIN
The origin story of the Polypane developer browser
Developer Time Is Valuable - Use the Right Tools - Kilian Valkhof
05:12 MIN
How to build structure and culture without killing agility
From Data Keeper to Culture Shaper: The Evolution of HR Across Growth Stages
03:16 MIN
Improving the developer feedback loop with specialized tools
Developer Time Is Valuable - Use the Right Tools - Kilian Valkhof
09:00 MIN
Navigating the growing complexity of modern CSS
WeAreDevelopers LIVE – You Don’t Need JavaScript, Modern CSS and More
02:49 MIN
Using AI to overcome challenges in systems programming
AI in the Open and in Browsers - Tarek Ziadé
Featured Partners
Related Videos
Algebraic Data Types + Pattern Matching = Elegant and readable Java code
Balkrishna Rawool
OOP revisited
Dominik Przybysz
Modern Java: This is not your father's Java anymore
Ron Veen
Modern Java 25
Ron Veen
Typed Security: Preventing Vulnerabilities By Design
Michael Koppmann
Using Java 17 latest features in real world projects
Ron Veen
10 must-know design patterns for JS Devs
Erick Wendel
Java with a Clojure mindset
Dan Lebrero
Related Articles
View all articles



From learning to earning
Jobs that call for the skills explored in this talk.



Paradigma Digital
Municipality of Madrid, Spain
Java
Azure
Microservices
Amazon Web Services (AWS)




APRIORI - business solutions AG
Berlin, Germany
ETL
Groovy
Data analysis

Paradigma Digital
Municipality of Pozuelo de Alarcón, Spain
ETL
Azure
NoSQL
Data analysis
Machine Learning
+3
