开发者

Learning AspectJ

I have read the documents in the following locations. Maybe I'm too dumb but I can't see too many useful examples that I can visualize and no much stay in my mind.

http://eclipse.org/aspectj

http://www.ibm.com/developerworks/java/library/j-aopwork8/index.html

Does anyone have any good and simple AspectJ getting start doc online? An eclipse project sampl开发者_高级运维e that I can run and play around with would be super!


I have written an example that shows you how AspectJ can work with annotations like @javax.inject.Inject here

I have also tried to simplify AspectJ with a cheat sheet here.

If you need to understand the theory, the AspectJ in Action is very good. For online resources, the Spring framework has a good reference document you can read here.

I hope it helps!


AspectJ In Action might help. It's got some unusual use cases that will help to get you beyond the logging "hello world" stage.

You can also get your feet wet with real usage by starting with Spring.


This is a link to an implementation of the GoF design patterns in AspectJ (they have not been updated for AspectJ 5, but they are still very relevant). They provide some great examples of patterns to use when implementing aspects:

http://hannemann.pbworks.com/Design+Patterns


Spring Roo is an excellent way to learn AspectJ since it sets everything up project wise. It also generates AspectJ ITDs that I found very helpful to learn from.

The AspectJ in Action book is excellent.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