Morgan Delagrange wrote:
OK, Java-specific question.  It seems likely that
altering or inlining LGPL code pollutes the Apache
license.  Are you of the opinion that IMPORTING but
not altering or distributing LGPL classes pollutes the
Apache licecnse?  And if so, can that be stated on the
Wiki page?  If LGPL code cannot be imported, it's
pretty much useless in any capacity for Java projects.

Bingo.

The only *reasonable* way of dealing with LGLP stuff would be thru some for of reflection (reflection, for those who don't know, is the ability for java to connect to 'named' resources of classes. it's the most *dynamic* form of loading for a language which is already entirely dynamically loaded).

So, suppose that LGPLObject is there somewhere in your classloading space (the classloader is the virtual machine subsystem that looks for your classes, classes being the objects and main units for java programs, all classes are always dynamically loaded)

and this LGPLObject contains the method (java terminology for a function) called doSomething()

If you use *regular* programming practices you have to do

 import LGPLObject;

then

 LGPLObject o = new LGPLObject();
 o.doSomething();

that will

 1) ask the classloader to find that object
 2) allocate memory for it
 3) create the object
 4) invoke the object method doSomething

This means, mostly, for legal sakes that the LGPLObject *MUST* be in the classloading space during compilation time.

Now, if we use reflection, we can do

  Class c = Class.forName("LGPLObject");
  Object o = c.newInstance();
  Method doSomething = c.getMethod("doSomething");
  doSomething.invoke();

which compiles even without having the LGPL library in your classpath.

*BUT* programming java in this way is *FOOLISH*. Reflection was created to load classes programmatically at runtime, it was not created as a way to route around legal problems.

--
Stefano Mazzocchi                               <[EMAIL PROTECTED]>
   Pluralitas non est ponenda sine necessitate [William of Ockham]
--------------------------------------------------------------------



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to