• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

AspectJ

 
Ranch Hand
Posts: 8945
Firefox Browser Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
What is AspectJ?
 
Pradeep bhatt
Ranch Hand
Posts: 8945
Firefox Browser Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Who owns the AspectJ? Is it a open standard ? Is it a implementation or some sort of spec?
 
Author
Posts: 62
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Pradeep,
AspectJ is an aspect-oriented programming language (that uses Java as the base language), much like Java is an object-oriented programming language.
From language point-of-view, AspectJ is an extension of Java that allows you to modularize crosscutting concerns -- requirement, design, or implementation that spread over multiple modules. AspectJ introduces a few new language constructs such as pointcut, advice, aspect, and introduction. Using these constructs, AspectJ allows you to implement crosscutting concerns into separate modules instead of fusing them with the core logic.
For more information on AspectJ language syntax, please refer to sample chapter (chapter 3) available at:
http://www.manning.com/laddad
AspectJ started at Xerox PARC and currently is an open source project at eclipse.org.
-Ramnivas
 
Ranch Hand
Posts: 3404
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Ramnivas and welcome.

AspectJ is an extension of Java that allows you to modularize crosscutting concerns -- requirement, design, or implementation that spread over multiple modules.


By this do you mean it's an API or framework as JUnit, Struts ?
regards
 
Pradeep bhatt
Ranch Hand
Posts: 8945
Firefox Browser Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Is there is any plan to apply for r Sun Microsystems JSR?
 
author
Posts: 11962
5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Pradeep Bhat:
Is there is any plan to apply for r Sun Microsystems JSR?


My guess is that this kind of rather big change regarding the language will take plenty of time before it becomes part of Java. However, there is JSR 175 for Java metadata, which could be called a step towards AOP.

Originally posted by HS Thomas:
By this do you mean it's an API or framework as JUnit, Struts ?


AspectJ specifies a language syntax which is basically Java plus some new keywords and notations. This non-Java code is translated into pure Java code during the build process.
 
Ramnivas Laddad
Author
Posts: 62
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thomas,
AspectJ is an extension of the Java language that adds a few new constructs. To compile programs written in AspectJ, you need to use the AspectJ compiler (ajc) (which, not surprisingly, is an extension of a Java compiler).
Pradeep,
There isn�t any current initiative to take AspectJ through JCP.
-Ramnivas
 
Ranch Hand
Posts: 252
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Pradeep,
You can find more info. about AspectJ here which is a series of articles written by Mr. Laddad
Thanks,
Bhushan
 
Pradeep bhatt
Ranch Hand
Posts: 8945
Firefox Browser Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Bhushan Jawle:
Pradeep,
You can find more info. about AspectJ here which is a series of articles written by Mr. Laddad
Thanks,
Bhushan


It would be better if I get Mr. Laddad book though.
 
Pradeep bhatt
Ranch Hand
Posts: 8945
Firefox Browser Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

AspectJ specifies a language syntax which is basically Java plus some new keywords and notations. This non-Java code is translated into pure Java code during the build process.


Is there any complier involved in the build process?
 
Lasse Koskela
author
Posts: 11962
5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Is there any complier involved in the build process?

Yes, the AspectJ compiler.
 
Pradeep bhatt
Ranch Hand
Posts: 8945
Firefox Browser Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Is AspectJ technology of the future?
 
Lasse Koskela
author
Posts: 11962
5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Is AspectJ technology of the future?


Depends on what you mean by "technology of the future." AspectJ is here now but it's not in wide-spread use yet (nor is any other full-blown AOP implementation).
 
Author & Gold Digger
Posts: 7617
6
IntelliJ IDE Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Pradeep Bhat:
Is AspectJ technology of the future?


In 2001, MIT released its annual "10 Emerging Technologies That Will Change the World". Among them, aspects were cited as a good support for untangling code in complex software systems: http://www.globalfuture.com/mit-trends2001.htm. This just means aspects will help developer create better software in the future. However, AspectJ is one implementation of AOP. There are many others available out there. AspectJ is currently the most mature AOP implementation and also the one that has the greatest community support.
Also, AspectJ won the "Most Innovative Java Product or Technology" JavaWorld Editors' Choice Award!.
[ September 17, 2003: Message edited by: Valentin Crettaz ]
 
Pradeep bhatt
Ranch Hand
Posts: 8945
Firefox Browser Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Where can AspectJ be used? Does it have any limitations?
Valentin, have you found any gold?

Originally posted by Valentin Crettaz:

In 2001, MIT released its annual "10 Emerging Technologies That Will Change the World". Among them, aspects were cited as a good support for untangling code in complex software systems: http://www.globalfuture.com/mit-trends2001.htm. This just means aspects will help developer create better software in the future. However, AspectJ is one implementation of AOP. There are many others available out there. AspectJ is currently the most mature AOP implementation and also the one that has the greatest community support.
Also, AspectJ won the "Most Innovative Java Product or Technology" JavaWorld Editors' Choice Award!.
[ September 17, 2003: Message edited by: Valentin Crettaz ]

 
Pradeep bhatt
Ranch Hand
Posts: 8945
Firefox Browser Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

AspectJ specifies a language syntax which is basically Java plus some new keywords and notations.


So does it mean that the learning curve is small?
 
Lasse Koskela
author
Posts: 11962
5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

So does it mean that the learning curve is small?


I would say that it's easier to grasp a new "type" on top of classes and interfaces than it is to grasp the combination of Java code and yet another XML file.
Then again, I haven't even studied AspectJ enough to claim any significant degree of knowledge about it so what do I know...
 
Pradeep bhatt
Ranch Hand
Posts: 8945
Firefox Browser Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
From Chapter 2 of Ramnivas

Although the AspectJ syntax may feel somewhat complex in the beginning,
once you understand the basic form, it�s quite natural for a seasoned Java programmer:
An aspect looks like a class, a pointcut looks like a method declaration,
and an advice looks like a method implementation. Rest assured that the
AspectJ syntax is actually a lot easier than it appears.

 
Pradeep bhatt
Ranch Hand
Posts: 8945
Firefox Browser Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Depends on what you mean by "technology of the future


I meant .. it is something that will be widely used,just like Java is used today.
 
Ramnivas Laddad
Author
Posts: 62
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Valentin and Lasse already answered most of the questions.
I will chime in on a few points:
  • Yogi Berra once said: It's tough to make predictions, especially about the future. That said, AOP is definitely here to stay. Its final shape or form may be different that what we are seeing now, but the core concepts will remains the same. This is much like OOP, where the core concepts of encapsulation and polymorphism stayed the same.
  • The learning curve with AspectJ is pretty small. You should be able to write simple aspects in a day or less. To understand the full language, it does take a longer. I would say, try it. You will be pleasantly surprised.


  • -Ramnivas
     
    With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
    reply
      Bookmark Topic Watch Topic
    • New Topic