SlideShare una empresa de Scribd logo
1 de 16
Aspect-Oriented 
Programming 
How can aspects clean your code? 
@BasiaFusinska
Aspect-Oriented Programming How can aspects clean your code? 2 
About me 
Programmer 
@basiafusinska 
Architect 
Coach 
Manager 
Teacher 
Trainer
Aspect-Oriented Programming How can aspects clean your code? 
Agenda 
3 
❖ What the hell...are aspects? 
❖ Some examples of AOP 
❖ Demo 1: refactor your way to aspects 
❖ Every-day aspects 
❖ Demo 2: some not-so-obvious aspects 
❖ How to test aspects 
❖ Demo 3: testing in practice 
❖ Q & A
Aspect-Oriented Programming How can aspects clean your code? 
Some history 
4 
❖ Gregor Kiczales (1997), Xerox PARC 
❖ OOP is unable to solve some common problems 
❖ Aspects encapsulate cross-cutting concerns and make them easier to 
reuse
Aspect-Oriented Programming How can aspects clean your code? 
Cross cutting concerns 
5 
❖ Cross-cutting concerns are scattered throughout the code 
❖ Code becomes difficult to develop and modify 
❖ Code breaks the Single Responsibility Principle
Aspect-Oriented Programming How can aspects clean your code? 
Cross-cutting concerns are everywhere! 
7 
❖ Logging 
❖ Validation 
❖ Persistence 
❖ Caching 
❖ Synchronization 
❖ Transactions 
❖ Exception handling 
❖ Authentication 
❖ Authorization 
❖ ...
Aspect-Oriented Programming How can aspects clean your code? 
What the heck are aspects? 
6 
❖ Purpose: cross-cutting concerns – pieces of functionality used across 
multiple parts of a system 
❖ Job: the advice – code that performs cross-cutting concern 
❖ Map: pointcut – set of joinpoints 
❖ How: weaving
Aspect-Oriented Programming How can aspects clean your code? 6 
How it works?
Aspect-Oriented Programming How can aspects clean your code? 
Types of advices? 
6 
❖ Entry 
❖ Exit 
❖ Exception 
❖ Success 
❖ Around 
❖ Method boundaries vs method interceptions
Aspect-Oriented Programming How can aspects clean your code? 
Some benefits of AOP 
8 
❖ Code is cleaner 
❖ DRY (Don’t Repeat Yourself): promotes code reuse 
❖ Better encapsulation
9 
Aspect-Oriented Programming How can aspects clean your code? 
Demonstration #1 
Refactor your way to aspects
Aspect-Oriented Programming How can aspects clean your code? 
You’ve been using AOP without knowing it 
10 
❖ IHttpModule - requests boundary aspects 
❖ IActionFilter - code run before and after the action execution 
❖ ASP.Net MVC Authentication - AuthorizeAttribute 
❖ Actions per request (Session Open/Close, ORM changes saving)
11 
Aspect-Oriented Programming How can aspects clean your code? 
Demonstration #2 
Some not-so-obvious aspects
Aspect-Oriented Programming How can aspects clean your code? 
Testing aspects 
12 
❖ Testing the pointcut – testing if aspects were used in correct places 
❖ Testing the advice – testing if the aspects are doing what they are 
supposed to do
13 
Aspect-Oriented Programming How can aspects clean your code? 
Demonstration #3 
Testing aspects
Thank you :) 
Any questions? 
@basiafusinska 
barbarafusinska.co 
m

Más contenido relacionado

La actualidad más candente

Coding Dojo: Mars Rover (2014)
Coding Dojo: Mars Rover (2014)Coding Dojo: Mars Rover (2014)
Coding Dojo: Mars Rover (2014)Peter Kofler
 
Devoxx 2013 Summary/Keynotes
Devoxx 2013 Summary/KeynotesDevoxx 2013 Summary/Keynotes
Devoxx 2013 Summary/KeynotesAliaksandr Kazlou
 
Software Craftsmanship Journeyman Tour (2013)
Software Craftsmanship Journeyman Tour (2013)Software Craftsmanship Journeyman Tour (2013)
Software Craftsmanship Journeyman Tour (2013)Peter Kofler
 
London SDET Meetup main presentation - How SDET can transform your organisati...
London SDET Meetup main presentation - How SDET can transform your organisati...London SDET Meetup main presentation - How SDET can transform your organisati...
London SDET Meetup main presentation - How SDET can transform your organisati...Sriram Angajala
 
Futuristic programing language
Futuristic programing languageFuturistic programing language
Futuristic programing languageMohamed Zaki
 
Idiomatic R for Rosetta Code (2013)
Idiomatic R for Rosetta Code (2013)Idiomatic R for Rosetta Code (2013)
Idiomatic R for Rosetta Code (2013)Peter Kofler
 
TSC Summit #3 - Reverse engineering and anti debugging techniques
TSC Summit #3 - Reverse engineering and anti debugging techniquesTSC Summit #3 - Reverse engineering and anti debugging techniques
TSC Summit #3 - Reverse engineering and anti debugging techniquesMikal Villa
 
Developing documentation for RESTful APIs: how to kill three birds with one s...
Developing documentation for RESTful APIs: how to kill three birds with one s...Developing documentation for RESTful APIs: how to kill three birds with one s...
Developing documentation for RESTful APIs: how to kill three birds with one s...Ilya Chesnokov
 
Coding Dojo Object Calisthenics (2016)
Coding Dojo Object Calisthenics (2016)Coding Dojo Object Calisthenics (2016)
Coding Dojo Object Calisthenics (2016)Peter Kofler
 
Code Retreat Venice (2016)
Code Retreat Venice (2016)Code Retreat Venice (2016)
Code Retreat Venice (2016)Peter Kofler
 
