How to use lambdas in "template"
First, lets use inheritance. We will inherit the specific event types from the event interface.
interface Event {}

class EventType1 implements Event{}

class EventType2 implements Event{}

Secondly, lets define the type of functions that we will call in the handleEvent() method. In this case it is Consumer&lt;Event&gt;
Now our handleEvent() function will look like this
void handleEvent(Event event, 
                 Consumer&lt;Event&gt; option1, 
                 Consumer&lt;Event&gt; option2) {
   if (someCheck()) {
      option1.accept(event);
   } else {
       option2.accept(event);
   }
}


Now we can call this function and pass instance of event interface and two lambdas or method references
Handler.handleEvent(new EventType1(),
    event -&gt; {
       //do something
    }, 
    event -&gt; {
       //do something else;
    });
}