I have a method that takes a String as an input, and I’d like to have an aspect intercept the method execution and, upon some certain condition, modify the String and have the join point receive the new input, so it has no idea that it’s been transformed.
Is this possible, or can it not be done due to security concerns?
Using AspectJ you can declare an around advice like this:
The your code has to be intrumented either at compile time or at the run time using AspectJ Java agent.