GDG Passo fundo - Apps with unit tests (Karma + jasmine + angular)
GDG Passo fundo - Apps with unit tests (Karma + jasmine + angular)GDG Passo fundo - Apps with unit tests (Karma + jasmine + angular)
GDG Passo fundo - Apps with unit tests (Karma + jasmine + angular)Matheus Marabesi
 
Designing Test Cases for the Gilded Rose Kata (2013)
Designing Test Cases for the Gilded Rose Kata (2013)Designing Test Cases for the Gilded Rose Kata (2013)
Designing Test Cases for the Gilded Rose Kata (2013)Peter Kofler
 
Oleksii Pedorenko and Dmytro Melnychuk "DAO Project Experience"
Oleksii Pedorenko and Dmytro Melnychuk "DAO Project Experience"Oleksii Pedorenko and Dmytro Melnychuk "DAO Project Experience"
Oleksii Pedorenko and Dmytro Melnychuk "DAO Project Experience"LogeekNightUkraine
 
Understand Java for Android the Hard Way
Understand Java for Android the Hard WayUnderstand Java for Android the Hard Way
Understand Java for Android the Hard WayGlobalLogic Ukraine
 
Coding Dojo: Functional Calisthenics (2016)
Coding Dojo: Functional Calisthenics (2016)Coding Dojo: Functional Calisthenics (2016)
Coding Dojo: Functional Calisthenics (2016)Peter Kofler
 
Brutal Coding Constraints (ITAKE 2017)
Brutal Coding Constraints (ITAKE 2017)Brutal Coding Constraints (ITAKE 2017)
Brutal Coding Constraints (ITAKE 2017)Peter Kofler
 
Coding Dojo: Asynchronous Clock-In (2016)
Coding Dojo: Asynchronous Clock-In (2016)Coding Dojo: Asynchronous Clock-In (2016)
Coding Dojo: Asynchronous Clock-In (2016)Peter Kofler
 
Integration of automation framework with ci tools
Integration of automation framework with ci toolsIntegration of automation framework with ci tools
Integration of automation framework with ci toolsvodQA
 

La actualidad más candente (20)

Coding Dojo: Mars Rover (2014)
Coding Dojo: Mars Rover (2014)Coding Dojo: Mars Rover (2014)
Coding Dojo: Mars Rover (2014)
 
Devoxx 2013 Summary/Keynotes
Devoxx 2013 Summary/KeynotesDevoxx 2013 Summary/Keynotes
Devoxx 2013 Summary/Keynotes
 
Software Craftsmanship Journeyman Tour (2013)
Software Craftsmanship Journeyman Tour (2013)Software Craftsmanship Journeyman Tour (2013)
Software Craftsmanship Journeyman Tour (2013)
 
London SDET Meetup main presentation - How SDET can transform your organisati...
London SDET Meetup main presentation - How SDET can transform your organisati...London SDET Meetup main presentation - How SDET can transform your organisati...
London SDET Meetup main presentation - How SDET can transform your organisati...
 
Futuristic programing language
Futuristic programing languageFuturistic programing language
Futuristic programing language
 
Idiomatic R for Rosetta Code (2013)
Idiomatic R for Rosetta Code (2013)Idiomatic R for Rosetta Code (2013)
Idiomatic R for Rosetta Code (2013)
 
TSC Summit #3 - Reverse engineering and anti debugging techniques
TSC Summit #3 - Reverse engineering and anti debugging techniquesTSC Summit #3 - Reverse engineering and anti debugging techniques
TSC Summit #3 - Reverse engineering and anti debugging techniques
 
Developing documentation for RESTful APIs: how to kill three birds with one s...
Developing documentation for RESTful APIs: how to kill three birds with one s...Developing documentation for RESTful APIs: how to kill three birds with one s...
Developing documentation for RESTful APIs: how to kill three birds with one s...
 
Coding Dojo Object Calisthenics (2016)
Coding Dojo Object Calisthenics (2016)Coding Dojo Object Calisthenics (2016)
Coding Dojo Object Calisthenics (2016)
 
Api NodeJS con PureScript
Api NodeJS con PureScriptApi NodeJS con PureScript
Api NodeJS con PureScript
 
Code Retreat Venice (2016)
Code Retreat Venice (2016)Code Retreat Venice (2016)
Code Retreat Venice (2016)
 
GDG Passo fundo - Apps with unit tests (Karma + jasmine + angular)
GDG Passo fundo - Apps with unit tests (Karma + jasmine + angular)GDG Passo fundo - Apps with unit tests (Karma + jasmine + angular)
GDG Passo fundo - Apps with unit tests (Karma + jasmine + angular)
 
Designing Test Cases for the Gilded Rose Kata (2013)
Designing Test Cases for the Gilded Rose Kata (2013)Designing Test Cases for the Gilded Rose Kata (2013)
Designing Test Cases for the Gilded Rose Kata (2013)
 
Oleksii Pedorenko and Dmytro Melnychuk "DAO Project Experience"
Oleksii Pedorenko and Dmytro Melnychuk "DAO Project Experience"Oleksii Pedorenko and Dmytro Melnychuk "DAO Project Experience"
Oleksii Pedorenko and Dmytro Melnychuk "DAO Project Experience"
 
Understand Java for Android the Hard Way
Understand Java for Android the Hard WayUnderstand Java for Android the Hard Way
Understand Java for Android the Hard Way
 
Aspect Oriented Programing - Introduction
Aspect Oriented Programing - IntroductionAspect Oriented Programing - Introduction
Aspect Oriented Programing - Introduction
 
Coding Dojo: Functional Calisthenics (2016)
Coding Dojo: Functional Calisthenics (2016)Coding Dojo: Functional Calisthenics (2016)
Coding Dojo: Functional Calisthenics (2016)
 
