Questions tagged [compile-time-weaving]

Compile time weaving is a technique which allows AOP aspects to be "woven in" at compile time mainly by modifying the compiled code (e.g. byte-code manipulation in Java).

89 questions
1
vote
2 answers

iajc weave particular aspects using aspect path

I have a library(say lib1) which comprises of a couple of aspect classes(say aspect1.java and aspect2.java). I want to weave only aspect1.java in my service code. Is this possible using ant iajc target in compile time weaving ? I know this is…
roger
  • 269
  • 1
  • 5
  • 20
1
vote
0 answers

Is compile time code generation possible for xproj projects?

In MSBuild based projects generating code seems easy enough as i have seen from PostSharp, Fody, and my own project. However i haven't really seen anything yet on how to do this in a xproj file, since i can't hook myself into the build chain through…
Dbl
  • 5,634
  • 3
  • 41
  • 66
1
vote
1 answer

Code weaving in XAML controls

I am developing user controls for winRT app. I want to avoid massive repetition of code and I am wondering if you know any solution for code weaving for properties and dependency property? I've tried Fody, but it doesn't work well with dependency…
1
vote
1 answer

Logging for domain objects using aspects (compile time weaving)

I want to keep logging code separate from my domain logic using aspects. But those aspects should do compile time weaving rather than making proxy objects. What all options are there apart from AspectJ?
Anmol Gupta
  • 2,797
  • 9
  • 27
  • 43
1
vote
0 answers

Spring AOP - pointcut for loggers. @Before not triggering for logger

I'm newbie to Spring AOP. I've written aspect advice for all methods in my application while it throws exception.(I've tried it with grails.) ExceptionService.groovy @Aspect public class ExceptionService { def logMessage(def message){ def…
Jacks
  • 11
  • 1
  • 3
1
vote
0 answers

Wrong context used to inject dependency in environment with servlet- and portlet-context

I am currently working on an application, that is accessed as both a portlet and a servlet (at least some parts are). I am also using compile-time-weaving to inject dependencies into beans in the prototype scope, so for example beans that are…
1
vote
1 answer

AspectJ compile-time weaving - getting output source code?

Is there a way to get source files as a result of AspectJ compilation? So instead of getting bytecode, ajc works as a preprocessor that generates Java sources that can be compiled with javac?
TFuto
  • 1,361
  • 15
  • 33
1
vote
1 answer

Excluding certain packages from Maven aspectj weavedependencies

Is it possible to make an exception (i.e. something to be excluded ) from AspectJ weaveDependencies? Something like the line with capital letters below? org.codehaus.mojo
Sanyifejű
  • 2,610
  • 10
  • 46
  • 73
1
vote
0 answers

Equinox Weaving doesn't work in Virgo tomcat

I'm using equinox weaving to do aspect across bundles in Virgo tomcat, I followed the weaving sample. It worked fine in eclipse target platform. But when I deployed into virgo, it didn't work. I modified config.ini like…
1
vote
0 answers

Error message: Can't ask to parameterize a member of non-generic type

My setup is vaadin, mybatis and spring. Now i integrated spring with vaadin with the vaadin tutorial everything works perfect. But when i'm using @Configurable(preConstruction = true) on a custom component with a Property.ValueChangeEvent method i…
1
vote
1 answer

PropertyChanged.Fody migrating notifypropertychanged

I have been using NotifyProperyWeaver and noticed it is deprecated in the latest build to Fody using PropertyChanged.Fody. I had NotifyProperyWeaver to only weave the properties i had attributes on and all other notifying was disabled. Is there a…
1
vote
1 answer

Partial compile time weaving third party jar with maven

I've configured weaving third party jar with maven plugin aspectj-maven-plugin. org.codehaus.mojo aspectj-maven-plugin
Daniil Iaitskov
  • 5,525
  • 8
  • 39
  • 49
1
vote
1 answer

How to distinguish generated methods (AspectJ)

I am currently using aspectJ @Around in order to inspect my code. I am using aspectJ compiler in order to weave the aspects. BUT, in runtime, I am analyzing also the structure of classes using reflection type.getDeclaredMethods(). BUt i need to…
malejpavouk
  • 4,297
  • 6
  • 41
  • 67
1
vote
2 answers

Problems changing from Load Time Weaver to Compile Time Weaver in Spring

I'm trying to change from load-time-weaving to compile-time-weaving with my Spring 2.5 app. To do this, I did the following: In my ant build file, I added
1
vote
1 answer

Why can't eclipse enable JDT Weaving?

I have created a simple Spring Roo Project in Eclipse Indigo, where the jpa entities where generated using the dbre command. When I want to add methods to some class, I'm not able to use the methods the are woven into the entities via the Spring Roo…
SpaceTrucker
  • 13,377
  • 6
  • 60
  • 99