Function currying
Upcoming SlideShare
Loading in...5
×
 

Like this? Share it with your network

Share

Function currying

on

  • 2,610 views

Understanding and using Function Currying for AS3 and javascript developers.

Understanding and using Function Currying for AS3 and javascript developers.

Statistics

Views

Total Views
2,610
Views on SlideShare
550
Embed Views
2,060

Actions

Likes
0
Downloads
2
Comments
0

5 Embeds 2,060

http://www.gridlinked.info 1916
http://solutionoptimist.com 135
http://www.linkedin.com 6
https://www.linkedin.com 2
http://webcache.googleusercontent.com 1

Accessibility

Categories

Upload Details

Uploaded via as Adobe PDF

Usage Rights

CC Attribution-NonCommercial LicenseCC Attribution-NonCommercial License

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment

Function currying Presentation Transcript

  • 1. Understanding Function Currying Javascript / AS3 Thomas Burleson Digital Solutions ArchitectSunday, April 29, 12
  • 2. Anonymous Functions Closures Function Currying Partial ApplicationsSunday, April 29, 12
  • 3. Function Currying: Combine function with variables to create new function. Variables are cached [captured] as function arguments Outer variables are accessed via closure scope by inner FunctionSunday, April 29, 12
  • 4. But how/why do we use Function Currying Explore existing Javascript code Refactor code (to remove verbosity) Apply DRY concept Concise Code, Easy MaintenanceSunday, April 29, 12
  • 5. Refactoring with DRY Existing Code Anonymous Functions Closures Function CurryingSunday, April 29, 12
  • 6. REST Service (asynchronous)Sunday, April 29, 12
  • 7. Not DRY Verbose! Difficult to maintainSunday, April 29, 12
  • 8. Uses function currying at two (2) levels : onSuccess() forClass()Sunday, April 29, 12
  • 9. Video Tutorial (click to run) (click to download) Source CodeSunday, April 29, 12