Brutal Coding Constraints (ITAKE 2017)
Brutal Coding Constraints (ITAKE 2017)Brutal Coding Constraints (ITAKE 2017)
Brutal Coding Constraints (ITAKE 2017)
 
Coding Dojo: Asynchronous Clock-In (2016)
Coding Dojo: Asynchronous Clock-In (2016)Coding Dojo: Asynchronous Clock-In (2016)
Coding Dojo: Asynchronous Clock-In (2016)
 
Integration of automation framework with ci tools
Integration of automation framework with ci toolsIntegration of automation framework with ci tools
Integration of automation framework with ci tools
 

Destacado

4. arteria carotida externa
4. arteria carotida externa4. arteria carotida externa
4. arteria carotida externaanatogral
 
Predicting the Future as a Service with Azure ML and R
Predicting the Future as a Service with Azure ML and R Predicting the Future as a Service with Azure ML and R
Predicting the Future as a Service with Azure ML and R Barbara Fusinska
 
Sveriges politiska partier
Sveriges politiska partierSveriges politiska partier
Sveriges politiska partierMikael Lärare
 
Hb networking 2014
Hb networking 2014Hb networking 2014
Hb networking 2014suzcarle
 
Clip voor altijd in mijn hart
Clip voor altijd in mijn hartClip voor altijd in mijn hart
Clip voor altijd in mijn hartTrees van Dijk
 
남동구 라선거구 최승원
남동구 라선거구 최승원남동구 라선거구 최승원
남동구 라선거구 최승원승원 최
 
The Pub Digital Press Kit
The Pub Digital Press KitThe Pub Digital Press Kit
The Pub Digital Press KitTRG2014
 
Aldenmc capabilities 05-12-14-cc
Aldenmc capabilities 05-12-14-ccAldenmc capabilities 05-12-14-cc
Aldenmc capabilities 05-12-14-ccaldenmarcom
 
新規 Microsoft power point presentation
新規 Microsoft power point presentation新規 Microsoft power point presentation
新規 Microsoft power point presentationAkira Sawada
 
5. arteria carotida int.
5. arteria carotida int.5. arteria carotida int.
5. arteria carotida int.anatogral
 
Nft Distribution Holdings interview questions and answers
Nft Distribution Holdings interview questions and answersNft Distribution Holdings interview questions and answers
Nft Distribution Holdings interview questions and answersmayanevaeh121
 
Go Green Go Cozmo (Jordan)
Go Green Go Cozmo (Jordan) Go Green Go Cozmo (Jordan)
Go Green Go Cozmo (Jordan) Amanda Haddad
 
Getting started with R when analysing GitHub commits
Getting started with R when analysing GitHub commitsGetting started with R when analysing GitHub commits
Getting started with R when analysing GitHub commitsBarbara Fusinska
 
Norland Managed Services interview questions and answers
Norland Managed Services interview questions and answersNorland Managed Services interview questions and answers
Norland Managed Services interview questions and answersmayanevaeh121
 
Group 13 Fracking and Silica Dust Exposure
Group 13  Fracking and Silica Dust ExposureGroup 13  Fracking and Silica Dust Exposure
Group 13 Fracking and Silica Dust ExposureAndres Guerrero
 

Destacado (20)

4. arteria carotida externa
4. arteria carotida externa4. arteria carotida externa
4. arteria carotida externa
 
Predicting the Future as a Service with Azure ML and R
Predicting the Future as a Service with Azure ML and R Predicting the Future as a Service with Azure ML and R
Predicting the Future as a Service with Azure ML and R
 
Sveriges politiska partier
Sveriges politiska partierSveriges politiska partier
Sveriges politiska partier
 
Hb networking 2014
Hb networking 2014Hb networking 2014
Hb networking 2014
 
Heart buddy
Heart buddyHeart buddy
Heart buddy
 
Clip voor altijd in mijn hart
Clip voor altijd in mijn hartClip voor altijd in mijn hart
Clip voor altijd in mijn hart
 
남동구 라선거구 최승원
남동구 라선거구 최승원남동구 라선거구 최승원
남동구 라선거구 최승원
 
The Pub Digital Press Kit
The Pub Digital Press KitThe Pub Digital Press Kit
The Pub Digital Press Kit
 
Aldenmc capabilities 05-12-14-cc
Aldenmc capabilities 05-12-14-ccAldenmc capabilities 05-12-14-cc
Aldenmc capabilities 05-12-14-cc
 
Heart buddy
Heart buddyHeart buddy
Heart buddy
 
新規 Microsoft power point presentation
新規 Microsoft power point presentation新規 Microsoft power point presentation
新規 Microsoft power point presentation
 
When the connection fails
When the connection failsWhen the connection fails
When the connection fails
 
5. arteria carotida int.
5. arteria carotida int.5. arteria carotida int.
5. arteria carotida int.
 
Nft Distribution Holdings interview questions and answers
Nft Distribution Holdings interview questions and answersNft Distribution Holdings interview questions and answers
Nft Distribution Holdings interview questions and answers
 
Go Green Go Cozmo (Jordan)
Go Green Go Cozmo (Jordan) Go Green Go Cozmo (Jordan)
Go Green Go Cozmo (Jordan)
 
When the connection fails
When the connection failsWhen the connection fails
When the connection fails
 
Getting started with R when analysing GitHub commits
Getting started with R when analysing GitHub commitsGetting started with R when analysing GitHub commits
Getting started with R when analysing GitHub commits
 
Norland Managed Services interview questions and answers
Norland Managed Services interview questions and answersNorland Managed Services interview questions and answers
Norland Managed Services interview questions and answers
 
Group 13 Fracking and Silica Dust Exposure
Group 13  Fracking and Silica Dust ExposureGroup 13  Fracking and Silica Dust Exposure
Group 13 Fracking and Silica Dust Exposure
 
Ekologiska fotavtryck
Ekologiska fotavtryckEkologiska fotavtryck
Ekologiska fotavtryck
 

Similar a How aspects clean your code

Solve cross cutting concerns with aspect oriented programming (aop)
Solve cross cutting concerns with aspect oriented programming (aop)Solve cross cutting concerns with aspect oriented programming (aop)
Solve cross cutting concerns with aspect oriented programming (aop)Siva Prasad Rao Janapati
 
2R-3KS03-OOP_UNIT-I (Part-A)_2023-24.pptx
2R-3KS03-OOP_UNIT-I (Part-A)_2023-24.pptx2R-3KS03-OOP_UNIT-I (Part-A)_2023-24.pptx
2R-3KS03-OOP_UNIT-I (Part-A)_2023-24.pptxGauravGamer2
 
Linters for frontend code review
Linters for frontend code reviewLinters for frontend code review
Linters for frontend code reviewVsevolod Nechaev
 
Aspect Oriented Programming
Aspect Oriented ProgrammingAspect Oriented Programming
Aspect Oriented ProgrammingAnumod Kumar
 
The Past, Present, and Future of OpenACC
The Past, Present, and Future of OpenACCThe Past, Present, and Future of OpenACC
The Past, Present, and Future of OpenACCinside-BigData.com
 
Be armed to the teeth to maintain a high quality iOS code
Be armed to the teeth to maintain a high quality iOS codeBe armed to the teeth to maintain a high quality iOS code
Be armed to the teeth to maintain a high quality iOS codeAnastasia Kazakova
 
How to Embed Codeless Test Automation Into DevOps
How to Embed Codeless Test Automation Into DevOpsHow to Embed Codeless Test Automation Into DevOps
How to Embed Codeless Test Automation Into DevOpsPerfecto by Perforce
 
Unit 1 introduction to c++.pptx
Unit 1 introduction to c++.pptxUnit 1 introduction to c++.pptx
Unit 1 introduction to c++.pptxshashiden1
 
DYNAMIC SLICING OF ASPECT-ORIENTED PROGRAMS
DYNAMIC SLICING OF ASPECT-ORIENTED PROGRAMSDYNAMIC SLICING OF ASPECT-ORIENTED PROGRAMS
DYNAMIC SLICING OF ASPECT-ORIENTED PROGRAMSPraveen Penumathsa
 
DYNAMIC SLICING OF ASPECT-ORIENTED PROGRAMS
DYNAMIC SLICING OF ASPECT-ORIENTED PROGRAMSDYNAMIC SLICING OF ASPECT-ORIENTED PROGRAMS
DYNAMIC SLICING OF ASPECT-ORIENTED PROGRAMSPraveen Penumathsa
 
Pointcut Rejuvenation: Recovering Pointcut Expressions in Evolving Aspect-Ori...
Pointcut Rejuvenation: Recovering Pointcut Expressions in Evolving Aspect-Ori...Pointcut Rejuvenation: Recovering Pointcut Expressions in Evolving Aspect-Ori...
Pointcut Rejuvenation: Recovering Pointcut Expressions in Evolving Aspect-Ori...Raffi Khatchadourian
 
Dealing With Legacy: The Real-World Experience
Dealing With Legacy: The Real-World ExperienceDealing With Legacy: The Real-World Experience
Dealing With Legacy: The Real-World ExperienceJakub Holy
 
Software Defect Prevention via Continuous Inspection
Software Defect Prevention via Continuous InspectionSoftware Defect Prevention via Continuous Inspection
Software Defect Prevention via Continuous InspectionJosh Gough
 
Developer Job in Practice
Developer Job in PracticeDeveloper Job in Practice
Developer Job in Practiceintive
 
The View - Lotusscript coding best practices
The View - Lotusscript coding best practicesThe View - Lotusscript coding best practices
The View - Lotusscript coding best practicesBill Buchan
 
Introduction to Aspect Oriented Programming (DDD South West 4.0)
Introduction to Aspect Oriented Programming (DDD South West 4.0)Introduction to Aspect Oriented Programming (DDD South West 4.0)
Introduction to Aspect Oriented Programming (DDD South West 4.0)Yan Cui
 
Clean Code Part III - Craftsmanship at SoCal Code Camp
Clean Code Part III - Craftsmanship at SoCal Code CampClean Code Part III - Craftsmanship at SoCal Code Camp
Clean Code Part III - Craftsmanship at SoCal Code CampTheo Jungeblut
 
