Hello Diethelm,
Thursday, October 05, 2000, 1:41:47 AM, you wrote:
DGG> Quick solution: would it be Ok to replace that code with
DGG> Vector packages = TurbineResources.getVector("module.packages");
DGG> String basePackage = GenericLoader.getBasePackage();
DGG> if (! vector.contains(basePackage))
DGG> packages.addElement( basePackage );
What about creating new instance of vector?
It can be faster than looping through vector elements comparing long
string, although allocates additional memory...
Vector class implements Cloneable interface, so you can call clone().
Something like this:
Vector tmpPackages = TurbineResources.getVector("module.packages");
Vactor packages = (Vector) tmpPackages.clone();
packages.addElement( GenericLoader.getBasePackage() );
/ Shamil
------------------------------------------------------------
To subscribe: [EMAIL PROTECTED]
To unsubscribe: [EMAIL PROTECTED]
Search: <http://www.mail-archive.com/turbine%40list.working-dogs.com/>
Problems?: [EMAIL PROTECTED]
- Re: Are things much slower? [LONG] Leon Messerschmidt
- RE: Are things much slower? [LONG] Diethelm Guallar, Gonzalo
- Re: Are things much slower? [LONG] John McNally
- Re: Are things much slower? Christoph Reck
- Re: Are things much slower? Leon Messerschmidt
- RE: Are things much slower? [LONG] Diethelm Guallar, Gonzalo
- RE: Are things much slower? [LONG] Diethelm Guallar, Gonzalo
- Re: Are things much slower? [LONG] John McNally
- RE: Are things much slower? [LONG] Diethelm Guallar, Gonzalo
- Re: Are things much slower? [LONG] Jon Stevens
- RE: Are things much slower? [LONG] Shamil Yahin
- RE: Are things much slower? [LONG] Diethelm Guallar, Gonzalo
- Re: Are things much slower? [LONG] Jon Stevens
- Re: Are things much slower? [LONG] Fedor Karpelevitch
- Re: Are things much slower? [LONG] Peter Recore
- Re: Are things much slower? [LONG] Jon Stevens
- RE: Are things much slower? [LONG] Diethelm Guallar, Gonzalo
- RE: Are things much slower? [LONG] Craig Berry
- RE: Are things much slower? [LONG] Diethelm Guallar, Gonzalo
- Re: Are things much slower? [LONG] Jon Stevens
- RE: Are things much slower? [LONG] Craig Berry
