I found this topic: How to change the value of annotation at runtime using reflection?
And I'm trying to change the annotation of a method, but java.lang.reflect.Method does not contain any map field, for example, an "annotation" or a method like "getDeclaredAnnotationMap"
There is only private byte[] annotations, but what can I do with this byte array?
So how to change method annotation?
EDIT:
I created this: http://pastebin.com/T2rewcwU
But this only edits this instance of the method, if you uncomment 33 lines of code, then the value will be reset.
source
share