java - AspectJ Decompilation -


i have following class: package ajia.messaging;

public class messagecommunicator {     public void deliver(string message) {         system.out.println(message);     }      public void deliver(string person, string message) {         system.out.println(person + ", " + message);     } } 

and following advice:

package ajia.security; import ajia.messaging.messagecommunicator;  public aspect securityaspect {     private authenticator authenticator = new authenticator();      pointcut secureaccess()         : execution(* messagecommunicator.deliver(..));      before() : secureaccess() {         system.out.println("checking , authenticating user");         authenticator.authenticate();     } } 

i compile - ajc -source 5 ajia\messaging\messagecommunicator.java ajia\security\securityaspect.aj

as understand resulting messagecommunicator.class have aspect code included. wandering if standard java decompilers decompile class correctly?

decompilers work recognizing patterns produced compilers. aspectj tries produce code follows same kinds of pattern (the structure of byte code catch blocks, kind of thing). code decompile ok unless crazy weaving has gone on. aspectj project accept bug reports on code isn't cleanly decompilable , attempt address it.


Comments

Popular posts from this blog

Python Kivy ListView: How to delete selected ListItemButton? -

asp.net mvc 4 - A specified Include path is not valid. The EntityType '' does not declare a navigation property with the name '' -