title: Play 2 - How to set default value of template's parameter from Java controller?
body: <p>Is it possible to define optional parameter when rendering an scala template in Play Framework 2? </p>
  
  <p>My controller looks like this:</p>
  
  <pre><code>public static Result recoverPassword() {
      Form&lt;RecoveryForm&gt; resetForm = form(RecoveryForm.class);
      return ok(recover.render(resetForm));
      // On success I'd like to pass an optional parameter:
      // return ok(recover.render(resetForm, true));
  }
  </code></pre>
  
  <p>My Scala template looks like this:</p>
  
  <pre><code>@(resetForm: Form[controllers.Account.RecoveryForm], success:Boolean = false)
  </code></pre>
  
  <p>Also tried:</p>
  
  <pre><code>@(resetForm: Form[controllers.Account.RecoveryForm]) (success:Boolean = false)
  </code></pre>
  
  <p>In both cases i got "error: method render in class recover cannot be applied to given types;"</p>