code: public static <T> T eachLine(File self, @ClosureParams(value = FromString.class, options = {"String", "String,Integer"}) Closure<T> closure) throws IOException {
          return eachLine(self, 1, closure);
      }
docs: Iterates through this file line by line.  Each line is passed to the
  given 1 or 2 arg closure.  The file is read using a reader which
  is closed before this method returns.
  
  @param self    a File
  @param closure a closure (arg 1 is line, optional arg 2 is line number starting at line 1)
  @return the last value returned by the closure
  @throws IOException if an IOException occurs.
  @see #eachLine(java.io.File, int, groovy.lang.Closure)
  @since 1.5.5