[osis-core] annotateRef: Question on whitespace

Patrick Durusau osis-core@bibletechnologieswg.org
Mon, 15 Sep 2003 17:39:49 -0400


Todd,

Todd Tillinghast wrote:
> Patrick,
> 
<snip>

> 
> What if we did not allow whitespace but allowed the user to specify the
> occurrence number of the match string with a default to the first
> occurrence.
> 
> For example:
> <verse osisID="X.1.1">The trouble with string matching is that a string
> can have whitespace trouble makers.</verse>
> 
> <reference osisRef="X.1.1@s[trouble][2]"/> 
> 
> where the second [#] is optional but would indicate the #th occurrence
> of the match string
> 

Hmmm, Steve and I talked about this briefly this afternoon and if we 
require (in the doc) that @s[ ] always be used at the lowest container, 
the second occurrence cases should be fairly rare.

Still, I like your solution, support for which would be optional (?).

One of the reasons for the @s[ ] operator was that when Steve and I were 
doing the grain syntax, we picked a word fairly far into a verse and 
then had to count the characters to reach it. :-) Made us realize the 
need for an alternative syntax!

Steve? Looks like a winner to me. Hmmm, will need to redo the regex but 
that should not be a problem. (He said foolishly.)

Hope you are having a great day!

Patrick

-- 
Patrick Durusau
Director of Research and Development
Society of Biblical Literature
Patrick.Durusau@sbl-site.org
Chair, V1 - Text Processing: Office and Publishing Systems Interface
Co-Editor, ISO 13250, Topic Maps -- Reference Model

Topic Maps: Human, not artificial, intelligence at work!