The constructor reference, which is a special type of method reference, when used for functional programming is evaluated without any explicit definition of abstract method declared in the Functional interface. Can you help me with the intricacies of how it's being resolved or linked? In particular to the following program how the empFactory object is evaluated?
public class Employee{
String name;
Integer age;
public Employee(String name, Integer age){
this.name=name;
this.age=age;
}
}
public interface EmployeeFactory{
public abstract Employee getEmployee(String name, Integer age);
}
public class Run{
public static void main(String... args){
EmployeeFactory empFactory=Employee::new;
Employee emp= empFactory.getEmployee("Ammy Sen", 25);
}
}