Copyright © 1992, 1997 International Organization for Standardization. All rights reserved.

This electronic document is for use during development and review of International Standards. Official printed copies of International Standards can be purchased from the ISO and the national standards organization of your country.

Next ClausePrevious Clause  

homeParent clauseNext major clausePrevious major clauseNext clause at this levelPrevious clause at this level


7 Location address module

7.11 Querying

Subclauses:


HyTime recommends the use of the Standard Document Query Language (SDQL), defined in the DSSSL standard, ISO/IEC 10179:1996 Document Style Semantics and Specification Language, for the queryloc and nmquery element forms. The SDQL language includes equivalents of all the HyTime location address forms.

NOTE 202 This means, in part, that any location ladder can be replaced by the equivalent SDQL query.

However, any query notation can be used with HyTime as long as the notation can operate on groves and returns node lists as the result of the query.

NOTE 203 Any existing query mechanism can be integrated into a HyTime system by defining an appropriate property set and grove construction process for the data notation it is designed to work with.

HyTime defines a general query-based location address, queryloc that can be used both for general queries and as the base for specialized location addresses derived from the queryloc form. The hyperlinks module defines two queryloc-form location addreses, linkloc and anchloc, for addresing hyperlinks and their anchors according to their HyTime-specific semantics as reflected in the HyTime architectural semantic grove (see 8.3 Hyperlink-related location addresses). The scheduling module defines a queryloc-form location address, fcsloc, for addressing events in event schedules (see 9.10 Finite coordinate space location address).

7.11.1 Query location address

The element form query location address (queryloc) contains a query that returns a node list.

If the location source for a queryloc is a multiple location and is not a span location, each node in the location source is treated as the root of a separate query domain.

The attribute query notation (notation) specifies the data content notation governing the query specified by the query location address.

NOTE 204 The data attributes for elements (DAFE) facility can be used to provide notation-specific attributes for queryloc-form elements (see A.5.3 Data Attributes for Elements (DAFE)).

The attribute no data found (notfound) indicates the expected system response when the query fails to return any nodes: either report an RHE ("error") or ignore the query location address ("ignore").

                   <!-- Query Location Address -->
<![ %queryloc; [
<!element
   queryloc       -- Query location address --
                  -- Clause: 7.11.1 --
                  -- Locates objects in a grove using queries against
                     their properties as defined in the property set
                     used to construct the grove. --
   - O
   (%HyCFC;)*

-- Attributes [locs]: locsrc, queryloc, impsrc --
-- OptionalAttributes [locs]: multloc, referatt, spanloc, treetype --
-- CommonAttributes [GenArc]: dafe, dvlatt, etfullnm, id,
   ireftype, lextype, opacity --
-- CommonAttributes [base]: activity, conloc, dtxtatt, valueref --
-- CommonAttributes [locs]: refctl, refloc, reftype, rflocspn --
>
<!attlist
   queryloc       -- Query location address --
                  -- Clause: 7.11.1 --

   notation       -- Query notation --
      NAME        -- Lextype: NOTATION --
      #REQUIRED

   notfound       -- No data found --
      NAME        -- Lextype: ("ERROR"|"IGNORE") --
      ERROR
>
<!entity % locsrc "INCLUDE">
<!entity % impsrc "INCLUDE">
]]><!-- queryloc -->

7.11.2 Name list query

The element form name list query (nmquery) is a specialized form of query location address for which the query domain must either be the content tree rooted at an SGML element node in an SGML document grove or the value of the entities property of an SGMLDOC node. The attribute query domain (qdomain) addresses the location source for the query (qdomain is a synonym for locsrc).

              <!-- Name List Query Location Address -->
<![ %nameloc; %queryloc; [
<!element
   nmquery        -- Name list query location address --
                  -- Clause: 7.11.2 --
                  -- Locates elements or entities by querying their
                     properties. --
   - O
   (%HyCFC;)*

-- Attributes [locs]: locsrc, nmquery, impsrc --
-- OptionalAttributes [locs]: multloc, referatt, spanloc, treetype --
-- CommonAttributes [GenArc]: dafe, dvlatt, etfullnm, id,
   ireftype, lextype, opacity --
-- CommonAttributes [base]: activity, conloc, dtxtatt, valueref --
-- CommonAttributes [locs]: refctl, refloc, reftype, rflocspn --
>
<!attlist
   nmquery        -- Name list query location address --
                  -- Clause: 7.11.2 --

   HyBase   NAME     #FIXED queryloc
   HyBnames CDATA    #FIXED "locsrc qdomain"

   qdomain        -- Query domain --
      CDATA       -- Reference --
      #IMPLIED    -- Default: implied as described for impsrc --

   notation       -- Query notation --
      NAME        -- Lextype: NOTATION --
      #REQUIRED

   notfound       -- No data found --
      NAME        -- Lextype: ("ERROR"|"IGNORE") --
      ERROR
>
<!entity % locsrc "INCLUDE">
<!entity % impsrc "INCLUDE">
]]><!-- nmquery -->

Next ClausePrevious Clause  

Copyright © 1992, 1997 International Organization for Standardization. All rights reserved.

This electronic document is for use during development and review of International Standards. Official printed copies of International Standards can be purchased from the ISO and the national standards organization of your country.


HTML generated from the original SGML source using a DSSSL style specification and the SGML output back-end of the JADE DSSSL engine.