Aspect (computer programming): Difference between revisions

Content deleted Content added
m moved Aspect (computer science) to Aspect (computer programming): More accurate parenthetical disambiguation (discuss)
Readable description first ("cross-cuts" is not really very explanatory)
Line 1:
In [[computer science]], an '''aspect''' is a part of a program that cross-cuts its [[core concern]]s, therefore violating its [[separation of concerns]]. It is a feature linked to many other parts of athe program, but which is not necessarilyrelated to the program's primary function. ofAn aspect cross-cuts the program's [[core concern]]s, therefore violating its [[separation of concerns]]. For example, logging code can cross-cut many modules, yet the aspect of logging should be separate from the functional concerns of the module it cross-cuts. Isolating such aspects as [[Data logging|logging]] and [[persistence]] from [[business logic]] is the aim of [[aspect-oriented software development]] (AOSD), of which the [[aspect-oriented programming]] (AOP) [[programming paradigm|paradigm]] is the most widely employed.<ref>{{citebook|title=Aspect-Oriented Database Systems|author=Awais Rashid|year= 2004|publisher=Springer|isbn=3540009485}}</ref>
 
Aspect-orientation is not limited to programming since it is useful to identify, analyse, trace and modularise concerns (e.g., PREview) through requirements elicitation, specification and design. Aspects can be multi-dimensional by allowing both functional and non-functional behaviour to cross cut any other concerns, instead of just mapping non-functional concerns to functional requirements{{Citation needed|date=April 2010}}.
Line 6:
 
The prism analogy describes aspects with terms from the ___domain of light. Like splitting light into its many aspects (different colours) with a prism, you split a problem into its separate aspects. With another prism you can put the different colours back into a white ray of light, and by the process of weaving aspects you can put your solutions for the different aspects of a problem back into a solution for the whole problem.
 
== See also ==
[[AspectJ]]