- From: Herbert van de Sompel <hvdsomp@gmail.com>
- Date: Thu, 21 Mar 2013 04:58:48 -0600
- To: Randall Leeds <randall.leeds@gmail.com>
- Cc: public-openannotation <public-openannotation@w3.org>
hi Randall, I did a brief presentation about Open Annotation at a recent EUDAT meeting (http://www.eudat.eu/2nd-eudat-user-forum) and got a question from the audience along the same lines of what you describe. If I remember correctly the person asking the question was involved in TEI work. Greetings Herbert On Wed, Mar 20, 2013 at 7:15 PM, Randall Leeds <randall.leeds@gmail.com> wrote: > In Annotator [0], the historical format for a selected range of a > document is a serialization of the properties of a DOM Range [1] > object (modulo a renaming of startContainer -> start, endContainer -> > end). > > In porting Annotator to use the OA spec, I've found it useful to still > store this selector, even as we store now an oa:TextQuoteSelector and > oa:TextPositionSelector. The reason is that it is cheapest to locate a > range by using XPath (when the XPath still properly identifies the > same text), since it can be done by direct traversal. > > It strikes me as a sensible addition to our spec to have a > DomRangeSelector. Since this is a standard that has been implemented > in browsers for quite some time it is familiar to developers and well > established. > > I would propose something like the following: > > oa:DomRangeSelector Class A resource which describes the > segment of interest as specified by the DOM Level 2 Traversal Range > specification. > oa:startContainer Property A string identifying the > element at the start of the range. > oa:startOffset Property A string identifying the > character offset within the start container. > oa:endContainer > oa:endOffset > > The only part I'm not sure how to specify well is the spelling of the > container values. We use XPath, but this could be xpointer or some > other thing. Probably to keep things simple, an XPath is adequate. > > For an example of an annotation with this format, see this URL for a > (JSON) representation, see [2]. > > I submit this proposal for discussion and comments from the group, > either for inclusion in Core or Extension. > > -R > > [0] http://okfn.org/labs/annotator > [1] http://www.w3.org/TR/DOM-Level-2-Traversal-Range/ranges.html > [2] https://dev.hypothes.is/api/v1/annotations/ODwQlmoYSX2JdzZF5zX_Uw > -- Herbert Van de Sompel Digital Library Research & Prototyping Los Alamos National Laboratory, Research Library http://public.lanl.gov/herbertv/ ==
Received on Thursday, 21 March 2013 10:59:19 UTC