Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(718)

Side by Side Diff: Source/core/dom/Document.idl

Issue 360463005: Add [TypeChecking=Interface] on various methods in Document.idl (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: rebased Created 6 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « Source/core/dom/Document.cpp ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2006, 2007, 2011 Apple Inc. All rights reserved. 2 * Copyright (C) 2006, 2007, 2011 Apple Inc. All rights reserved.
3 * Copyright (C) 2006, 2007 Samuel Weinig <sam@webkit.org> 3 * Copyright (C) 2006, 2007 Samuel Weinig <sam@webkit.org>
4 * 4 *
5 * This library is free software; you can redistribute it and/or 5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Library General Public 6 * modify it under the terms of the GNU Library General Public
7 * License as published by the Free Software Foundation; either 7 * License as published by the Free Software Foundation; either
8 * version 2 of the License, or (at your option) any later version. 8 * version 2 of the License, or (at your option) any later version.
9 * 9 *
10 * This library is distributed in the hope that it will be useful, 10 * This library is distributed in the hope that it will be useful,
(...skipping 24 matching lines...) Expand all
35 DocumentFragment createDocumentFragment(); 35 DocumentFragment createDocumentFragment();
36 Text createTextNode(DOMString data); 36 Text createTextNode(DOMString data);
37 Comment createComment(DOMString data); 37 Comment createComment(DOMString data);
38 [RaisesException, MeasureAs=DocumentCreateCDATASection] CDATASection createC DATASection([Default=Undefined] optional DOMString data); // Removed from DOM4. 38 [RaisesException, MeasureAs=DocumentCreateCDATASection] CDATASection createC DATASection([Default=Undefined] optional DOMString data); // Removed from DOM4.
39 [RaisesException] ProcessingInstruction createProcessingInstruction(DOMStrin g target, DOMString data); 39 [RaisesException] ProcessingInstruction createProcessingInstruction(DOMStrin g target, DOMString data);
40 [RaisesException, MeasureAs=DocumentCreateAttribute] Attr createAttribute([D efault=Undefined] optional DOMString name); // Removed from DOM4. 40 [RaisesException, MeasureAs=DocumentCreateAttribute] Attr createAttribute([D efault=Undefined] optional DOMString name); // Removed from DOM4.
41 HTMLCollection getElementsByTagName(DOMString localName); 41 HTMLCollection getElementsByTagName(DOMString localName);
42 42
43 // Introduced in DOM Level 2: 43 // Introduced in DOM Level 2:
44 44
45 [CustomElementCallbacks, RaisesException] Node importNode(Node node, optiona l boolean deep); 45 [CustomElementCallbacks, RaisesException, TypeChecking=Interface] Node impor tNode(Node node, optional boolean deep);
46 [CustomElementCallbacks, RaisesException] Element createElementNS([TreatNull As=NullString] DOMString namespaceURI, DOMString qualifiedName); 46 [CustomElementCallbacks, RaisesException] Element createElementNS([TreatNull As=NullString] DOMString namespaceURI, DOMString qualifiedName);
47 [RaisesException, DeprecateAs=DocumentCreateAttributeNS] Attr createAttribut eNS([TreatNullAs=NullString,Default=Undefined] optional DOMString namespaceURI, 47 [RaisesException, DeprecateAs=DocumentCreateAttributeNS] Attr createAttribut eNS([TreatNullAs=NullString,Default=Undefined] optional DOMString namespaceURI,
48 [TreatNullAs=NullString,Default=Undefined] optional DOMString qualifiedName); // Removed from DOM4. 48 [TreatNullAs=NullString,Default=Undefined] optional DOMString qualifiedName); // Removed from DOM4.
49 HTMLCollection getElementsByTagNameNS([TreatNullAs=NullString] DOMString nam espaceURI, DOMString localName); 49 HTMLCollection getElementsByTagNameNS([TreatNullAs=NullString] DOMString nam espaceURI, DOMString localName);
50 [PerWorldBindings] Element getElementById(DOMString elementId); 50 [PerWorldBindings] Element getElementById(DOMString elementId);
51 51
52 // DOM Level 3 Core 52 // DOM Level 3 Core
53 53
54 [TreatReturnedNullStringAs=Null, MeasureAs=DocumentInputEncoding] readonly a ttribute DOMString inputEncoding; // Removed from DOM4. 54 [TreatReturnedNullStringAs=Null, MeasureAs=DocumentInputEncoding] readonly a ttribute DOMString inputEncoding; // Removed from DOM4.
55 55
56 [TreatReturnedNullStringAs=Null, MeasureAs=DocumentXMLEncoding] readonly att ribute DOMString xmlEncoding; // Removed from DOM4. 56 [TreatReturnedNullStringAs=Null, MeasureAs=DocumentXMLEncoding] readonly att ribute DOMString xmlEncoding; // Removed from DOM4.
57 [TreatReturnedNullStringAs=Null, TreatNullAs=NullString, RaisesException=Set ter, MeasureAs=DocumentXMLVersion] attribute DOMString xmlVersion; // Removed fr om DOM4. 57 [TreatReturnedNullStringAs=Null, TreatNullAs=NullString, RaisesException=Set ter, MeasureAs=DocumentXMLVersion] attribute DOMString xmlVersion; // Removed fr om DOM4.
58 [RaisesException=Setter, MeasureAs=DocumentXMLStandalone] attribute boolean xmlStandalone; // Removed from DOM4. 58 [RaisesException=Setter, MeasureAs=DocumentXMLStandalone] attribute boolean xmlStandalone; // Removed from DOM4.
59 59
60 [RaisesException, CustomElementCallbacks] Node adoptNode(Node node); 60 [RaisesException, CustomElementCallbacks, TypeChecking=Interface] Node adopt Node(Node node);
61 61
62 [TreatReturnedNullStringAs=Null, ImplementedAs=url] readonly attribute DOMSt ring documentURI; 62 [TreatReturnedNullStringAs=Null, ImplementedAs=url] readonly attribute DOMSt ring documentURI;
63 63
64 // DOM Level 2 Events (DocumentEvents interface) 64 // DOM Level 2 Events (DocumentEvents interface)
65 65
66 [RaisesException] Event createEvent(DOMString eventType); 66 [RaisesException] Event createEvent(DOMString eventType);
67 67
68 // DOM Level 2 Traversal and Range (DocumentRange interface) 68 // DOM Level 2 Traversal and Range (DocumentRange interface)
69 69
70 Range createRange(); 70 Range createRange();
71 71
72 // DOM Level 2 Traversal and Range (DocumentTraversal interface) 72 // DOM Level 2 Traversal and Range (DocumentTraversal interface)
73 73
74 [RaisesException] NodeIterator createNodeIterator(Node root, 74 [RaisesException, TypeChecking=Interface] NodeIterator createNodeIterator(No de root,
75 optional unsigned long wha tToShow = 0xFFFFFFFF, 75 op tional unsigned long whatToShow = 0xFFFFFFFF,
76 optional NodeFilter? filte r = null); 76 op tional NodeFilter? filter = null);
77 [RaisesException] TreeWalker createTreeWalker(Node root, 77 [RaisesException, TypeChecking=Interface] TreeWalker createTreeWalker(Node r oot,
78 optional unsigned long whatToS how = 0xFFFFFFFF, 78 option al unsigned long whatToShow = 0xFFFFFFFF,
79 optional NodeFilter? filter = null); 79 option al NodeFilter? filter = null);
80 80
81 // DOM Level 2 Abstract Views (DocumentView interface) 81 // DOM Level 2 Abstract Views (DocumentView interface)
82 82
83 [ImplementedAs=executingWindow] readonly attribute Window defaultView; 83 [ImplementedAs=executingWindow] readonly attribute Window defaultView;
84 84
85 // DOM Level 2 Style (DocumentStyle interface) 85 // DOM Level 2 Style (DocumentStyle interface)
86 86
87 readonly attribute StyleSheetList styleSheets; 87 readonly attribute StyleSheetList styleSheets;
88 88
89 // DOM Level 2 Style (DocumentCSS interface) 89 // DOM Level 2 Style (DocumentCSS interface)
90 90
91 CSSStyleDeclaration getOverrideStyle([Default=Undefined] optional Element e lement, 91 CSSStyleDeclaration getOverrideStyle([Default=Undefined] optional Element el ement,
92 [Default=Undefined] opti onal DOMString pseudoElement); 92 [Default=Undefined] optional DOMString pseudoElement);
93 93
94 // DOM 4 94 // DOM 4
95 readonly attribute DOMString contentType; 95 readonly attribute DOMString contentType;
96 96
97 // Common extensions 97 // Common extensions
98 [CustomElementCallbacks] 98 [CustomElementCallbacks]
99 boolean execCommand([Default=Undefined] optional DOMString comman d, 99 boolean execCommand([Default=Undefined] optional DOMString comman d,
100 [Default=Undefined] optional boolean userInte rface, 100 [Default=Undefined] optional boolean userInte rface,
101 [TreatNullAs=NullString, TreatUndefinedAs=Nul lString,Default=Undefined] optional DOMString value); 101 [TreatNullAs=NullString, TreatUndefinedAs=Nul lString,Default=Undefined] optional DOMString value);
102 102
(...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after
185 [RuntimeEnabled=Touch] attribute EventHandler ontouchend; 185 [RuntimeEnabled=Touch] attribute EventHandler ontouchend;
186 [RuntimeEnabled=Touch] attribute EventHandler ontouchmove; 186 [RuntimeEnabled=Touch] attribute EventHandler ontouchmove;
187 [RuntimeEnabled=Touch] attribute EventHandler ontouchstart; 187 [RuntimeEnabled=Touch] attribute EventHandler ontouchstart;
188 attribute EventHandler onwebkitfullscreenchange; 188 attribute EventHandler onwebkitfullscreenchange;
189 attribute EventHandler onwebkitfullscreenerror; 189 attribute EventHandler onwebkitfullscreenerror;
190 attribute EventHandler onwebkitpointerlockchange; 190 attribute EventHandler onwebkitpointerlockchange;
191 attribute EventHandler onwebkitpointerlockerror; 191 attribute EventHandler onwebkitpointerlockerror;
192 attribute EventHandler onwheel; 192 attribute EventHandler onwheel;
193 193
194 [RuntimeEnabled=Touch] Touch createTouch([Default=Undefined] optional Window window, 194 [RuntimeEnabled=Touch] Touch createTouch([Default=Undefined] optional Window window,
195 [Default=Undefined] optional Even tTarget target, 195 [Default=Undefined] optional EventT arget target,
196 [Default=Undefined] optional long identifier, 196 [Default=Undefined] optional long i dentifier,
197 [Default=Undefined] optional doub le pageX, 197 [Default=Undefined] optional double pageX,
198 [Default=Undefined] optional doub le pageY, 198 [Default=Undefined] optional double pageY,
199 [Default=Undefined] optional doub le screenX, 199 [Default=Undefined] optional double screenX,
200 [Default=Undefined] optional doub le screenY, 200 [Default=Undefined] optional double screenY,
201 [Default=Undefined] optional doub le webkitRadiusX, 201 [Default=Undefined] optional double webkitRadiusX,
202 [Default=Undefined] optional doub le webkitRadiusY, 202 [Default=Undefined] optional double webkitRadiusY,
203 [Default=Undefined] optional floa t webkitRotationAngle, 203 [Default=Undefined] optional float webkitRotationAngle,
204 [Default=Undefined] optional floa t webkitForce); 204 [Default=Undefined] optional float webkitForce);
205 [RuntimeEnabled=Touch] TouchList createTouchList(Touch... touches); 205 [RuntimeEnabled=Touch] TouchList createTouchList(Touch... touches);
206 206
207 [CallWith=ScriptState, CustomElementCallbacks, RaisesException, MeasureAs=Do cumentRegisterElement] CustomElementConstructor registerElement(DOMString name, optional Dictionary options); 207 [CallWith=ScriptState, CustomElementCallbacks, RaisesException, MeasureAs=Do cumentRegisterElement] CustomElementConstructor registerElement(DOMString name, optional Dictionary options);
208 [CustomElementCallbacks, PerWorldBindings, RaisesException] Element createEl ement(DOMString localName, [TreatNullAs=NullString] DOMString typeExtension); 208 [CustomElementCallbacks, PerWorldBindings, RaisesException] Element createEl ement(DOMString localName, [TreatNullAs=NullString] DOMString typeExtension);
209 [CustomElementCallbacks, RaisesException] Element createElementNS([TreatNull As=NullString] DOMString namespaceURI, DOMString qualifiedName, 209 [CustomElementCallbacks, RaisesException] Element createElementNS([TreatNull As=NullString] DOMString namespaceURI, DOMString qualifiedName,
210 [TreatNullAs=NullString] DOMString typeExtension); 210 [TreatNullAs=NullString] DOMString typeExtension);
211 211
212 // Page visibility API. 212 // Page visibility API.
213 readonly attribute DOMString visibilityState; 213 readonly attribute DOMString visibilityState;
214 readonly attribute boolean hidden; 214 readonly attribute boolean hidden;
215 215
216 // Deprecated prefixed page visibility API. 216 // Deprecated prefixed page visibility API.
217 // TODO(davidben): This is a property so attaching a deprecation warning res ults in false positives when outputting 217 // TODO(davidben): This is a property so attaching a deprecation warning res ults in false positives when outputting
218 // document in the console. It's possible http://crbug.com/43394 will resolv e this. 218 // document in the console. It's possible http://crbug.com/43394 will resolv e this.
219 [MeasureAs=PrefixedPageVisibility, ImplementedAs=visibilityState] readonly a ttribute DOMString webkitVisibilityState; 219 [MeasureAs=PrefixedPageVisibility, ImplementedAs=visibilityState] readonly a ttribute DOMString webkitVisibilityState;
220 [MeasureAs=PrefixedPageVisibility, ImplementedAs=hidden] readonly attribute boolean webkitHidden; 220 [MeasureAs=PrefixedPageVisibility, ImplementedAs=hidden] readonly attribute boolean webkitHidden;
221 221
222 readonly attribute HTMLScriptElement currentScript; 222 readonly attribute HTMLScriptElement currentScript;
223 }; 223 };
224 224
225 Document implements GlobalEventHandlers; 225 Document implements GlobalEventHandlers;
226 Document implements ParentNode; 226 Document implements ParentNode;
OLDNEW
« no previous file with comments | « Source/core/dom/Document.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698