Skip to content

Instantly share code, notes, and snippets.

@EwanDawson
Created July 19, 2017 03:31
Show Gist options
  • Save EwanDawson/08812b620aa3476342c30bf82b02f120 to your computer and use it in GitHub Desktop.
Save EwanDawson/08812b620aa3476342c30bf82b02f120 to your computer and use it in GitHub Desktop.
Transform a collection by applying a function to each element
//Transform collection in payload[0]
//by passing element to script named in payload[1]
payload[0]
.collect { invoke(payload[1], it) }
.collect { it.get() }
_Sent from my OnePlus ONEPLUS A5000 using [FastHub](https://play.google.com/store/apps/details?id=com.fastaccess.github)_
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment