V
vinayakumar
Hi
I have following requirement.
Write information of metods in some class in xml format. The methods
will have some thing called atachement.
for eg:
public void mymethd(){}
public static final string atch$mymethd$description="Metod
description".
My xml will look like
<name ="mymethod" descriptin ="method description"/>
I am dping this using reflection and xml parsing.
The problem I am facing is some classes have static attributes that
gets initilized by calling a static method which uses data base etc. I
mean this need application server context. But my tool won't be runnig
in application server it is just a stand alone applicaion and get
required claases from class path.
If I have these kind of classes I get error when I do class.forName()
becuase these static variables trying to get initilized which needs
application server context.
I tried class.forName(className,boolean initlize, Claaloader) method
also by giving initilze as false. Now I face problem when I try to get
value of static final String. This try to initlize all the the
attributes of the class again and I get same error when I do
class.forName(className). Any suggestion welcome
I have following requirement.
Write information of metods in some class in xml format. The methods
will have some thing called atachement.
for eg:
public void mymethd(){}
public static final string atch$mymethd$description="Metod
description".
My xml will look like
<name ="mymethod" descriptin ="method description"/>
I am dping this using reflection and xml parsing.
The problem I am facing is some classes have static attributes that
gets initilized by calling a static method which uses data base etc. I
mean this need application server context. But my tool won't be runnig
in application server it is just a stand alone applicaion and get
required claases from class path.
If I have these kind of classes I get error when I do class.forName()
becuase these static variables trying to get initilized which needs
application server context.
I tried class.forName(className,boolean initlize, Claaloader) method
also by giving initilze as false. Now I face problem when I try to get
value of static final String. This try to initlize all the the
attributes of the class again and I get same error when I do
class.forName(className). Any suggestion welcome