Christopher,
What would be a simple example of input paramters for your call? And
what would you expect it to produce?
Two optimizations I can think of:
1) Assign a local variable to: psDelims.length
Assuming that psDelims is a character string of delimiters, then do this:
nDelimiters = psDelims.length
and re-use that in your inner loop
1b) Rather than indexing into a character string of delimiters, I
don't know if it would be faster to make a list of delimiters and
index into them as:
listOfDelimiters[i]
2) Rather than breaking up the strings yourself, you could try
assigning "the itemdelimiter" and then use "word 1" of the string to
pull out the tokens. I wonder if that would be faster?
Irv
At 12:35 PM -0800 3/4/02, Watson, Christopher wrote:
>Hello friends.
>
>Below you will find the properties and "new" handler for my string
>tokenizer. This object takes a string, and a collection of delimiters, and
>splits the string into an internally maintained linear list of tokens, based
>on the specified delimiting characters.
>
>I'm looking for ANY ways to optimize this "new" handler, without having to
>resort to TextCruncher or any other Xtra.
>
--
Lingo / Director / Shockwave development for all occasions.
(Home-made Lingo cooked up fresh every day just for you.)
[To remove yourself from this list, or to change to digest mode, go to
http://www.penworks.com/lingo-l.cgi To post messages to the list, email
[EMAIL PROTECTED] (Problems, email [EMAIL PROTECTED]). Lingo-L is for
learning and helping with programming Lingo. Thanks!]