Partial application and currying are techniques that allow you to pass arguments to a function one by one. Learn why and how to perform these techniques in Java.
- The first advanced concept we're going to look at here … is called partial application. … So what is partial application? … Well, in simple terms, … partial application is when we take a function … that has some number of arguments, … and we fix some of those arguments to a set value. … This function with fixed arguments … can then be called from anywhere else in the code, … and it will be as if we had called the original function … with all of its arguments. … Another way to think about it as like this. … Normally when we call a function … we have to pass all the arguments into it … at the same exact time and place. … What partial application allows us to do, … is pass arguments to a function … at different places in the code and then get the result … once the function gets all of the arguments it needs. … Now, partial application is also a very useful way … to configure more general functions into more specific ones. … In general, if there's a function … that we use often in our code …
Skill Level Advanced
Java Design Patterns: Structuralwith Bethan Palmer1h 38m Intermediate
1. Introduction to Functional Programming
2. First-Class Functions
3. Working with Streams in Java
4. Advanced Concepts
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.