Upgrade to Pro — share decks privately, control downloads, hide ads and more …

This Week On Code Hoarders: Declutter Your Codebase With Aspect Oriented Programming

This Week On Code Hoarders: Declutter Your Codebase With Aspect Oriented Programming

How many lines of code in your methods actually contribute to what that method is supposed to do? The clutter of logging, security checks, exception handling, implementing INotifyPropertyChanged and much more can be purged from your methods with Aspect Oriented Programming (AOP) techniques. In this session we will clean up an application to make it more readable, better organized and easier to maintain by using AOP tools to organize the common functionality. What are you waiting for? Come to this session and get that cruft out of your codebase.

Joe Kuemerle

March 19, 2012
Tweet

More Decks by Joe Kuemerle

Other Decks in Programming

Transcript

  1. @jkuemerle / www.kuemerle.com This Week On Code Hoarders: Declutter Your

    Codebase With Aspect Oriented Programming Joe Kuemerle www.kuemerle.com @jkuemerle
  2. @jkuemerle / www.kuemerle.com Joe Kuemerle • Developer at BookingBuilder Technologies

    • Over 15 years of development experience with a broad range of technologies • Focused on application and data security, coding best practices and regulatory compliance • Presenter at community, regional and national events.
  3. @jkuemerle / www.kuemerle.com AOP Terminology • Cross-Cutting Concern: required but

    non core functionality • Advice: the implementation of specific functionality, contained in a module • Join Point: a location to execute an aspect • Pointcut: a set of join points that defines when and where to apply aspects • Aspect: when, where and what to apply in order to accomplish AOP. The combination of the pointcut and advice.
  4. @jkuemerle / www.kuemerle.com • Threading • Transactions • Undo •

    Compile Time Validation • Architecture Validation • Logging • Tracing • Security • Caching • Exception Handling • Functionality Injection o Dirty flags o INotifyPropertyChanged o Parameter validation What can you do with AOP?
  5. @jkuemerle / www.kuemerle.com References • https://bitbucket.org/jkuemerle/aop • http://wpfpasswordgenerator.codeplex.com • http://crosscuttingconcerns.com

    • http://www.sharpcrafters.com/blog • http://ruskin- dantra.blogspot.com/2009/03/inotifypropertychang ed-made-easier.html • http://www.developerfusion.com/article/137636/ta king-the-single-responsibility-principle-seriously • http://www.ibm.com/developerworks/rational/libra ry/mar06/pollice/index.html
  6. @jkuemerle / www.kuemerle.com Photo Credits • http://www.flickr.com/photos/andidigress/4471100232 • http://www.flickr.com/photos/earthworm/5002718047 •

    http://www.flickr.com/photos/profzucker/5845911299 • http://www.flickr.com/photos/29051800@N03/2713792371 • http://www.flickr.com/photos/7891209@N04/2951368555 • http://www.flickr.com/photos/f-oxymoron/5005673112 • http://www.flickr.com/photos/rscwm/6429923619