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

Side by Side Diff: third_party/WebCore/bindings/scripts/test/TestObj.idl

Issue 10837033: Roll IDL to multivm@733 (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 4 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 | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2009 Google Inc. All rights reserved. 2 * Copyright (C) 2009 Google Inc. All rights reserved.
3 * Copyright (C) 2010 Apple Inc. All rights reserved. 3 * Copyright (C) 2010 Apple Inc. All rights reserved.
4 * 4 *
5 * Redistribution and use in source and binary formstrArg, with or without 5 * Redistribution and use in source and binary formstrArg, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
7 * are met: 7 * are met:
8 * 8 *
9 * 1. Redistributions of source code must retain the above copyright 9 * 1. Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer. 10 * notice, this list of conditions and the following disclaimer.
(...skipping 17 matching lines...) Expand all
28 */ 28 */
29 29
30 // This IDL file is for testing the bindings code generator and for tracking 30 // This IDL file is for testing the bindings code generator and for tracking
31 // changes in its ouput. 31 // changes in its ouput.
32 module test { 32 module test {
33 interface [ 33 interface [
34 Constructor(in [Callback] TestCallback testCallback), 34 Constructor(in [Callback] TestCallback testCallback),
35 InterfaceName=TestObject 35 InterfaceName=TestObject
36 ] TestObj { 36 ] TestObj {
37 // Attributes 37 // Attributes
38 readonly attribute long readOnlyIntAttr; 38 readonly attribute long readOnlyLongAttr;
39 readonly attribute DOMString readOnlyStringAttr; 39 readonly attribute DOMString readOnlyStringAttr;
40 readonly attribute TestObj readOnlyTestObjAttr; 40 readonly attribute TestObj readOnlyTestObjAttr;
41 #if defined(TESTING_JS) 41 #if defined(TESTING_JS) || defined(TESTING_V8)
42 static readonly attribute long staticReadOnlyIntAttr; 42 static readonly attribute long staticReadOnlyLongAttr;
43 static attribute DOMString staticStringAttr; 43 static attribute DOMString staticStringAttr;
44 static readonly attribute TestSubObjConstructor TestSubObj;
44 #endif 45 #endif
45 attribute short shortAttr; 46 attribute short shortAttr;
46 attribute unsigned short unsignedShortAttr; 47 attribute unsigned short unsignedShortAttr;
47 attribute long intAttr; 48 attribute long longAttr;
48 attribute long long longLongAttr; 49 attribute long long longLongAttr;
49 attribute unsigned long long unsignedLongLongAttr; 50 attribute unsigned long long unsignedLongLongAttr;
50 attribute DOMString stringAttr; 51 attribute DOMString stringAttr;
51 attribute TestObj testObjAttr; 52 attribute TestObj testObjAttr;
52 53
53 JS, V8 54 JS, V8
54 // WK_ucfirst, WK_lcfirst exceptional cases. 55 // WK_ucfirst, WK_lcfirst exceptional cases.
55 attribute TestObj XMLObjAttr; 56 attribute TestObj XMLObjAttr;
56 attribute boolean create; 57 attribute boolean create;
57 58
58 // Reflected DOM attributes 59 // Reflected DOM attributes
59 attribute [Reflect] DOMString reflectedStringAttr; 60 attribute [Reflect] DOMString reflectedStringAttr;
60 attribute [Reflect] long reflectedIntegralAttr; 61 attribute [Reflect] long reflectedIntegralAttr;
61 attribute [Reflect] unsigned long reflectedUnsignedIntegralAttr; 62 attribute [Reflect] unsigned long reflectedUnsignedIntegralAttr;
62 attribute [Reflect] boolean reflectedBooleanAttr; 63 attribute [Reflect] boolean reflectedBooleanAttr;
63 attribute [Reflect, URL] DOMString reflectedURLAttr; 64 attribute [Reflect, URL] DOMString reflectedURLAttr;
64 attribute [Reflect=customContentStringAttr] DOMString reflectedStringAtt r; 65 attribute [Reflect=customContentStringAttr] DOMString reflectedStringAtt r;
65 attribute [Reflect=customContentIntegralAttr] long reflectedCustomIntegr alAttr; 66 attribute [Reflect=customContentIntegralAttr] long reflectedCustomIntegr alAttr;
66 attribute [Reflect=customContentBooleanAttr] boolean reflectedCustomBool eanAttr; 67 attribute [Reflect=customContentBooleanAttr] boolean reflectedCustomBool eanAttr;
67 attribute [Reflect=customContentURLAttr, URL] DOMString reflectedCustomU RLAttr; 68 attribute [Reflect=customContentURLAttr, URL] DOMString reflectedCustomU RLAttr;
68 69
69 // Methods 70 // Methods
70 void voidMethod(); 71 void voidMethod();
71 void voidMethodWithArgs(in long intArg, in DOMString strArg, in TestO bj objArg); 72 void voidMethodWithArgs(in long longArg, in DOMString strArg, in Test Obj objArg);
72 long intMethod(); 73 long longMethod();
73 long intMethodWithArgs(in long intArg, in DOMString strArg, in TestOb j objArg); 74 long longMethodWithArgs(in long longArg, in DOMString strArg, in Test Obj objArg);
74 TestObj objMethod(); 75 TestObj objMethod();
75 TestObj objMethodWithArgs(in long intArg, in DOMString strArg, in TestOb j objArg); 76 TestObj objMethodWithArgs(in long longArg, in DOMString strArg, in TestO bj objArg);
76 77
77 void methodWithSequenceArg(in sequence<ScriptProfile> sequenceArg); 78 void methodWithSequenceArg(in sequence<ScriptProfile> sequenceArg);
78 sequence<ScriptProfile> methodReturningSequence(in long intArg); 79 sequence<ScriptProfile> methodReturningSequence(in long longArg);
79 80
80 TestObj methodThatRequiresAllArgsAndThrows(in DOMString strArg, in TestO bj objArg) 81 TestObj methodThatRequiresAllArgsAndThrows(in DOMString strArg, in TestO bj objArg)
81 raises(DOMException); 82 raises(DOMException);
82 83
83 void serializedValue(in SerializedScriptValue serializedArg); 84 void serializedValue(in SerializedScriptValue serializedArg);
84 void idbKey(in IDBKey key); 85 void idbKey(in IDBKey key);
85 void optionsObject(in Dictionary oo, in [Optional] Dictionary ooo); 86 void optionsObject(in Dictionary oo, in [Optional] Dictionary ooo);
86 87
87 // Exceptions 88 // Exceptions
88 void methodWithException() raises(DOMException); 89 void methodWithException() raises(DOMException);
89 attribute long attrWithGetterException getter raises(DOMException); 90 attribute long attrWithGetterException getter raises(DOMException);
90 attribute long attrWithSetterException setter raises(DOMException); 91 attribute long attrWithSetterException setter raises(DOMException);
91 attribute DOMString stringAttrWithGetterException getter raises(DOMExcep tion); 92 attribute DOMString stringAttrWithGetterException getter raises(DOMExcep tion);
92 attribute DOMString stringAttrWithSetterException setter raises(DOMExcep tion); 93 attribute DOMString stringAttrWithSetterException setter raises(DOMExcep tion);
93 94
94 // 'Custom' extended attribute 95 // 'Custom' extended attribute
95 attribute [Custom] long customAttr; 96 attribute [Custom] long customAttr;
96 [Custom] void customMethod(); 97 [Custom] void customMethod();
97 [Custom] void customMethodWithArgs(in long intArg, in DOMString strArg, in TestObj objArg); 98 [Custom] void customMethodWithArgs(in long longArg, in DOMString strArg, in TestObj objArg);
98 99
99 void addEventListener(in DOMString type, 100 void addEventListener(in DOMString type,
100 in EventListener listener, 101 in EventListener listener,
101 in [Optional] boolean useCapture); 102 in [Optional] boolean useCapture);
102 void removeEventListener(in DOMString type, 103 void removeEventListener(in DOMString type,
103 in EventListener listener, 104 in EventListener listener,
104 in [Optional] boolean useCapture); 105 in [Optional] boolean useCapture);
105 106
106 // 'CallWith' extended attribute 107 // 'CallWith' extended attribute
107 [CallWith=ScriptState] void withScriptStateVoid(); 108 [CallWith=ScriptState] void withScriptStateVoid();
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after
161 [Conditional=Condition1] const unsigned short CONDITIONAL_CONST = 0; 162 [Conditional=Condition1] const unsigned short CONDITIONAL_CONST = 0;
162 163
163 #if defined(TESTING_V8) || defined(TESTING_JS) 164 #if defined(TESTING_V8) || defined(TESTING_JS)
164 readonly attribute [CachedAttribute] any cachedAttribute1; 165 readonly attribute [CachedAttribute] any cachedAttribute1;
165 readonly attribute [CachedAttribute] any cachedAttribute2; 166 readonly attribute [CachedAttribute] any cachedAttribute2;
166 #endif 167 #endif
167 168
168 #if defined(TESTING_V8) || defined(TESTING_JS) 169 #if defined(TESTING_V8) || defined(TESTING_JS)
169 // Overloads 170 // Overloads
170 void overloadedMethod(in TestObj? objArg, in DOMString strArg); 171 void overloadedMethod(in TestObj? objArg, in DOMString strArg);
171 void overloadedMethod(in TestObj? objArg, in [Optional] long intArg); 172 void overloadedMethod(in TestObj? objArg, in [Optional] long longArg) ;
172 void overloadedMethod(in DOMString strArg); 173 void overloadedMethod(in DOMString strArg);
173 void overloadedMethod(in long intArg); 174 void overloadedMethod(in long longArg);
174 void overloadedMethod(in [Callback] TestCallback callback); 175 void overloadedMethod(in [Callback] TestCallback callback);
175 void overloadedMethod(in DOMStringList? listArg); 176 void overloadedMethod(in DOMStringList? listArg);
176 void overloadedMethod(in DOMString[]? arrayArg); 177 void overloadedMethod(in DOMString[]? arrayArg);
177 void overloadedMethod(in TestObj objArg); 178 void overloadedMethod(in TestObj objArg);
178 void overloadedMethod(in DOMString[] arrayArg); 179 void overloadedMethod(in DOMString[] arrayArg);
180 void overloadedMethod(in sequence<unsigned long> arrayArg);
179 #endif 181 #endif
180 182
181 // Class methods within JavaScript (like what's used for IDBKeyRange). 183 // Class methods within JavaScript (like what's used for IDBKeyRange).
182 static void classMethod(); 184 static void classMethod();
183 static long classMethodWithOptional(in [Optional] long arg); 185 static long classMethodWithOptional(in [Optional] long arg);
184 [Custom] static void classMethod2(in long arg); 186 [Custom] static void classMethod2(in long arg);
185 187
186 // Static method with conditional on overloaded methods 188 // Static method with conditional on overloaded methods
187 [Conditional=Condition1] static void overloadedMethod1(in long arg); 189 [Conditional=Condition1] static void overloadedMethod1(in long arg);
188 [Conditional=Condition1] static void overloadedMethod1(in DOMString type ); 190 [Conditional=Condition1] static void overloadedMethod1(in DOMString type );
189 191
192 void classMethodWithClamp(in [Clamp] unsigned short objArgsShort, in [Cl amp] unsigned long objArgsLong);
193
190 #if defined(TESTING_V8) 194 #if defined(TESTING_V8)
191 // 'V8EnabledAtRuntime' methods and attributes. 195 // 'V8EnabledAtRuntime' methods and attributes.
192 [V8EnabledAtRuntime] void enabledAtRuntimeMethod1(in int intArg); 196 [V8EnabledAtRuntime] void enabledAtRuntimeMethod1(in long longArg);
193 [V8EnabledAtRuntime=FeatureName] void enabledAtRuntimeMethod2(in int int Arg); 197 [V8EnabledAtRuntime=FeatureName] void enabledAtRuntimeMethod2(in long lo ngArg);
194 attribute [V8EnabledAtRuntime] long enabledAtRuntimeAttr1; 198 attribute [V8EnabledAtRuntime] long enabledAtRuntimeAttr1;
195 attribute [V8EnabledAtRuntime=FeatureName] long enabledAtRuntimeAttr2; 199 attribute [V8EnabledAtRuntime=FeatureName] long enabledAtRuntimeAttr2;
196 // V8EnabledPerContext currently only supports attributes. 200 // 'V8EnabledPerContext' methods and attributes.
197 attribute [V8EnabledPerContext] long enabledAtContextAttr1; 201 [V8EnabledPerContext] void enabledPerContextMethod1(in long longArg);
198 attribute [V8EnabledPerContext=FeatureName] long enabledAtContextAttr2; 202 [V8EnabledPerContext=FeatureName] void enabledPerContextMethod2(in long longArg);
203 attribute [V8EnabledPerContext] long enabledPerContextAttr1;
204 attribute [V8EnabledPerContext=FeatureName] long enabledPerContextAttr2;
199 #endif 205 #endif
200 206
201 207
202 #if defined(TESTING_V8) 208 #if defined(TESTING_V8)
203 attribute float[] floatArray; 209 attribute float[] floatArray;
204 attribute double[] doubleArray; 210 attribute double[] doubleArray;
205 #endif 211 #endif
206 212
207 #if defined(TESTING_JS) 213 #if defined(TESTING_JS)
208 void methodWithUnsignedLongArray(in unsigned long[] unsignedLongArray); 214 void methodWithUnsignedLongSequence(in sequence<unsigned long> unsignedL ongSequence);
209 #endif 215 #endif
210 #if defined(TESTING_V8) || defined(TESTING_JS) 216 #if defined(TESTING_V8) || defined(TESTING_JS)
211 DOMString[] stringArrayFunction(in DOMString[] values) raises(DOMExcepti on); 217 DOMString[] stringArrayFunction(in DOMString[] values) raises(DOMExcepti on);
212 #endif 218 #endif
213 219
214 readonly attribute [CheckSecurityForNode] Document contentDocument; 220 readonly attribute [CheckSecurityForNode] Document contentDocument;
215 [CheckSecurityForNode] SVGDocument getSVGDocument() 221 [CheckSecurityForNode] SVGDocument getSVGDocument()
216 raises(DOMException); 222 raises(DOMException);
217 223
218 void convert1(in [TreatReturnedNullStringAs=Null] a); 224 void convert1(in [TreatReturnedNullStringAs=Null] a);
219 void convert2(in [TreatReturnedNullStringAs=Undefined] b); 225 void convert2(in [TreatReturnedNullStringAs=Undefined] b);
220 void convert3(in [TreatReturnedNullStringAs=False] c); 226 void convert3(in [TreatReturnedNullStringAs=False] c);
221 void convert4(in [TreatNullAs=NullString] d); 227 void convert4(in [TreatNullAs=NullString] d);
222 void convert5(in [TreatNullAs=NullString, TreatUndefinedAs=NullString] e ); 228 void convert5(in [TreatNullAs=NullString, TreatUndefinedAs=NullString] e );
223 229
224 attribute SVGPoint mutablePoint; 230 attribute SVGPoint mutablePoint;
225 attribute [Immutable] SVGPoint immutablePoint; 231 attribute [Immutable] SVGPoint immutablePoint;
226 SVGPoint mutablePointFunction(); 232 SVGPoint mutablePointFunction();
227 [Immutable] SVGPoint immutablePointFunction(); 233 [Immutable] SVGPoint immutablePointFunction();
228 234
229 [ImplementedAs=banana] void orange(); 235 [ImplementedAs=banana] void orange();
230 attribute [ImplementedAs=blueberry] int strawberry; 236 attribute [ImplementedAs=blueberry] long strawberry;
231 237
232 attribute [StrictTypeChecking] float strictFloat; 238 attribute [StrictTypeChecking] float strictFloat;
233 [StrictTypeChecking] bool strictFunction(in DOMString str, in float a, i n int b) 239 [StrictTypeChecking] bool strictFunction(in DOMString str, in float a, i n long b)
234 raises(DOMException); 240 raises(DOMException);
235 241
236 // ObjectiveC reserved words. 242 // ObjectiveC reserved words.
237 readonly attribute long description; 243 readonly attribute long description;
238 attribute long id; 244 attribute long id;
239 readonly attribute DOMString hash; 245 readonly attribute DOMString hash;
240 246
241 // Check constants and enums. 247 // Check constants and enums.
242 const unsigned short CONST_VALUE_0 = 0; 248 const unsigned short CONST_VALUE_0 = 0;
243 const unsigned short CONST_VALUE_1 = 1; 249 const unsigned short CONST_VALUE_1 = 1;
244 const unsigned short CONST_VALUE_2 = 2; 250 const unsigned short CONST_VALUE_2 = 2;
245 const unsigned short CONST_VALUE_4 = 4; 251 const unsigned short CONST_VALUE_4 = 4;
246 const unsigned short CONST_VALUE_8 = 8; 252 const unsigned short CONST_VALUE_8 = 8;
247 const short CONST_VALUE_9 = -1; 253 const short CONST_VALUE_9 = -1;
248 const DOMString CONST_VALUE_10 = "my constant string"; 254 const DOMString CONST_VALUE_10 = "my constant string";
249 const unsigned short CONST_VALUE_11 = 0xffffffff; 255 const unsigned short CONST_VALUE_11 = 0xffffffff;
250 const unsigned short CONST_VALUE_12 = 0x01; 256 const unsigned short CONST_VALUE_12 = 0x01;
251 const unsigned short CONST_VALUE_13 = 0X20; 257 const unsigned short CONST_VALUE_13 = 0X20;
252 const unsigned short CONST_VALUE_14 = 0x1abc; 258 const unsigned short CONST_VALUE_14 = 0x1abc;
253 [Reflect=CONST_IMPL] const unsigned short CONST_JAVASCRIPT = 15; 259 [Reflect=CONST_IMPL] const unsigned short CONST_JAVASCRIPT = 15;
254 260
255 attribute [Replaceable] long replaceableAttribute; 261 attribute [Replaceable] long replaceableAttribute;
256 }; 262 };
257 } 263 }
OLDNEW
« no previous file with comments | « third_party/WebCore/README ('k') | third_party/WebCore/bindings/scripts/test/TestSupplemental.idl » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698