{{theTime}}

Search This Blog

Total Pageviews

What is a Java Functional Interface

A functional interface is an interface with a single abstract method. Also know as SAM (Single Abstract Method) types.

Examples:

public interface Comparator<T> {
    int compare(T o1, T o2);
}

public interface Callable<V> {
    V call() throws Exception;
}

public interface ActionListener extends EventListener {
    public void actionPerformed(ActionEvent e);
}

public interface Runnable {
    public void run();
}

No comments:

Cucumber Eclipse sample program

Cucumber Eclipse SetupCreate Eclipse Maven Project Open pom.xml Goto Dependencies Add GroupId: info.cukes, Artifact Id: cucumber-java, Versi...