Using Automated Code Reviews to Achieve Continuous Quality (ASQF Agile Night ...
Using Automated Code Reviews to Achieve Continuous Quality (ASQF Agile Night ...Using Automated Code Reviews to Achieve Continuous Quality (ASQF Agile Night ...
Using Automated Code Reviews to Achieve Continuous Quality (ASQF Agile Night ...Peter Kofler
 

Similar a How aspects clean your code (20)

Solve cross cutting concerns with aspect oriented programming (aop)
Solve cross cutting concerns with aspect oriented programming (aop)Solve cross cutting concerns with aspect oriented programming (aop)
Solve cross cutting concerns with aspect oriented programming (aop)
 
How to define an api
How to define an apiHow to define an api
How to define an api
 
2R-3KS03-OOP_UNIT-I (Part-A)_2023-24.pptx
2R-3KS03-OOP_UNIT-I (Part-A)_2023-24.pptx2R-3KS03-OOP_UNIT-I (Part-A)_2023-24.pptx
2R-3KS03-OOP_UNIT-I (Part-A)_2023-24.pptx
 
Linters for frontend code review
Linters for frontend code reviewLinters for frontend code review
Linters for frontend code review
 
Quick Intro to Clean Coding
Quick Intro to Clean CodingQuick Intro to Clean Coding
Quick Intro to Clean Coding
 
Aspect Oriented Programming
Aspect Oriented ProgrammingAspect Oriented Programming
Aspect Oriented Programming
 
The Past, Present, and Future of OpenACC
The Past, Present, and Future of OpenACCThe Past, Present, and Future of OpenACC
The Past, Present, and Future of OpenACC
 
Be armed to the teeth to maintain a high quality iOS code
Be armed to the teeth to maintain a high quality iOS codeBe armed to the teeth to maintain a high quality iOS code
Be armed to the teeth to maintain a high quality iOS code
 
How to Embed Codeless Test Automation Into DevOps
How to Embed Codeless Test Automation Into DevOpsHow to Embed Codeless Test Automation Into DevOps
How to Embed Codeless Test Automation Into DevOps
 
Unit 1 introduction to c++.pptx
Unit 1 introduction to c++.pptxUnit 1 introduction to c++.pptx
Unit 1 introduction to c++.pptx
 
DYNAMIC SLICING OF ASPECT-ORIENTED PROGRAMS
DYNAMIC SLICING OF ASPECT-ORIENTED PROGRAMSDYNAMIC SLICING OF ASPECT-ORIENTED PROGRAMS
DYNAMIC SLICING OF ASPECT-ORIENTED PROGRAMS
 
DYNAMIC SLICING OF ASPECT-ORIENTED PROGRAMS
DYNAMIC SLICING OF ASPECT-ORIENTED PROGRAMSDYNAMIC SLICING OF ASPECT-ORIENTED PROGRAMS
DYNAMIC SLICING OF ASPECT-ORIENTED PROGRAMS
 
Pointcut Rejuvenation: Recovering Pointcut Expressions in Evolving Aspect-Ori...
Pointcut Rejuvenation: Recovering Pointcut Expressions in Evolving Aspect-Ori...Pointcut Rejuvenation: Recovering Pointcut Expressions in Evolving Aspect-Ori...
Pointcut Rejuvenation: Recovering Pointcut Expressions in Evolving Aspect-Ori...
 
Dealing With Legacy: The Real-World Experience
Dealing With Legacy: The Real-World ExperienceDealing With Legacy: The Real-World Experience
Dealing With Legacy: The Real-World Experience
 
Software Defect Prevention via Continuous Inspection
Software Defect Prevention via Continuous InspectionSoftware Defect Prevention via Continuous Inspection
Software Defect Prevention via Continuous Inspection
 
Developer Job in Practice
Developer Job in PracticeDeveloper Job in Practice
Developer Job in Practice
 
The View - Lotusscript coding best practices
The View - Lotusscript coding best practicesThe View - Lotusscript coding best practices
The View - Lotusscript coding best practices
 
Introduction to Aspect Oriented Programming (DDD South West 4.0)
Introduction to Aspect Oriented Programming (DDD South West 4.0)Introduction to Aspect Oriented Programming (DDD South West 4.0)
Introduction to Aspect Oriented Programming (DDD South West 4.0)
 
Clean Code Part III - Craftsmanship at SoCal Code Camp
Clean Code Part III - Craftsmanship at SoCal Code CampClean Code Part III - Craftsmanship at SoCal Code Camp
Clean Code Part III - Craftsmanship at SoCal Code Camp
 
Using Automated Code Reviews to Achieve Continuous Quality (ASQF Agile Night ...
Using Automated Code Reviews to Achieve Continuous Quality (ASQF Agile Night ...Using Automated Code Reviews to Achieve Continuous Quality (ASQF Agile Night ...
Using Automated Code Reviews to Achieve Continuous Quality (ASQF Agile Night ...
 

Más de Barbara Fusinska

Hassle free, scalable, machine learning learning with Kubeflow
Hassle free, scalable, machine learning learning with KubeflowHassle free, scalable, machine learning learning with Kubeflow
Hassle free, scalable, machine learning learning with KubeflowBarbara Fusinska
 
Deep learning with TensorFlow
Deep learning with TensorFlowDeep learning with TensorFlow
Deep learning with TensorFlowBarbara Fusinska
 
Clean, Learn and Visualise data with R
Clean, Learn and Visualise data with RClean, Learn and Visualise data with R
Clean, Learn and Visualise data with RBarbara Fusinska
 
Using Machine Learning and Chatbots to handle 1st line Technical Support
Using Machine Learning and Chatbots to handle 1st line Technical SupportUsing Machine Learning and Chatbots to handle 1st line Technical Support
Using Machine Learning and Chatbots to handle 1st line Technical SupportBarbara Fusinska
 
Machine Learning with Azure
Machine Learning with AzureMachine Learning with Azure
Machine Learning with AzureBarbara Fusinska
 
Networks are like onions: Practical Deep Learning with TensorFlow
Networks are like onions: Practical Deep Learning with TensorFlowNetworks are like onions: Practical Deep Learning with TensorFlow
Networks are like onions: Practical Deep Learning with TensorFlowBarbara Fusinska
 
Using Machine Learning and Chatbots to handle 1st line Technical Support
Using Machine Learning and Chatbots to handle 1st line Technical SupportUsing Machine Learning and Chatbots to handle 1st line Technical Support
Using Machine Learning and Chatbots to handle 1st line Technical SupportBarbara Fusinska
 
Deep Learning with Microsoft Cognitive Toolkit
Deep Learning with Microsoft Cognitive ToolkitDeep Learning with Microsoft Cognitive Toolkit
Deep Learning with Microsoft Cognitive ToolkitBarbara Fusinska
 
Clean, Learn and Visualise data with R
Clean, Learn and Visualise data with RClean, Learn and Visualise data with R
Clean, Learn and Visualise data with RBarbara Fusinska
 
Using Machine Learning and Chatbots to handle 1st line technical support
Using Machine Learning and Chatbots to handle 1st line technical supportUsing Machine Learning and Chatbots to handle 1st line technical support
Using Machine Learning and Chatbots to handle 1st line technical supportBarbara Fusinska
 
V like Velocity, Predicting in Real-Time with Azure ML
V like Velocity, Predicting in Real-Time with Azure MLV like Velocity, Predicting in Real-Time with Azure ML
V like Velocity, Predicting in Real-Time with Azure MLBarbara Fusinska
 
A picture speaks a thousand words - Data Visualisation with R
A picture speaks a thousand words - Data Visualisation with RA picture speaks a thousand words - Data Visualisation with R
A picture speaks a thousand words - Data Visualisation with RBarbara Fusinska
 
Analysing GitHub commits with R
Analysing GitHub commits with RAnalysing GitHub commits with R
Analysing GitHub commits with RBarbara Fusinska
 
Analysing GitHub commits with R
Analysing GitHub commits with RAnalysing GitHub commits with R
Analysing GitHub commits with RBarbara Fusinska
 
Breaking the eggshell: From .NET to Node.js
Breaking the eggshell: From .NET to Node.jsBreaking the eggshell: From .NET to Node.js
Breaking the eggshell: From .NET to Node.jsBarbara Fusinska
 
Analysing GitHub commits with R
Analysing GitHub commits with RAnalysing GitHub commits with R
Analysing GitHub commits with RBarbara Fusinska
 
Analysing GitHub commits with R
Analysing GitHub commits with RAnalysing GitHub commits with R
Analysing GitHub commits with RBarbara Fusinska
 

Más de Barbara Fusinska (20)

Hassle free, scalable, machine learning learning with Kubeflow
Hassle free, scalable, machine learning learning with KubeflowHassle free, scalable, machine learning learning with Kubeflow
Hassle free, scalable, machine learning learning with Kubeflow
 
Machine Learning with R
Machine Learning with RMachine Learning with R
Machine Learning with R
 
Deep learning with TensorFlow
Deep learning with TensorFlowDeep learning with TensorFlow
Deep learning with TensorFlow
 
Clean, Learn and Visualise data with R
Clean, Learn and Visualise data with RClean, Learn and Visualise data with R
Clean, Learn and Visualise data with R
 
TensorFlow in 3 sentences
TensorFlow in 3 sentencesTensorFlow in 3 sentences
TensorFlow in 3 sentences
 
Using Machine Learning and Chatbots to handle 1st line Technical Support
Using Machine Learning and Chatbots to handle 1st line Technical SupportUsing Machine Learning and Chatbots to handle 1st line Technical Support
Using Machine Learning and Chatbots to handle 1st line Technical Support
 
Machine Learning with Azure
Machine Learning with AzureMachine Learning with Azure
Machine Learning with Azure
 
Networks are like onions: Practical Deep Learning with TensorFlow
Networks are like onions: Practical Deep Learning with TensorFlowNetworks are like onions: Practical Deep Learning with TensorFlow
Networks are like onions: Practical Deep Learning with TensorFlow
 
Using Machine Learning and Chatbots to handle 1st line Technical Support
Using Machine Learning and Chatbots to handle 1st line Technical SupportUsing Machine Learning and Chatbots to handle 1st line Technical Support
Using Machine Learning and Chatbots to handle 1st line Technical Support
 
Deep Learning with Microsoft Cognitive Toolkit
Deep Learning with Microsoft Cognitive ToolkitDeep Learning with Microsoft Cognitive Toolkit
Deep Learning with Microsoft Cognitive Toolkit
 
Machine Learning with R
Machine Learning with RMachine Learning with R
Machine Learning with R
 
Clean, Learn and Visualise data with R
Clean, Learn and Visualise data with RClean, Learn and Visualise data with R
Clean, Learn and Visualise data with R
 
Using Machine Learning and Chatbots to handle 1st line technical support
Using Machine Learning and Chatbots to handle 1st line technical supportUsing Machine Learning and Chatbots to handle 1st line technical support
Using Machine Learning and Chatbots to handle 1st line technical support
 
V like Velocity, Predicting in Real-Time with Azure ML
V like Velocity, Predicting in Real-Time with Azure MLV like Velocity, Predicting in Real-Time with Azure ML
V like Velocity, Predicting in Real-Time with Azure ML
 
A picture speaks a thousand words - Data Visualisation with R
A picture speaks a thousand words - Data Visualisation with RA picture speaks a thousand words - Data Visualisation with R
A picture speaks a thousand words - Data Visualisation with R
 
Analysing GitHub commits with R
Analysing GitHub commits with RAnalysing GitHub commits with R
Analysing GitHub commits with R
 
Analysing GitHub commits with R
Analysing GitHub commits with RAnalysing GitHub commits with R
Analysing GitHub commits with R
 
Breaking the eggshell: From .NET to Node.js
Breaking the eggshell: From .NET to Node.jsBreaking the eggshell: From .NET to Node.js
Breaking the eggshell: From .NET to Node.js
 
Analysing GitHub commits with R
Analysing GitHub commits with RAnalysing GitHub commits with R
Analysing GitHub commits with R
 
Analysing GitHub commits with R
Analysing GitHub commits with RAnalysing GitHub commits with R
Analysing GitHub commits with R
 

Último

Cyber security and its impact on E commerce
Cyber security and its impact on E commerceCyber security and its impact on E commerce
Cyber security and its impact on E commercemanigoyal112
 
Ahmed Motair CV April 2024 (Senior SW Developer)
Ahmed Motair CV April 2024 (Senior SW Developer)Ahmed Motair CV April 2024 (Senior SW Developer)
Ahmed Motair CV April 2024 (Senior SW Developer)Ahmed Mater
 
Intelligent Home Wi-Fi Solutions | ThinkPalm
Intelligent Home Wi-Fi Solutions | ThinkPalmIntelligent Home Wi-Fi Solutions | ThinkPalm
Intelligent Home Wi-Fi Solutions | ThinkPalmSujith Sukumaran
 
cpct NetworkING BASICS AND NETWORK TOOL.ppt
cpct NetworkING BASICS AND NETWORK TOOL.pptcpct NetworkING BASICS AND NETWORK TOOL.ppt
cpct NetworkING BASICS AND NETWORK TOOL.pptrcbcrtm
 
How to submit a standout Adobe Champion Application
How to submit a standout Adobe Champion ApplicationHow to submit a standout Adobe Champion Application
How to submit a standout Adobe Champion ApplicationBradBedford3
 
VK Business Profile - provides IT solutions and Web Development
VK Business Profile - provides IT solutions and Web DevelopmentVK Business Profile - provides IT solutions and Web Development
VK Business Profile - provides IT solutions and Web Developmentvyaparkranti
 
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...Natan Silnitsky
 
Recruitment Management Software Benefits (Infographic)
Recruitment Management Software Benefits (Infographic)Recruitment Management Software Benefits (Infographic)
Recruitment Management Software Benefits (Infographic)Hr365.us smith
 
Precise and Complete Requirements? An Elusive Goal
Precise and Complete Requirements? An Elusive GoalPrecise and Complete Requirements? An Elusive Goal
Precise and Complete Requirements? An Elusive GoalLionel Briand
 
MYjobs Presentation Django-based project
MYjobs Presentation Django-based projectMYjobs Presentation Django-based project
MYjobs Presentation Django-based projectAnoyGreter
 
Cloud Data Center Network Construction - IEEE
Cloud Data Center Network Construction - IEEECloud Data Center Network Construction - IEEE
Cloud Data Center Network Construction - IEEEVICTOR MAESTRE RAMIREZ
 
Unveiling the Future: Sylius 2.0 New Features
Unveiling the Future: Sylius 2.0 New FeaturesUnveiling the Future: Sylius 2.0 New Features
Unveiling the Future: Sylius 2.0 New FeaturesŁukasz Chruściel
 
办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样
办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样
办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样umasea
 
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte Germany
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte GermanySuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte Germany
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte GermanyChristoph Pohl
 
Comparing Linux OS Image Update Models - EOSS 2024.pdf
Comparing Linux OS Image Update Models - EOSS 2024.pdfComparing Linux OS Image Update Models - EOSS 2024.pdf
Comparing Linux OS Image Update Models - EOSS 2024.pdfDrew Moseley
 
Unveiling Design Patterns: A Visual Guide with UML Diagrams
Unveiling Design Patterns: A Visual Guide with UML DiagramsUnveiling Design Patterns: A Visual Guide with UML Diagrams
Unveiling Design Patterns: A Visual Guide with UML DiagramsAhmed Mohamed
 
Folding Cheat Sheet #4 - fourth in a series
Folding Cheat Sheet #4 - fourth in a seriesFolding Cheat Sheet #4 - fourth in a series
Folding Cheat Sheet #4 - fourth in a seriesPhilip Schwarz
 
Tech Tuesday - Mastering Time Management Unlock the Power of OnePlan's Timesh...
Tech Tuesday - Mastering Time Management Unlock the Power of OnePlan's Timesh...Tech Tuesday - Mastering Time Management Unlock the Power of OnePlan's Timesh...
Tech Tuesday - Mastering Time Management Unlock the Power of OnePlan's Timesh...OnePlan Solutions
 

Último (20)

Advantages of Odoo ERP 17 for Your Business
Advantages of Odoo ERP 17 for Your BusinessAdvantages of Odoo ERP 17 for Your Business
Advantages of Odoo ERP 17 for Your Business
 
Cyber security and its impact on E commerce
Cyber security and its impact on E commerceCyber security and its impact on E commerce
Cyber security and its impact on E commerce
 
Ahmed Motair CV April 2024 (Senior SW Developer)
Ahmed Motair CV April 2024 (Senior SW Developer)Ahmed Motair CV April 2024 (Senior SW Developer)
Ahmed Motair CV April 2024 (Senior SW Developer)
 
Intelligent Home Wi-Fi Solutions | ThinkPalm
Intelligent Home Wi-Fi Solutions | ThinkPalmIntelligent Home Wi-Fi Solutions | ThinkPalm
Intelligent Home Wi-Fi Solutions | ThinkPalm
 
cpct NetworkING BASICS AND NETWORK TOOL.ppt
cpct NetworkING BASICS AND NETWORK TOOL.pptcpct NetworkING BASICS AND NETWORK TOOL.ppt
cpct NetworkING BASICS AND NETWORK TOOL.ppt
 
How to submit a standout Adobe Champion Application
How to submit a standout Adobe Champion ApplicationHow to submit a standout Adobe Champion Application
How to submit a standout Adobe Champion Application
 
VK Business Profile - provides IT solutions and Web Development
VK Business Profile - provides IT solutions and Web DevelopmentVK Business Profile - provides IT solutions and Web Development
VK Business Profile - provides IT solutions and Web Development
 
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...
Taming Distributed Systems: Key Insights from Wix's Large-Scale Experience - ...
 
Recruitment Management Software Benefits (Infographic)
Recruitment Management Software Benefits (Infographic)Recruitment Management Software Benefits (Infographic)
Recruitment Management Software Benefits (Infographic)
 
Precise and Complete Requirements? An Elusive Goal
Precise and Complete Requirements? An Elusive GoalPrecise and Complete Requirements? An Elusive Goal
Precise and Complete Requirements? An Elusive Goal
 
MYjobs Presentation Django-based project
MYjobs Presentation Django-based projectMYjobs Presentation Django-based project
MYjobs Presentation Django-based project
 
Cloud Data Center Network Construction - IEEE
Cloud Data Center Network Construction - IEEECloud Data Center Network Construction - IEEE
Cloud Data Center Network Construction - IEEE
 
Unveiling the Future: Sylius 2.0 New Features
Unveiling the Future: Sylius 2.0 New FeaturesUnveiling the Future: Sylius 2.0 New Features
Unveiling the Future: Sylius 2.0 New Features
 
办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样
办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样
办理学位证(UQ文凭证书)昆士兰大学毕业证成绩单原版一模一样
 
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte Germany
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte GermanySuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte Germany
SuccessFactors 1H 2024 Release - Sneak-Peek by Deloitte Germany
 
Comparing Linux OS Image Update Models - EOSS 2024.pdf
Comparing Linux OS Image Update Models - EOSS 2024.pdfComparing Linux OS Image Update Models - EOSS 2024.pdf
Comparing Linux OS Image Update Models - EOSS 2024.pdf
 
Hot Sexy call girls in Patel Nagar🔝 9953056974 🔝 escort Service
Hot Sexy call girls in Patel Nagar🔝 9953056974 🔝 escort ServiceHot Sexy call girls in Patel Nagar🔝 9953056974 🔝 escort Service
Hot Sexy call girls in Patel Nagar🔝 9953056974 🔝 escort Service
 
Unveiling Design Patterns: A Visual Guide with UML Diagrams
Unveiling Design Patterns: A Visual Guide with UML DiagramsUnveiling Design Patterns: A Visual Guide with UML Diagrams
Unveiling Design Patterns: A Visual Guide with UML Diagrams
 
Folding Cheat Sheet #4 - fourth in a series
Folding Cheat Sheet #4 - fourth in a seriesFolding Cheat Sheet #4 - fourth in a series
Folding Cheat Sheet #4 - fourth in a series
 
Tech Tuesday - Mastering Time Management Unlock the Power of OnePlan's Timesh...
Tech Tuesday - Mastering Time Management Unlock the Power of OnePlan's Timesh...Tech Tuesday - Mastering Time Management Unlock the Power of OnePlan's Timesh...
Tech Tuesday - Mastering Time Management Unlock the Power of OnePlan's Timesh...
 

How aspects clean your code

  • 1. Aspect-Oriented Programming How can aspects clean your code? @BasiaFusinska
  • 2. Aspect-Oriented Programming How can aspects clean your code? 2 About me Programmer @basiafusinska Architect Coach Manager Teacher Trainer
  • 3. Aspect-Oriented Programming How can aspects clean your code? Agenda 3 ❖ What the hell...are aspects? ❖ Some examples of AOP ❖ Demo 1: refactor your way to aspects ❖ Every-day aspects ❖ Demo 2: some not-so-obvious aspects ❖ How to test aspects ❖ Demo 3: testing in practice ❖ Q & A
  • 4. Aspect-Oriented Programming How can aspects clean your code? Some history 4 ❖ Gregor Kiczales (1997), Xerox PARC ❖ OOP is unable to solve some common problems ❖ Aspects encapsulate cross-cutting concerns and make them easier to reuse
  • 5. Aspect-Oriented Programming How can aspects clean your code? Cross cutting concerns 5 ❖ Cross-cutting concerns are scattered throughout the code ❖ Code becomes difficult to develop and modify ❖ Code breaks the Single Responsibility Principle
  • 6. Aspect-Oriented Programming How can aspects clean your code? Cross-cutting concerns are everywhere! 7 ❖ Logging ❖ Validation ❖ Persistence ❖ Caching ❖ Synchronization ❖ Transactions ❖ Exception handling ❖ Authentication ❖ Authorization ❖ ...
  • 7. Aspect-Oriented Programming How can aspects clean your code? What the heck are aspects? 6 ❖ Purpose: cross-cutting concerns – pieces of functionality used across multiple parts of a system ❖ Job: the advice – code that performs cross-cutting concern ❖ Map: pointcut – set of joinpoints ❖ How: weaving
  • 8. Aspect-Oriented Programming How can aspects clean your code? 6 How it works?
  • 9. Aspect-Oriented Programming How can aspects clean your code? Types of advices? 6 ❖ Entry ❖ Exit ❖ Exception ❖ Success ❖ Around ❖ Method boundaries vs method interceptions
  • 10. Aspect-Oriented Programming How can aspects clean your code? Some benefits of AOP 8 ❖ Code is cleaner ❖ DRY (Don’t Repeat Yourself): promotes code reuse ❖ Better encapsulation
  • 11. 9 Aspect-Oriented Programming How can aspects clean your code? Demonstration #1 Refactor your way to aspects
  • 12. Aspect-Oriented Programming How can aspects clean your code? You’ve been using AOP without knowing it 10 ❖ IHttpModule - requests boundary aspects ❖ IActionFilter - code run before and after the action execution ❖ ASP.Net MVC Authentication - AuthorizeAttribute ❖ Actions per request (Session Open/Close, ORM changes saving)
  • 13. 11 Aspect-Oriented Programming How can aspects clean your code? Demonstration #2 Some not-so-obvious aspects
  • 14. Aspect-Oriented Programming How can aspects clean your code? Testing aspects 12 ❖ Testing the pointcut – testing if aspects were used in correct places ❖ Testing the advice – testing if the aspects are doing what they are supposed to do
  • 15. 13 Aspect-Oriented Programming How can aspects clean your code? Demonstration #3 Testing aspects
  • 16. Thank you :) Any questions? @basiafusinska barbarafusinska.co m