2
* Copyright (c) 2000 World Wide Web Consortium,
3
* (Massachusetts Institute of Technology, Institut National de
4
* Recherche en Informatique et en Automatique, Keio University). All
5
* Rights Reserved. This program is distributed under the W3C's Software
6
* Intellectual Property License. This program is distributed in the
7
* hope that it will be useful, but WITHOUT ANY WARRANTY; without even
8
* the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
10
* See W3C License http://www.w3.org/Consortium/Legal/ for more details.
13
// File: http://www.w3.org/TR/2000/REC-DOM-Level-2-Traversal-Range-20001113/ranges.idl
20
#pragma prefix "dom.w3c.org"
24
typedef dom::Node Node;
25
typedef dom::DocumentFragment DocumentFragment;
26
typedef dom::DOMString DOMString;
28
// Introduced in DOM Level 2:
29
exception RangeException {
33
const unsigned short BAD_BOUNDARYPOINTS_ERR = 1;
34
const unsigned short INVALID_NODE_TYPE_ERR = 2;
37
// Introduced in DOM Level 2:
39
readonly attribute Node startContainer;
40
// raises(dom::DOMException) on retrieval
42
readonly attribute long startOffset;
43
// raises(dom::DOMException) on retrieval
45
readonly attribute Node endContainer;
46
// raises(dom::DOMException) on retrieval
48
readonly attribute long endOffset;
49
// raises(dom::DOMException) on retrieval
51
readonly attribute boolean collapsed;
52
// raises(dom::DOMException) on retrieval
54
readonly attribute Node commonAncestorContainer;
55
// raises(dom::DOMException) on retrieval
57
void setStart(in Node refNode,
59
raises(RangeException,
61
void setEnd(in Node refNode,
63
raises(RangeException,
65
void setStartBefore(in Node refNode)
66
raises(RangeException,
68
void setStartAfter(in Node refNode)
69
raises(RangeException,
71
void setEndBefore(in Node refNode)
72
raises(RangeException,
74
void setEndAfter(in Node refNode)
75
raises(RangeException,
77
void collapse(in boolean toStart)
78
raises(dom::DOMException);
79
void selectNode(in Node refNode)
80
raises(RangeException,
82
void selectNodeContents(in Node refNode)
83
raises(RangeException,
87
const unsigned short START_TO_START = 0;
88
const unsigned short START_TO_END = 1;
89
const unsigned short END_TO_END = 2;
90
const unsigned short END_TO_START = 3;
92
short compareBoundaryPoints(in unsigned short how,
94
raises(dom::DOMException);
96
raises(dom::DOMException);
97
DocumentFragment extractContents()
98
raises(dom::DOMException);
99
DocumentFragment cloneContents()
100
raises(dom::DOMException);
101
void insertNode(in Node newNode)
102
raises(dom::DOMException,
104
void surroundContents(in Node newParent)
105
raises(dom::DOMException,
108
raises(dom::DOMException);
110
raises(dom::DOMException);
112
raises(dom::DOMException);
115
// Introduced in DOM Level 2:
116
interface DocumentRange {
121
#endif // _RANGES_IDL_