RE: str:tokenize()
| Newsgroups | gmane.text.xml.xslt.extensions |
|---|---|
| Message-ID | <5150922C4A9FFE4DA2F658016BF9FA3C0329DC50@lnxseamail01.internal.courtlink.com> |
This sounds somewhat like str:split() although I'm not sure what you were thinking with the unlimited arguments. I had the same desire you mention so I put str:split together and posted it to EXSLT. It was accepted and can be found at: http://www.exslt.org/str/functions/split/index.html > -----Original Message----- > From: Casadome, Francisco [mailto:[email protected]] > Sent: Tuesday, September 23, 2003 9:23 AM > To: '[email protected]' > Subject: [exslt] str:tokenize() > > > Hi EXSLT, > > This is my first post on this list. > I really like the idea of EXSLT and would like to contribute to the > str:tokenize() function. > I'm currently working on a tokenizer and one thing I miss on > the function > posted on the web > is that you are forced to work with single characters. > I think it would be more useful to let the caller specify > strings instead of > characters. > This way you could split the string into tokens by ". " but > not ".", like in > the following example: > > String: "Edit the config.sys file. In the line > number [...]" > Expected result: <Token>Edit</Token> > <Token>the</Token> > <Token>config.sys</Token> > <Token>file</Token> > <Token>In</Token> > <Token>the</Token> > <Token>line</Token> > <Token>numer</Token> > > However, with the current implementation this is not possible. > The function definition would be something like this: > > node-set str:tokenize(string, string?, string?, string?, ...) > > Is this "unlimited" arguments number possible at all in XSLT ? > > I hope this helps to improve a little bit an already great idea. > > Regards, > > Francisco J. Casadomé Rodríguez > Linguistic Engineer - Linguistic Engineering Group > Bowne Global Solutions > http://www.bowneglobal.com > > _______________________________________________ > exslt mailing list > [email protected] > http://www.exslt.org/list >