Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- class Miner(args: Args) extends Job(args) {
- def fetchUrl(url:String) = {
- ...
- }
- TextLine(args("input")).map(url: String => fetchUrl(url))
- .write(args("output"))
- }
- TextLine(args("input")).map(fetchUrl)
- .write(args("output"))
- val savings =
- items.mapTo(('price, 'discountedPrice) -> 'savings) {
- x : (Float, Float) =>
- val (price, discountedPrice) = x
- price - discountedPrice
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement