|
This sounds like a classic circular-dependency problem. How about the
following solution, based on the Dependency Inversion Principle
(http://www.objectmentor.com/publications/dip.pdf)? 1) Extract the aspect into a separate"component" with its own build step. 2) Define an interface for the services provided by the rest of your code base that your aspect needs. The interface is part of the aspect's component. The aspect needs a "setter" to associate to it an object that implements the interface. 3) Determine where in your code base (main()?) to invoke the "setter" to associate an implementing object with the aspect. (You could use dependency injection with Spring, for example.) 4) Build the aspect and weave the 3rd-party jar. 5) Build your code base. 6) At runtime, associate the implementing object with the aspect... 7) Rinse and repeat ;) HTH, dean [EMAIL PROTECTED] wrote: Hello, I am trying to weave into a third party jar an aspect that depends on my local codebase, but I want to defer the compilation of my local codebase until a later time and simply reference the previously woven jar file. However, I am getting a compile error with that approach. The following ant target works fine, but weaves into the third party jar and compiles my local codebase at the same time: -- Dean Wampler, Ph.D. [EMAIL PROTECTED] http://www.aspectassoc.com http://www.aspectprogramming.com http://www.contract4j.org I want my tombstone to say: Unknown Application Error in Dean Wampler.exe. Application Terminated. [Okay] [Cancel] |
_______________________________________________ aspectj-users mailing list [email protected] https://dev.eclipse.org/mailman/listinfo/aspectj-users
