Ok, here is the problem. There are several parts in the
code where the following snippet is used:

  Vector packages = TurbineResources.getVector("module.packages");
  packages.addElement( GenericLoader.getBasePackage() );

This in fact modifies the vector held in TurbineResources
(this is news to me, and different to the way the STL works
in C++, where the vector returned would NOT be a reference),
so each time this code is called, the vector size increases
by one. This is especially so in JavaBaseFactory::getAssembler(),
which is called many times. I'm not sure why, but this later
makes the loop iterate over all packages in the vector.

Quick solution: would it be Ok to replace that code with

  Vector packages = TurbineResources.getVector("module.packages");
  String basePackage = GenericLoader.getBasePackage();
  if (! vector.contains(basePackage))
    packages.addElement( basePackage );

everywhere? If yes, would this be a candidate for a utility
function, and where (what class)?

Thanks,


-- 
Gonzalo A. Diethelm
[EMAIL PROTECTED]


------------------------------------------------------------
To subscribe:        [EMAIL PROTECTED]
To unsubscribe:      [EMAIL PROTECTED]
Search: <http://www.mail-archive.com/turbine%40list.working-dogs.com/>
Problems?:           [EMAIL PROTECTED]

Reply via email to