method signature to parameter type signature

Ping Mao <[email protected]>
Newsgroups gmane.comp.java.objectweb.asm
Message-ID <[email protected]>
Hi there,

I am doing the method replacing as the example(MethodReplacer) in
http://asm.ow2.org/current/asm-transformations.pdf. The challenge is that the
original methods contain parameter(s) which might be generic types.  When visit
the method, the method signature is available, but I don't know if there is any
utility in ASM available to retrieve the parameter type's signature from the
method signature, like the functionality of 
Type[] Type.getArgumentTypes(final String methodDescriptor) which returns an
array of each argument type.

For example, for method:
public int getParameter(String first, List<ArrayList> second) {
    return 1;
}
the method signature is "(ILjava/util/List<Ljava/util/ArrayList;>;)I", it would
be helpful to get an array of parameter signature as {"I",
"Ljava/util/List<Ljava/util/ArrayList;>;"} to be needed in the local variables
section of the method body. Do I need to parse the method signature myself or
there is utility available?

Thanks a lot,
Ping
message-footer.txt (text/plain, 238 B)
-- 
You receive this message as a subscriber of the [email protected] mailing list.
To unsubscribe: mailto:[email protected]
For general help: mailto:[email protected]?subject=help
OW2 mailing lists service home page: http://www.ow2.org/wws
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.