A reference to a static method such as Math::max or Integer::parseInt maps its parameters directly onto the functional interface's parameters, with no implicit receiver involved.
BiFunction<Integer, Integer, Integer> max = Math::max;
System.out.println("max.apply(3, 9) = " + max.apply(3, 9));
Function<String, Integer> parse = Integer::parseInt;
System.out.println("parse.apply(\"123\") = " + parse.apply("123"));
max.apply(3, 9) = 9
parse.apply("123") = 123
Run this yourself in the Online Java Compiler, spin up a live REST API in the API Sandbox, or practise with Java interview questions.
Published 2026-09-27