Hi,

See the HelloWorldBuilder example, you'll have to use ClassGen and
MethodGen
to add new methods conveniently. The only difference is that you use
an existing class and modify and thus just pass it to the ClassGen
constructor.

Cheers
        Markus

> -----Ursprungliche Nachricht-----
> Von: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED]]
> Gesendet: Dienstag, 21. Mai 2002 06:58
> An: BCEL Users List
> Betreff: ConstantPool
> 
> 
> 
> I am trying to use JavaClass to see if a method exists.  I 
> want to create
> the method if it doesn't exist, but I don't understand how to add the
> method name to the ConstantPool.  Do I need to do an 
> arraycopy to make the
> ConstantPool bigger or are there extra slots to put new 
> constants.  If that
> is true, how do I tell where the next available slot is?  Do 
> I check for
> nulls?
> 
> What about the signature index?  What do I point to and how are the
> elements of the signature set up?
> 
> Thanks,
> -Phil
> 
> 
> --
> To unsubscribe, e-mail:   
> <mailto:[EMAIL PROTECTED]>
> For additional commands, e-mail: 
> <mailto:[EMAIL PROTECTED]>
> 

Reply via email to