Subject: Re: [xsl] Pointers are weird From: "Elliotte Rusty Harold elharo@xxxxxxxxxxx" <xsl-list-service@xxxxxxxxxxxxxxxxxxxxxx> Date: Fri, 11 Apr 2025 17:42:22 -0000 |
No. XML does not have pointers, any more than it has ints or booleans. Elliotte Rusty Harold elharo@xxxxxxxxxxx On Fri, Apr 11, 2025 at 6:31b/AM Roger L Costello costello@xxxxxxxxx < xsl-list-service@xxxxxxxxxxxxxxxxxxxxxx> wrote: > Hi Folks, > > Occasionally friends come over to my home and I take them on a walk around > the neighborhood. When I see some thing interesting, I raise my hand and > position my index finger in the direction of the interesting thing. That > is, I point at the interesting thing. It seems to me, that that is a real > pointer--my index finger pointing at some thing. > > XML has pointers, e.g., > > <Book ref="SK">...</Book> > > <Author id="SK">Stephen King</Author> > > The value of the ref attribute, "SK", points to <Author id="SK"> > > "SK" doesn't look like a pointer to me. It looks like data. XML-aware > tools, however, treat it as a pointer to the <Author> element with a > matching id value. > > HTML has pointers, e.g., > > <a href="#lesson1">...</a> > > <p id="lesson1">...</p> > > The value of the href attribute, "#lesson1", points to <p id="lesson1"> > > "#lesson1" doesn't look like a pointer to me. It looks like data. > HTML-aware tools, however, treat it as a pointer to the <p> element with a > matching id value. > > I conclude that, in XML and HTML, a pointer is not a pointer at all. It's > data. It's data that is repeated elsewhere in the document: ("SK" ... > "SK"), ("#lesson1" ... "lesson1"). For this "pointer fiction" to work, a > tool that processes the document must participate in the fiction and treat > ref="SK" as pointing to <Author id="SK"> and treat href="#lesson1" as > pointing to <p id="lesson1">. > > Isn't that weird? > > /Roger
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
[xsl] Re: Pointers are weird, Jacopille, David (he | Thread | Re: [xsl] Pointers are weird, Dave Pawson dave.paw |
[xsl] Re: Pointers are weird, Jacopille, David (he | Date | Re: [xsl] Pointers are weird, Dave Pawson dave.paw |
Month |