Skip to content

Closures

Philip Ford edited this page Jan 15, 2017 · 30 revisions
  • Contained in braces

  • They are functions.

  • Used in callbacks

  • The default parameter (if you do not provide parameters) is it.

    [1,2,3].each {
       println it
    }

Clone this wiki locally