title: How do I define a method which takes a lambda as a parameter in Java 8?
body: <p>In Java 8, methods can be created as Lambda expressions and can be passed by reference (with a little work under the hood). There are plenty of examples online with lambdas being created and used with methods, but no examples of how to make a method taking a lambda as a parameter. What is the syntax for that?</p>
  
  <pre><code>MyClass.method((a, b) -&gt; a+b);
  
  
  class MyClass{
    //How do I define this method?
    static int method(Lambda l){
      return l(5, 10);
    }
  }
  </code></pre>