aspect oriented software development

13
Otavio Ferreira (@otaviofff) Technical Architect, Scrum Master Oct 2007

Upload: otavio-ferreira

Post on 06-May-2015

2.088 views

Category:

Technology


0 download

TRANSCRIPT

Page 1: Aspect Oriented Software Development

Otavio  Ferreira  (@otaviofff)  Technical  Architect,  Scrum  Master   Oct  2007  

Page 2: Aspect Oriented Software Development

•  AOSD  tag  cloud  

October  2007   MIH  SWAT  Team     2  

AOSD  concern  

aspect  dominant  

decomposi@on  

separa@on  of  concerns  

cross-­‐cuCng  concerns  

modularity   AOP  

point  cut  

join  point  

advice  

core  concern  

Page 3: Aspect Oriented Software Development

•  Concern  – An  area  of  interest  or  focus  in  a  system.  – The  primary  criteria  for  decomposing  SW  into  smaller,  more  manageable  and  comprehensible  parts.  

October  2007   MIH  SWAT  Team     3  

Text  Picture  Video  Quote  Link  Chat  

Caching  Logging  

Excep@on  Handling  Tumblelog  

Page 4: Aspect Oriented Software Development

•  Separa@on  of  concerns  – Based  on  the  Divide-­‐and-­‐Conquer  strategy.  – Focused  on  breaking  down    the  SW  into  dis@nct  parts    that  overlap  in  func@onality    as  liUle  as  possible.  

October  2007   MIH  SWAT  Team     4  

Page 5: Aspect Oriented Software Development

•  Core  concern  – Core  business  related  concern.  – Domain  specific  concern.  – Func@onal  requirement.  – Can  be  cleanly  encapsulated  in  a  generalized  procedure  (i.e.  object,  method,  procedure,  API).  

October  2007   MIH  SWAT  Team     5  

Page 6: Aspect Oriented Software Development

•  Cross-­‐cuCng  concern  – Common  func@onality  orthogonal  to  core  concern.  

– Non-­‐func@onal  requirement.  – Can  NOT  be  cleanly  encapsulated  in  a  generalized  procedure  (i.e.  object,  method,  procedure,  API).  

October  2007   MIH  SWAT  Team     6  

Page 7: Aspect Oriented Software Development

•  Dominant  decomposi@on  – The  SW  can  be  modularized  in  only  one  way  at  a  @me.  

– Concerns  that  do  not  align  with  that  modulariza@on  end  up  scaUered  across  many  modules  and  tangled  with  one  another.    

October  2007   MIH  SWAT  Team     7  

Page 8: Aspect Oriented Software Development

•  ScaUering  and  tangling  – Cross-­‐cuCng  concerns  o^en  cannot  be  cleanly  decomposed  from  the  rest  of  the  system  in  both  the  design  and  implementa@on.  

October  2007   MIH  SWAT  Team     8  

Logging  

Excep@on  Handling  

Page 9: Aspect Oriented Software Development

•  Aspect  (Finally!)  – A  part  of  a  program  that  cross-­‐cuts  its  core  concerns,  therefore  “viola@ng”  its  separa@on  of  concerns.  

 

October  2007   MIH  SWAT  Team     9  

Excep@on  Handling  

Logging  

Page 10: Aspect Oriented Software Development

•  Modularity  – AOP    is  an  advance  in  modulariza@on.  – Loosely  coupled  concerns  /  components.    

October  2007   MIH  SWAT  Team     10  

Page 11: Aspect Oriented Software Development

•  Aspect-­‐oriented  programming  – A  technique  used  to  support  the  programmer  in  cleanly  separa@ng  components  and  aspects  from  each  other.  

– Centers  its  aUen@on  on  the  code  modulariza@on,  providing  mechanisms  to  separate  cross-­‐cuCng  concerns  at  code  level.  

– Related  to  the  language.  

October  2007   MIH  SWAT  Team     11  

Page 12: Aspect Oriented Software Development

•  Aspect-­‐oriented  so^ware  development  –   A  combina@on  of  mechanisms  and  methodologies  that  facilitate  in  separa@ng  concerns  at  different  abstrac@on  levels.  

– Uses  a  combina@on  of  language,  environment,  and  method.  

October  2007   MIH  SWAT  Team     12  

Page 13: Aspect Oriented Software Development

•  Aspect-­‐oriented  applica@on  – Consists  of:  

•  Component  language  (C#,  Java,  etc.)  •  Aspect-­‐oriented  language  /  framework  •  Aspect  weaver  

October  2007   MIH  SWAT  Team     13