|
|
Aspect Oriented Programming in Java
Object oriented programming has become mainstream over the last years,
having almost completely replaced the procedural approach. One of the biggest
advantages of object orientation is that a software system can be seen as
being built of a collection of discrete classes. Each of these classes has a
well defined task, its responsibilities are clearly defined. In an OO
application, those classes collaborate to achieve the application's
overall goal. However, there are parts of a system that cannot be viewed as
being the responsibility of only one class, they cross-cut the complete system
and affect parts of many classes. Examples might be locking in a distributed
application, exception handling, or logging method calls. Of course, the code
that handles these parts can be added to each class separately, but that would
violate the principle that each class has well-defined responsibilities. This
is where AOP comes into play: AOP defines a new program construct, called an
aspect, which is used to capture cross-cutting aspects of a software system in
separate program entities. The application classes keep their
well-defined resonsibilities. Additionally, each aspect captures cross-cutting
behaviour.
[Artikel]
01.12.1999
Download...
Abstract...
|
Aspect Oriented Programming in Java
|
|
Published in: JavaReport, 1999-12
|
|