dom/interfaces/xpath/nsIDOMXPathResult.idl

changeset 0
6474c204b198
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/dom/interfaces/xpath/nsIDOMXPathResult.idl	Wed Dec 31 06:09:35 2014 +0100
     1.3 @@ -0,0 +1,51 @@
     1.4 +/* -*- Mode: IDL; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
     1.5 +/* This Source Code Form is subject to the terms of the Mozilla Public
     1.6 + * License, v. 2.0. If a copy of the MPL was not distributed with this
     1.7 + * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
     1.8 +
     1.9 +/**
    1.10 + * Corresponds to http://www.w3.org/TR/2002/WD-DOM-Level-3-XPath-20020208
    1.11 + */
    1.12 +
    1.13 +#include "domstubs.idl"
    1.14 +
    1.15 +interface XPathException;
    1.16 +
    1.17 +[scriptable, uuid(75506f84-b504-11d5-a7f2-ca108ab8b6fc)]
    1.18 +interface nsIDOMXPathResult : nsISupports
    1.19 +{
    1.20 +  // XPathResultType
    1.21 +  const unsigned short      ANY_TYPE                       = 0;
    1.22 +  const unsigned short      NUMBER_TYPE                    = 1;
    1.23 +  const unsigned short      STRING_TYPE                    = 2;
    1.24 +  const unsigned short      BOOLEAN_TYPE                   = 3;
    1.25 +  const unsigned short      UNORDERED_NODE_ITERATOR_TYPE   = 4;
    1.26 +  const unsigned short      ORDERED_NODE_ITERATOR_TYPE     = 5;
    1.27 +  const unsigned short      UNORDERED_NODE_SNAPSHOT_TYPE   = 6;
    1.28 +  const unsigned short      ORDERED_NODE_SNAPSHOT_TYPE     = 7;
    1.29 +  const unsigned short      ANY_UNORDERED_NODE_TYPE        = 8;
    1.30 +  const unsigned short      FIRST_ORDERED_NODE_TYPE        = 9;
    1.31 +
    1.32 +  readonly attribute unsigned short   resultType;
    1.33 +  readonly attribute double           numberValue;
    1.34 +                                      // raises(XPathException) on retrieval
    1.35 +
    1.36 +  readonly attribute DOMString        stringValue;
    1.37 +                                      // raises(XPathException) on retrieval
    1.38 +
    1.39 +  readonly attribute boolean          booleanValue;
    1.40 +                                      // raises(XPathException) on retrieval
    1.41 +
    1.42 +  readonly attribute nsIDOMNode       singleNodeValue;
    1.43 +                                      // raises(XPathException) on retrieval
    1.44 +
    1.45 +  readonly attribute boolean          invalidIteratorState;
    1.46 +  readonly attribute unsigned long    snapshotLength;
    1.47 +                                      // raises(XPathException) on retrieval
    1.48 +
    1.49 +  nsIDOMNode               iterateNext()
    1.50 +                                      raises(XPathException, 
    1.51 +                                             DOMException);
    1.52 +  nsIDOMNode               snapshotItem(in unsigned long index)
    1.53 +                                      raises(XPathException);
    1.54 +};

mercurial