Sean,

Thanks for the response, and a lot of the issue I am sure come from my lack
of understanding regarding class loaders. I guess what I mean, if I can
explain it a bit better, is that the first time I looked up class loading it
seemed somewhat complicated to implement in CF since I think I had to create
an array of Urls and pass that around and have have URL instances or
something like that. 

1) So I guess what I mean is first time I load the class:

// Do all the complex url class loading to get the class in the heap or
memory space or whatever you might refer to it (I don't know that end of the
stuff)

2) Then after that, is it possible to load (after first loading):

CreateObject("java", "ben.coooolcomponents.foo").Init()

As if it was "part" of the java name spaces???

Does this make any more sense... sorry I don't know all the proper
terminology to help explain what I really mean. 

......................
Ben Nadel 
Web Developer
Nylon Technology
6 West 14th Street
New York, NY 10011
212.691.1134
212.691.3477 fax
www.nylontechnology.com

"Vote for Pedro"

-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf
Of Sean Corfield
Sent: Friday, December 16, 2005 10:40 AM
To: [email protected]
Subject: Re: [CFCDev] Anyone using java.net.URLClassLoader?

On 12/16/05, Ben Nadel <[EMAIL PROTECTED]> wrote:
> If you use a class loader to load a java class, does that class now live
in
> the ColdFusion memory space the way a class would if it's path was set in
> the ColdFusion admin....

That's not entirely a straightforward question to answer because it
depends on what the class loader actually does... However, classes
generally live in a specific part of memory so, yes, it's much the
same as adding a class to the class path (in this case if you use the
CFMX class loader to load a Java class explicitly, it will be the same
as if CFMX had loaded it implicitly) - however classes don't live in
"the ColdFusion memory space" (I assume you mean the regular heap).
Java memory management is pretty complex but Sun have a lot of
documentation on how the various memory spaces all work (perm, eden,
survivor etc).

> if you use class loader, does it incur large
> overhead everytime you load that javaclass? Or just the first time, the
rest
> being like built in java classes?

Again, it depends on which class loader you use and how it's written.
In general, I'd say don't worry about it...
--
Sean A Corfield -- http://corfield.org/
Got frameworks?

"If you're not annoying somebody, you're not really alive."
-- Margaret Atwood


----------------------------------------------------------
You are subscribed to cfcdev. To unsubscribe, send an email to
[email protected] with the words 'unsubscribe cfcdev' as the subject of the
email.

CFCDev is run by CFCZone (www.cfczone.org) and supported by CFXHosting
(www.cfxhosting.com).

An archive of the CFCDev list is available at
www.mail-archive.com/[email protected]





----------------------------------------------------------
You are subscribed to cfcdev. To unsubscribe, send an email to 
[email protected] with the words 'unsubscribe cfcdev' as the subject of the 
email.

CFCDev is run by CFCZone (www.cfczone.org) and supported by CFXHosting 
(www.cfxhosting.com).

An archive of the CFCDev list is available at 
www.mail-archive.com/[email protected]


Reply via email to