An aspect is a module implemented in an Aspect-Oriented Programming language that contains code for a cross-cutting concern, like logging or security. For questions about the aspect ratio of images, use the aspect-ratio tag.
This tag is for Aspect-Oriented Programming. For questions and answers about the aspect ratio of images, please use the aspect-ratio tag.
A feature of a program, like logging, is usually spread throughout a program and is not related to that program's main function. Such a feature is called a cross-cutting concern. The aim of aspect-oriented software development (AOSD) (also called aspect-oriented programming or AOP) is to move a cross-cutting concerns into an aspect. This is called refactoring the code.
In AOSD, aspects are written separately from the main application, which can be written in any standard OOP language. An AOP compiler, like AspectJ, compiles the AOP code and object-oriented programming (OOP) code together in a process called weaving.
AOP is often used to enhance legacy applications or 3rd party libraries when the original source code is not available. It is also used to overcome the main weakness of OOP by collecting the cross-cutting concerns into aspects.
Wikis:
See also: