[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Internal classes
On Sat, Mar 08, 2003 at 10:16:34AM -0000, Eric Bodden wrote:
> Hello!
>
> Also another question: Does anyone know if the bytecode contains some
> information which could tell someone for an internal class, in which
> actual class this internal class had been defined?
It probably is, but I don't know for sure. I'd look in the VM Spec.
> So I actually want to
> get the name of the declaring source file. And: If so, is SOOT capable
> of reading that out somehow?
Probably the easiest way is to look at the SourceFile attribute (I'm not
sure whether that's the exact name, but there is something like it). As
far as I know, Soot doesn't contain all the code to read it out, but it
may contain some. In any case, you'll have to code some of it yourself,
but it should be similar to the LineNumber attribute. Look in the VM
Spec and in the coffi package of Soot.
Ondrej
>
> Thanks,
> Eric
>
> ------------------------------------------------------------
> Eric Bodden
> CS-DIP full time student @ University of Kent at Canterbury
> UKC internal phone: 5095
> ICQ UIN: 12656220, secure mail on demand
> Website: http://www.bodden.de
>