You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by temp temp <mi...@yahoo.com> on 2007/07/18 15:44:46 UTC

[JAVA] using clas.forname()

    How can I  know whether a class is already loaded ?   
  or  if I call class.forname(“Some class name”)   twice will there be any problems ?
  Thanks
  Miro
    
       
---------------------------------
Need a vacation? Get great deals to amazing places on Yahoo! Travel. 

[OT] RE: [JAVA] using clas.forname()

Posted by Dave Newton <ne...@yahoo.com>.
--- temp temp <mi...@yahoo.com> wrote:
> but can  I call  Class.forName()   for same class
> more than  once 
>   exmple
>   class.forName("Test")
>   class.forName("Test")
>   even If i can do this i donot want to load the
> class once it is already  loaded so how  can I find
> if the class is already loaded ?

Search teh intarwebs for "singleton".

d.



      ____________________________________________________________________________________
Park yourself in front of a world of choices in alternative vehicles. Visit the Yahoo! Auto Green Center.
http://autos.yahoo.com/green_center/ 

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


RE: [JAVA] using clas.forname()

Posted by temp temp <mi...@yahoo.com>.
but can  I call  Class.forName()   for same class more than  once 
  exmple
  class.forName("Test")
  class.forName("Test")
  even If i can do this i donot want to load the class once it is already  loaded so how  can I find if the class is already loaded ?
Miro
  Neil Aggarwal <ne...@JAMMConsulting.com> wrote:  Miro:

You can call Class.forName() as many times as you
like without a problem.

 Neil 

--
Neil Aggarwal, (832)245-7314, www.JAMMConsulting.com
FREE! Eliminate junk email and reclaim your inbox.
Visit http://www.spammilter.com for details.

-----Original Message-----
From: temp temp [mailto:miroconnect@yahoo.com] 
Sent: Wednesday, July 18, 2007 8:45 AM
To: user@struts.apache.org
Subject: [JAVA] using clas.forname()

    How can I  know whether a class is already loaded ?   
  or  if I call class.forname("Some class name")   twice will there be any
problems ?
  Thanks
  Miro
    
       
---------------------------------
Need a vacation? Get great deals to amazing places on Yahoo! Travel. 


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org



       
---------------------------------
Need a vacation? Get great deals to amazing places on Yahoo! Travel. 

RE: [JAVA] using clas.forname()

Posted by Al Sutton <al...@alsutton.com>.
You might get a problem if the class isn't there :).

-----Original Message-----
From: Neil Aggarwal [mailto:neil@JAMMConsulting.com] 
Sent: 18 July 2007 14:47
To: 'Struts Users Mailing List'
Subject: RE: [JAVA] using clas.forname()


Miro:

You can call Class.forName() as many times as you
like without a problem.

	Neil 

--
Neil Aggarwal, (832)245-7314, www.JAMMConsulting.com
FREE! Eliminate junk email and reclaim your inbox.
Visit http://www.spammilter.com for details.

-----Original Message-----
From: temp temp [mailto:miroconnect@yahoo.com] 
Sent: Wednesday, July 18, 2007 8:45 AM
To: user@struts.apache.org
Subject: [JAVA] using clas.forname()

    How can I  know whether a class is already loaded ?   
  or  if I call class.forname("Some class name")   twice will there be any
problems ?
  Thanks
  Miro
    
       
---------------------------------
Need a vacation? Get great deals to amazing places on Yahoo! Travel. 


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


RE: [JAVA] using clas.forname()

Posted by Neil Aggarwal <ne...@JAMMConsulting.com>.
Miro:

You can call Class.forName() as many times as you
like without a problem.

	Neil 

--
Neil Aggarwal, (832)245-7314, www.JAMMConsulting.com
FREE! Eliminate junk email and reclaim your inbox.
Visit http://www.spammilter.com for details.

-----Original Message-----
From: temp temp [mailto:miroconnect@yahoo.com] 
Sent: Wednesday, July 18, 2007 8:45 AM
To: user@struts.apache.org
Subject: [JAVA] using clas.forname()

    How can I  know whether a class is already loaded ?   
  or  if I call class.forname("Some class name")   twice will there be any
problems ?
  Thanks
  Miro
    
       
---------------------------------
Need a vacation? Get great deals to amazing places on Yahoo! Travel. 


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org