Sat, 03 Jan 2015 20:18:00 +0100
Conditionally enable double key logic according to:
private browsing mode or privacy.thirdparty.isolate preference and
implement in GetCookieStringCommon and FindCookie where it counts...
With some reservations of how to convince FindCookie users to test
condition and pass a nullptr when disabling double key logic.
michael@0 | 1 | /* -*- Mode: IDL; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ |
michael@0 | 2 | /* This Source Code Form is subject to the terms of the Mozilla Public |
michael@0 | 3 | * License, v. 2.0. If a copy of the MPL was not distributed with this file, |
michael@0 | 4 | * You can obtain one at http://mozilla.org/MPL/2.0/. |
michael@0 | 5 | */ |
michael@0 | 6 | |
michael@0 | 7 | typedef TestJSImplInterface AnotherNameForTestJSImplInterface; |
michael@0 | 8 | typedef TestJSImplInterface YetAnotherNameForTestJSImplInterface; |
michael@0 | 9 | typedef TestJSImplInterface? NullableTestJSImplInterface; |
michael@0 | 10 | |
michael@0 | 11 | callback MyTestCallback = void(); |
michael@0 | 12 | |
michael@0 | 13 | TestInterface implements ImplementedInterface; |
michael@0 | 14 | |
michael@0 | 15 | enum MyTestEnum { |
michael@0 | 16 | "a", |
michael@0 | 17 | "b" |
michael@0 | 18 | }; |
michael@0 | 19 | |
michael@0 | 20 | // We don't support multiple constructors (bug 869268) or named constructors |
michael@0 | 21 | // for JS-implemented WebIDL. |
michael@0 | 22 | [Constructor(DOMString str, unsigned long num, boolean? boolArg, |
michael@0 | 23 | TestInterface? iface, long arg1, |
michael@0 | 24 | DictForConstructor dict, any any1, |
michael@0 | 25 | object obj1, |
michael@0 | 26 | object? obj2, sequence<Dict> seq, optional any any2, |
michael@0 | 27 | optional object obj3, |
michael@0 | 28 | optional object? obj4), |
michael@0 | 29 | JSImplementation="@mozilla.org/test-js-impl-interface;1"] |
michael@0 | 30 | interface TestJSImplInterface { |
michael@0 | 31 | // Integer types |
michael@0 | 32 | // XXXbz add tests for throwing versions of all the integer stuff |
michael@0 | 33 | readonly attribute byte readonlyByte; |
michael@0 | 34 | attribute byte writableByte; |
michael@0 | 35 | void passByte(byte arg); |
michael@0 | 36 | byte receiveByte(); |
michael@0 | 37 | void passOptionalByte(optional byte arg); |
michael@0 | 38 | void passOptionalByteBeforeRequired(optional byte arg1, byte arg2); |
michael@0 | 39 | void passOptionalByteWithDefault(optional byte arg = 0); |
michael@0 | 40 | void passOptionalByteWithDefaultBeforeRequired(optional byte arg1 = 0, byte arg2); |
michael@0 | 41 | void passNullableByte(byte? arg); |
michael@0 | 42 | void passOptionalNullableByte(optional byte? arg); |
michael@0 | 43 | void passVariadicByte(byte... arg); |
michael@0 | 44 | [Cached, Pure] |
michael@0 | 45 | readonly attribute byte cachedByte; |
michael@0 | 46 | [Cached, Constant] |
michael@0 | 47 | readonly attribute byte cachedConstantByte; |
michael@0 | 48 | [Cached, Pure] |
michael@0 | 49 | attribute byte cachedWritableByte; |
michael@0 | 50 | |
michael@0 | 51 | readonly attribute short readonlyShort; |
michael@0 | 52 | attribute short writableShort; |
michael@0 | 53 | void passShort(short arg); |
michael@0 | 54 | short receiveShort(); |
michael@0 | 55 | void passOptionalShort(optional short arg); |
michael@0 | 56 | void passOptionalShortWithDefault(optional short arg = 5); |
michael@0 | 57 | |
michael@0 | 58 | readonly attribute long readonlyLong; |
michael@0 | 59 | attribute long writableLong; |
michael@0 | 60 | void passLong(long arg); |
michael@0 | 61 | long receiveLong(); |
michael@0 | 62 | void passOptionalLong(optional long arg); |
michael@0 | 63 | void passOptionalLongWithDefault(optional long arg = 7); |
michael@0 | 64 | |
michael@0 | 65 | readonly attribute long long readonlyLongLong; |
michael@0 | 66 | attribute long long writableLongLong; |
michael@0 | 67 | void passLongLong(long long arg); |
michael@0 | 68 | long long receiveLongLong(); |
michael@0 | 69 | void passOptionalLongLong(optional long long arg); |
michael@0 | 70 | void passOptionalLongLongWithDefault(optional long long arg = -12); |
michael@0 | 71 | |
michael@0 | 72 | readonly attribute octet readonlyOctet; |
michael@0 | 73 | attribute octet writableOctet; |
michael@0 | 74 | void passOctet(octet arg); |
michael@0 | 75 | octet receiveOctet(); |
michael@0 | 76 | void passOptionalOctet(optional octet arg); |
michael@0 | 77 | void passOptionalOctetWithDefault(optional octet arg = 19); |
michael@0 | 78 | |
michael@0 | 79 | readonly attribute unsigned short readonlyUnsignedShort; |
michael@0 | 80 | attribute unsigned short writableUnsignedShort; |
michael@0 | 81 | void passUnsignedShort(unsigned short arg); |
michael@0 | 82 | unsigned short receiveUnsignedShort(); |
michael@0 | 83 | void passOptionalUnsignedShort(optional unsigned short arg); |
michael@0 | 84 | void passOptionalUnsignedShortWithDefault(optional unsigned short arg = 2); |
michael@0 | 85 | |
michael@0 | 86 | readonly attribute unsigned long readonlyUnsignedLong; |
michael@0 | 87 | attribute unsigned long writableUnsignedLong; |
michael@0 | 88 | void passUnsignedLong(unsigned long arg); |
michael@0 | 89 | unsigned long receiveUnsignedLong(); |
michael@0 | 90 | void passOptionalUnsignedLong(optional unsigned long arg); |
michael@0 | 91 | void passOptionalUnsignedLongWithDefault(optional unsigned long arg = 6); |
michael@0 | 92 | |
michael@0 | 93 | readonly attribute unsigned long long readonlyUnsignedLongLong; |
michael@0 | 94 | attribute unsigned long long writableUnsignedLongLong; |
michael@0 | 95 | void passUnsignedLongLong(unsigned long long arg); |
michael@0 | 96 | unsigned long long receiveUnsignedLongLong(); |
michael@0 | 97 | void passOptionalUnsignedLongLong(optional unsigned long long arg); |
michael@0 | 98 | void passOptionalUnsignedLongLongWithDefault(optional unsigned long long arg = 17); |
michael@0 | 99 | |
michael@0 | 100 | attribute float writableFloat; |
michael@0 | 101 | attribute unrestricted float writableUnrestrictedFloat; |
michael@0 | 102 | attribute float? writableNullableFloat; |
michael@0 | 103 | attribute unrestricted float? writableNullableUnrestrictedFloat; |
michael@0 | 104 | attribute double writableDouble; |
michael@0 | 105 | attribute unrestricted double writableUnrestrictedDouble; |
michael@0 | 106 | attribute double? writableNullableDouble; |
michael@0 | 107 | attribute unrestricted double? writableNullableUnrestrictedDouble; |
michael@0 | 108 | void passFloat(float arg1, unrestricted float arg2, |
michael@0 | 109 | float? arg3, unrestricted float? arg4, |
michael@0 | 110 | double arg5, unrestricted double arg6, |
michael@0 | 111 | double? arg7, unrestricted double? arg8, |
michael@0 | 112 | sequence<float> arg9, sequence<unrestricted float> arg10, |
michael@0 | 113 | sequence<float?> arg11, sequence<unrestricted float?> arg12, |
michael@0 | 114 | sequence<double> arg13, sequence<unrestricted double> arg14, |
michael@0 | 115 | sequence<double?> arg15, sequence<unrestricted double?> arg16); |
michael@0 | 116 | [LenientFloat] |
michael@0 | 117 | void passLenientFloat(float arg1, unrestricted float arg2, |
michael@0 | 118 | float? arg3, unrestricted float? arg4, |
michael@0 | 119 | double arg5, unrestricted double arg6, |
michael@0 | 120 | double? arg7, unrestricted double? arg8, |
michael@0 | 121 | sequence<float> arg9, |
michael@0 | 122 | sequence<unrestricted float> arg10, |
michael@0 | 123 | sequence<float?> arg11, |
michael@0 | 124 | sequence<unrestricted float?> arg12, |
michael@0 | 125 | sequence<double> arg13, |
michael@0 | 126 | sequence<unrestricted double> arg14, |
michael@0 | 127 | sequence<double?> arg15, |
michael@0 | 128 | sequence<unrestricted double?> arg16); |
michael@0 | 129 | [LenientFloat] |
michael@0 | 130 | attribute float lenientFloatAttr; |
michael@0 | 131 | [LenientFloat] |
michael@0 | 132 | attribute double lenientDoubleAttr; |
michael@0 | 133 | |
michael@0 | 134 | // Castable interface types |
michael@0 | 135 | // XXXbz add tests for throwing versions of all the castable interface stuff |
michael@0 | 136 | TestJSImplInterface receiveSelf(); |
michael@0 | 137 | TestJSImplInterface? receiveNullableSelf(); |
michael@0 | 138 | |
michael@0 | 139 | // Callback interface ignores 'resultNotAddRefed'. See bug 843272. |
michael@0 | 140 | //TestJSImplInterface receiveWeakSelf(); |
michael@0 | 141 | //TestJSImplInterface? receiveWeakNullableSelf(); |
michael@0 | 142 | |
michael@0 | 143 | // A version to test for casting to TestJSImplInterface& |
michael@0 | 144 | void passSelf(TestJSImplInterface arg); |
michael@0 | 145 | void passNullableSelf(TestJSImplInterface? arg); |
michael@0 | 146 | attribute TestJSImplInterface nonNullSelf; |
michael@0 | 147 | attribute TestJSImplInterface? nullableSelf; |
michael@0 | 148 | [Cached, Pure] |
michael@0 | 149 | readonly attribute TestJSImplInterface cachedSelf; |
michael@0 | 150 | // Optional arguments |
michael@0 | 151 | void passOptionalSelf(optional TestJSImplInterface? arg); |
michael@0 | 152 | void passOptionalNonNullSelf(optional TestJSImplInterface arg); |
michael@0 | 153 | void passOptionalSelfWithDefault(optional TestJSImplInterface? arg = null); |
michael@0 | 154 | |
michael@0 | 155 | // Non-wrapper-cache interface types |
michael@0 | 156 | [NewObject] |
michael@0 | 157 | TestNonWrapperCacheInterface receiveNonWrapperCacheInterface(); |
michael@0 | 158 | [NewObject] |
michael@0 | 159 | TestNonWrapperCacheInterface? receiveNullableNonWrapperCacheInterface(); |
michael@0 | 160 | |
michael@0 | 161 | [NewObject] |
michael@0 | 162 | sequence<TestNonWrapperCacheInterface> receiveNonWrapperCacheInterfaceSequence(); |
michael@0 | 163 | [NewObject] |
michael@0 | 164 | sequence<TestNonWrapperCacheInterface?> receiveNullableNonWrapperCacheInterfaceSequence(); |
michael@0 | 165 | [NewObject] |
michael@0 | 166 | sequence<TestNonWrapperCacheInterface>? receiveNonWrapperCacheInterfaceNullableSequence(); |
michael@0 | 167 | [NewObject] |
michael@0 | 168 | sequence<TestNonWrapperCacheInterface?>? receiveNullableNonWrapperCacheInterfaceNullableSequence(); |
michael@0 | 169 | |
michael@0 | 170 | // Non-castable interface types |
michael@0 | 171 | IndirectlyImplementedInterface receiveOther(); |
michael@0 | 172 | IndirectlyImplementedInterface? receiveNullableOther(); |
michael@0 | 173 | // Callback interface ignores 'resultNotAddRefed'. See bug 843272. |
michael@0 | 174 | //IndirectlyImplementedInterface receiveWeakOther(); |
michael@0 | 175 | //IndirectlyImplementedInterface? receiveWeakNullableOther(); |
michael@0 | 176 | |
michael@0 | 177 | void passOther(IndirectlyImplementedInterface arg); |
michael@0 | 178 | void passNullableOther(IndirectlyImplementedInterface? arg); |
michael@0 | 179 | attribute IndirectlyImplementedInterface nonNullOther; |
michael@0 | 180 | attribute IndirectlyImplementedInterface? nullableOther; |
michael@0 | 181 | // Optional arguments |
michael@0 | 182 | void passOptionalOther(optional IndirectlyImplementedInterface? arg); |
michael@0 | 183 | void passOptionalNonNullOther(optional IndirectlyImplementedInterface arg); |
michael@0 | 184 | void passOptionalOtherWithDefault(optional IndirectlyImplementedInterface? arg = null); |
michael@0 | 185 | |
michael@0 | 186 | // External interface types |
michael@0 | 187 | TestExternalInterface receiveExternal(); |
michael@0 | 188 | TestExternalInterface? receiveNullableExternal(); |
michael@0 | 189 | // Callback interface ignores 'resultNotAddRefed'. See bug 843272. |
michael@0 | 190 | //TestExternalInterface receiveWeakExternal(); |
michael@0 | 191 | //TestExternalInterface? receiveWeakNullableExternal(); |
michael@0 | 192 | void passExternal(TestExternalInterface arg); |
michael@0 | 193 | void passNullableExternal(TestExternalInterface? arg); |
michael@0 | 194 | attribute TestExternalInterface nonNullExternal; |
michael@0 | 195 | attribute TestExternalInterface? nullableExternal; |
michael@0 | 196 | // Optional arguments |
michael@0 | 197 | void passOptionalExternal(optional TestExternalInterface? arg); |
michael@0 | 198 | void passOptionalNonNullExternal(optional TestExternalInterface arg); |
michael@0 | 199 | void passOptionalExternalWithDefault(optional TestExternalInterface? arg = null); |
michael@0 | 200 | |
michael@0 | 201 | // Callback interface types |
michael@0 | 202 | TestCallbackInterface receiveCallbackInterface(); |
michael@0 | 203 | TestCallbackInterface? receiveNullableCallbackInterface(); |
michael@0 | 204 | // Callback interface ignores 'resultNotAddRefed'. See bug 843272. |
michael@0 | 205 | //TestCallbackInterface receiveWeakCallbackInterface(); |
michael@0 | 206 | //TestCallbackInterface? receiveWeakNullableCallbackInterface(); |
michael@0 | 207 | void passCallbackInterface(TestCallbackInterface arg); |
michael@0 | 208 | void passNullableCallbackInterface(TestCallbackInterface? arg); |
michael@0 | 209 | attribute TestCallbackInterface nonNullCallbackInterface; |
michael@0 | 210 | attribute TestCallbackInterface? nullableCallbackInterface; |
michael@0 | 211 | // Optional arguments |
michael@0 | 212 | void passOptionalCallbackInterface(optional TestCallbackInterface? arg); |
michael@0 | 213 | void passOptionalNonNullCallbackInterface(optional TestCallbackInterface arg); |
michael@0 | 214 | void passOptionalCallbackInterfaceWithDefault(optional TestCallbackInterface? arg = null); |
michael@0 | 215 | |
michael@0 | 216 | // Miscellaneous interface tests |
michael@0 | 217 | IndirectlyImplementedInterface receiveConsequentialInterface(); |
michael@0 | 218 | void passConsequentialInterface(IndirectlyImplementedInterface arg); |
michael@0 | 219 | |
michael@0 | 220 | // Sequence types |
michael@0 | 221 | [Cached, Pure] |
michael@0 | 222 | readonly attribute sequence<long> readonlySequence; |
michael@0 | 223 | [Cached, Pure] |
michael@0 | 224 | readonly attribute sequence<Dict> readonlySequenceOfDictionaries; |
michael@0 | 225 | [Cached, Pure] |
michael@0 | 226 | readonly attribute sequence<Dict>? readonlyNullableSequenceOfDictionaries; |
michael@0 | 227 | [Cached, Pure, Frozen] |
michael@0 | 228 | readonly attribute sequence<long> readonlyFrozenSequence; |
michael@0 | 229 | [Cached, Pure, Frozen] |
michael@0 | 230 | readonly attribute sequence<long>? readonlyFrozenNullableSequence; |
michael@0 | 231 | sequence<long> receiveSequence(); |
michael@0 | 232 | sequence<long>? receiveNullableSequence(); |
michael@0 | 233 | sequence<long?> receiveSequenceOfNullableInts(); |
michael@0 | 234 | sequence<long?>? receiveNullableSequenceOfNullableInts(); |
michael@0 | 235 | void passSequence(sequence<long> arg); |
michael@0 | 236 | void passNullableSequence(sequence<long>? arg); |
michael@0 | 237 | void passSequenceOfNullableInts(sequence<long?> arg); |
michael@0 | 238 | void passOptionalSequenceOfNullableInts(optional sequence<long?> arg); |
michael@0 | 239 | void passOptionalNullableSequenceOfNullableInts(optional sequence<long?>? arg); |
michael@0 | 240 | sequence<TestJSImplInterface> receiveCastableObjectSequence(); |
michael@0 | 241 | sequence<TestCallbackInterface> receiveCallbackObjectSequence(); |
michael@0 | 242 | sequence<TestJSImplInterface?> receiveNullableCastableObjectSequence(); |
michael@0 | 243 | sequence<TestCallbackInterface?> receiveNullableCallbackObjectSequence(); |
michael@0 | 244 | sequence<TestJSImplInterface>? receiveCastableObjectNullableSequence(); |
michael@0 | 245 | sequence<TestJSImplInterface?>? receiveNullableCastableObjectNullableSequence(); |
michael@0 | 246 | sequence<TestJSImplInterface> receiveWeakCastableObjectSequence(); |
michael@0 | 247 | sequence<TestJSImplInterface?> receiveWeakNullableCastableObjectSequence(); |
michael@0 | 248 | sequence<TestJSImplInterface>? receiveWeakCastableObjectNullableSequence(); |
michael@0 | 249 | sequence<TestJSImplInterface?>? receiveWeakNullableCastableObjectNullableSequence(); |
michael@0 | 250 | void passCastableObjectSequence(sequence<TestJSImplInterface> arg); |
michael@0 | 251 | void passNullableCastableObjectSequence(sequence<TestJSImplInterface?> arg); |
michael@0 | 252 | void passCastableObjectNullableSequence(sequence<TestJSImplInterface>? arg); |
michael@0 | 253 | void passNullableCastableObjectNullableSequence(sequence<TestJSImplInterface?>? arg); |
michael@0 | 254 | void passOptionalSequence(optional sequence<long> arg); |
michael@0 | 255 | void passOptionalNullableSequence(optional sequence<long>? arg); |
michael@0 | 256 | void passOptionalNullableSequenceWithDefaultValue(optional sequence<long>? arg = null); |
michael@0 | 257 | void passOptionalObjectSequence(optional sequence<TestJSImplInterface> arg); |
michael@0 | 258 | void passExternalInterfaceSequence(sequence<TestExternalInterface> arg); |
michael@0 | 259 | void passNullableExternalInterfaceSequence(sequence<TestExternalInterface?> arg); |
michael@0 | 260 | |
michael@0 | 261 | sequence<DOMString> receiveStringSequence(); |
michael@0 | 262 | sequence<ByteString> receiveByteStringSequence(); |
michael@0 | 263 | // Callback interface problem. See bug 843261. |
michael@0 | 264 | //void passStringSequence(sequence<DOMString> arg); |
michael@0 | 265 | sequence<any> receiveAnySequence(); |
michael@0 | 266 | sequence<any>? receiveNullableAnySequence(); |
michael@0 | 267 | //XXXbz No support for sequence of sequence return values yet. |
michael@0 | 268 | //sequence<sequence<any>> receiveAnySequenceSequence(); |
michael@0 | 269 | |
michael@0 | 270 | sequence<object> receiveObjectSequence(); |
michael@0 | 271 | sequence<object?> receiveNullableObjectSequence(); |
michael@0 | 272 | |
michael@0 | 273 | void passSequenceOfSequences(sequence<sequence<long>> arg); |
michael@0 | 274 | //XXXbz No support for sequence of sequence return values yet. |
michael@0 | 275 | //sequence<sequence<long>> receiveSequenceOfSequences(); |
michael@0 | 276 | |
michael@0 | 277 | // MozMap types |
michael@0 | 278 | void passMozMap(MozMap<long> arg); |
michael@0 | 279 | void passNullableMozMap(MozMap<long>? arg); |
michael@0 | 280 | void passMozMapOfNullableInts(MozMap<long?> arg); |
michael@0 | 281 | void passOptionalMozMapOfNullableInts(optional MozMap<long?> arg); |
michael@0 | 282 | void passOptionalNullableMozMapOfNullableInts(optional MozMap<long?>? arg); |
michael@0 | 283 | void passCastableObjectMozMap(MozMap<TestJSImplInterface> arg); |
michael@0 | 284 | void passNullableCastableObjectMozMap(MozMap<TestJSImplInterface?> arg); |
michael@0 | 285 | void passCastableObjectNullableMozMap(MozMap<TestJSImplInterface>? arg); |
michael@0 | 286 | void passNullableCastableObjectNullableMozMap(MozMap<TestJSImplInterface?>? arg); |
michael@0 | 287 | void passOptionalMozMap(optional MozMap<long> arg); |
michael@0 | 288 | void passOptionalNullableMozMap(optional MozMap<long>? arg); |
michael@0 | 289 | void passOptionalNullableMozMapWithDefaultValue(optional MozMap<long>? arg = null); |
michael@0 | 290 | void passOptionalObjectMozMap(optional MozMap<TestJSImplInterface> arg); |
michael@0 | 291 | void passExternalInterfaceMozMap(MozMap<TestExternalInterface> arg); |
michael@0 | 292 | void passNullableExternalInterfaceMozMap(MozMap<TestExternalInterface?> arg); |
michael@0 | 293 | void passStringMozMap(MozMap<DOMString> arg); |
michael@0 | 294 | void passByteStringMozMap(MozMap<ByteString> arg); |
michael@0 | 295 | void passMozMapOfMozMaps(MozMap<MozMap<long>> arg); |
michael@0 | 296 | MozMap<long> receiveMozMap(); |
michael@0 | 297 | MozMap<long>? receiveNullableMozMap(); |
michael@0 | 298 | MozMap<long?> receiveMozMapOfNullableInts(); |
michael@0 | 299 | MozMap<long?>? receiveNullableMozMapOfNullableInts(); |
michael@0 | 300 | //XXXbz No support for MozMap of MozMaps return values yet. |
michael@0 | 301 | //MozMap<MozMap<long>> receiveMozMapOfMozMaps(); |
michael@0 | 302 | MozMap<any> receiveAnyMozMap(); |
michael@0 | 303 | |
michael@0 | 304 | // ArrayBuffer is handled differently in callback interfaces and the example generator. |
michael@0 | 305 | // Need to figure out what should be done there. Seems like other typed array stuff is |
michael@0 | 306 | // similarly not working in the JS implemented generator. Probably some other issues |
michael@0 | 307 | // here as well. |
michael@0 | 308 | // Typed array types |
michael@0 | 309 | //void passArrayBuffer(ArrayBuffer arg); |
michael@0 | 310 | //void passNullableArrayBuffer(ArrayBuffer? arg); |
michael@0 | 311 | //void passOptionalArrayBuffer(optional ArrayBuffer arg); |
michael@0 | 312 | //void passOptionalNullableArrayBuffer(optional ArrayBuffer? arg); |
michael@0 | 313 | //void passOptionalNullableArrayBufferWithDefaultValue(optional ArrayBuffer? arg= null); |
michael@0 | 314 | //void passArrayBufferView(ArrayBufferView arg); |
michael@0 | 315 | //void passInt8Array(Int8Array arg); |
michael@0 | 316 | //void passInt16Array(Int16Array arg); |
michael@0 | 317 | //void passInt32Array(Int32Array arg); |
michael@0 | 318 | //void passUint8Array(Uint8Array arg); |
michael@0 | 319 | //void passUint16Array(Uint16Array arg); |
michael@0 | 320 | //void passUint32Array(Uint32Array arg); |
michael@0 | 321 | //void passUint8ClampedArray(Uint8ClampedArray arg); |
michael@0 | 322 | //void passFloat32Array(Float32Array arg); |
michael@0 | 323 | //void passFloat64Array(Float64Array arg); |
michael@0 | 324 | //void passSequenceOfArrayBuffers(sequence<ArrayBuffer> arg); |
michael@0 | 325 | //void passSequenceOfNullableArrayBuffers(sequence<ArrayBuffer?> arg); |
michael@0 | 326 | //void passMozMapOfArrayBuffers(MozMap<ArrayBuffer> arg); |
michael@0 | 327 | //void passMozMapOfNullableArrayBuffers(MozMap<ArrayBuffer?> arg); |
michael@0 | 328 | //void passVariadicTypedArray(Float32Array... arg); |
michael@0 | 329 | //void passVariadicNullableTypedArray(Float32Array?... arg); |
michael@0 | 330 | //Uint8Array receiveUint8Array(); |
michael@0 | 331 | |
michael@0 | 332 | // DOMString types |
michael@0 | 333 | void passString(DOMString arg); |
michael@0 | 334 | void passNullableString(DOMString? arg); |
michael@0 | 335 | void passOptionalString(optional DOMString arg); |
michael@0 | 336 | void passOptionalStringWithDefaultValue(optional DOMString arg = "abc"); |
michael@0 | 337 | void passOptionalNullableString(optional DOMString? arg); |
michael@0 | 338 | void passOptionalNullableStringWithDefaultValue(optional DOMString? arg = null); |
michael@0 | 339 | void passVariadicString(DOMString... arg); |
michael@0 | 340 | |
michael@0 | 341 | // ByteString types |
michael@0 | 342 | void passByteString(ByteString arg); |
michael@0 | 343 | void passNullableByteString(ByteString? arg); |
michael@0 | 344 | void passOptionalByteString(optional ByteString arg); |
michael@0 | 345 | void passOptionalNullableByteString(optional ByteString? arg); |
michael@0 | 346 | void passVariadicByteString(ByteString... arg); |
michael@0 | 347 | |
michael@0 | 348 | // Enumerated types |
michael@0 | 349 | void passEnum(MyTestEnum arg); |
michael@0 | 350 | void passNullableEnum(MyTestEnum? arg); |
michael@0 | 351 | void passOptionalEnum(optional MyTestEnum arg); |
michael@0 | 352 | void passEnumWithDefault(optional MyTestEnum arg = "a"); |
michael@0 | 353 | void passOptionalNullableEnum(optional MyTestEnum? arg); |
michael@0 | 354 | void passOptionalNullableEnumWithDefaultValue(optional MyTestEnum? arg = null); |
michael@0 | 355 | void passOptionalNullableEnumWithDefaultValue2(optional MyTestEnum? arg = "a"); |
michael@0 | 356 | MyTestEnum receiveEnum(); |
michael@0 | 357 | MyTestEnum? receiveNullableEnum(); |
michael@0 | 358 | attribute MyTestEnum enumAttribute; |
michael@0 | 359 | readonly attribute MyTestEnum readonlyEnumAttribute; |
michael@0 | 360 | |
michael@0 | 361 | // Callback types |
michael@0 | 362 | void passCallback(MyTestCallback arg); |
michael@0 | 363 | void passNullableCallback(MyTestCallback? arg); |
michael@0 | 364 | void passOptionalCallback(optional MyTestCallback arg); |
michael@0 | 365 | void passOptionalNullableCallback(optional MyTestCallback? arg); |
michael@0 | 366 | void passOptionalNullableCallbackWithDefaultValue(optional MyTestCallback? arg = null); |
michael@0 | 367 | MyTestCallback receiveCallback(); |
michael@0 | 368 | MyTestCallback? receiveNullableCallback(); |
michael@0 | 369 | // Hmm. These two don't work, I think because I need a locally modified version of TestTreatAsNullCallback. |
michael@0 | 370 | //void passNullableTreatAsNullCallback(TestTreatAsNullCallback? arg); |
michael@0 | 371 | //void passOptionalNullableTreatAsNullCallback(optional TestTreatAsNullCallback? arg); |
michael@0 | 372 | void passOptionalNullableTreatAsNullCallbackWithDefaultValue(optional TestTreatAsNullCallback? arg = null); |
michael@0 | 373 | |
michael@0 | 374 | // Any types |
michael@0 | 375 | void passAny(any arg); |
michael@0 | 376 | void passVariadicAny(any... arg); |
michael@0 | 377 | void passOptionalAny(optional any arg); |
michael@0 | 378 | void passAnyDefaultNull(optional any arg = null); |
michael@0 | 379 | void passSequenceOfAny(sequence<any> arg); |
michael@0 | 380 | void passNullableSequenceOfAny(sequence<any>? arg); |
michael@0 | 381 | void passOptionalSequenceOfAny(optional sequence<any> arg); |
michael@0 | 382 | void passOptionalNullableSequenceOfAny(optional sequence<any>? arg); |
michael@0 | 383 | void passOptionalSequenceOfAnyWithDefaultValue(optional sequence<any>? arg = null); |
michael@0 | 384 | void passSequenceOfSequenceOfAny(sequence<sequence<any>> arg); |
michael@0 | 385 | void passSequenceOfNullableSequenceOfAny(sequence<sequence<any>?> arg); |
michael@0 | 386 | void passNullableSequenceOfNullableSequenceOfAny(sequence<sequence<any>?>? arg); |
michael@0 | 387 | void passOptionalNullableSequenceOfNullableSequenceOfAny(optional sequence<sequence<any>?>? arg); |
michael@0 | 388 | void passMozMapOfAny(MozMap<any> arg); |
michael@0 | 389 | void passNullableMozMapOfAny(MozMap<any>? arg); |
michael@0 | 390 | void passOptionalMozMapOfAny(optional MozMap<any> arg); |
michael@0 | 391 | void passOptionalNullableMozMapOfAny(optional MozMap<any>? arg); |
michael@0 | 392 | void passOptionalMozMapOfAnyWithDefaultValue(optional MozMap<any>? arg = null); |
michael@0 | 393 | void passMozMapOfMozMapOfAny(MozMap<MozMap<any>> arg); |
michael@0 | 394 | void passMozMapOfNullableMozMapOfAny(MozMap<MozMap<any>?> arg); |
michael@0 | 395 | void passNullableMozMapOfNullableMozMapOfAny(MozMap<MozMap<any>?>? arg); |
michael@0 | 396 | void passOptionalNullableMozMapOfNullableMozMapOfAny(optional MozMap<MozMap<any>?>? arg); |
michael@0 | 397 | void passOptionalNullableMozMapOfNullableSequenceOfAny(optional MozMap<sequence<any>?>? arg); |
michael@0 | 398 | void passOptionalNullableSequenceOfNullableMozMapOfAny(optional sequence<MozMap<any>?>? arg); |
michael@0 | 399 | any receiveAny(); |
michael@0 | 400 | |
michael@0 | 401 | // object types |
michael@0 | 402 | void passObject(object arg); |
michael@0 | 403 | void passVariadicObject(object... arg); |
michael@0 | 404 | void passNullableObject(object? arg); |
michael@0 | 405 | void passVariadicNullableObject(object... arg); |
michael@0 | 406 | void passOptionalObject(optional object arg); |
michael@0 | 407 | void passOptionalNullableObject(optional object? arg); |
michael@0 | 408 | void passOptionalNullableObjectWithDefaultValue(optional object? arg = null); |
michael@0 | 409 | void passSequenceOfObject(sequence<object> arg); |
michael@0 | 410 | void passSequenceOfNullableObject(sequence<object?> arg); |
michael@0 | 411 | void passNullableSequenceOfObject(sequence<object>? arg); |
michael@0 | 412 | void passOptionalNullableSequenceOfNullableSequenceOfObject(optional sequence<sequence<object>?>? arg); |
michael@0 | 413 | void passOptionalNullableSequenceOfNullableSequenceOfNullableObject(optional sequence<sequence<object?>?>? arg); |
michael@0 | 414 | void passMozMapOfObject(MozMap<object> arg); |
michael@0 | 415 | object receiveObject(); |
michael@0 | 416 | object? receiveNullableObject(); |
michael@0 | 417 | |
michael@0 | 418 | // Union types |
michael@0 | 419 | void passUnion((object or long) arg); |
michael@0 | 420 | // Some union tests are debug-only to avoid creating all those |
michael@0 | 421 | // unused union types in opt builds. |
michael@0 | 422 | #ifdef DEBUG |
michael@0 | 423 | void passUnion2((long or boolean) arg); |
michael@0 | 424 | void passUnion3((object or long or boolean) arg); |
michael@0 | 425 | void passUnion4((Node or long or boolean) arg); |
michael@0 | 426 | void passUnion5((object or boolean) arg); |
michael@0 | 427 | void passUnion6((object or DOMString) arg); |
michael@0 | 428 | void passUnion7((object or DOMString or long) arg); |
michael@0 | 429 | void passUnion8((object or DOMString or boolean) arg); |
michael@0 | 430 | void passUnion9((object or DOMString or long or boolean) arg); |
michael@0 | 431 | void passUnion10(optional (EventInit or long) arg); |
michael@0 | 432 | void passUnion11(optional (CustomEventInit or long) arg); |
michael@0 | 433 | void passUnion12(optional (EventInit or long) arg = 5); |
michael@0 | 434 | void passUnion13(optional (object or long?) arg = null); |
michael@0 | 435 | void passUnion14(optional (object or long?) arg = 5); |
michael@0 | 436 | void passUnionWithCallback((EventHandler or long) arg); |
michael@0 | 437 | #endif |
michael@0 | 438 | void passUnionWithNullable((object? or long) arg); |
michael@0 | 439 | void passNullableUnion((object or long)? arg); |
michael@0 | 440 | void passOptionalUnion(optional (object or long) arg); |
michael@0 | 441 | void passOptionalNullableUnion(optional (object or long)? arg); |
michael@0 | 442 | void passOptionalNullableUnionWithDefaultValue(optional (object or long)? arg = null); |
michael@0 | 443 | //void passUnionWithInterfaces((TestJSImplInterface or TestExternalInterface) arg); |
michael@0 | 444 | //void passUnionWithInterfacesAndNullable((TestJSImplInterface? or TestExternalInterface) arg); |
michael@0 | 445 | //void passUnionWithSequence((sequence<object> or long) arg); |
michael@0 | 446 | void passUnionWithArrayBuffer((ArrayBuffer or long) arg); |
michael@0 | 447 | void passUnionWithString((DOMString or object) arg); |
michael@0 | 448 | //void passUnionWithEnum((MyTestEnum or object) arg); |
michael@0 | 449 | // Trying to use a callback in a union won't include the test |
michael@0 | 450 | // headers, unfortunately, so won't compile. |
michael@0 | 451 | // void passUnionWithCallback((MyTestCallback or long) arg); |
michael@0 | 452 | void passUnionWithObject((object or long) arg); |
michael@0 | 453 | //void passUnionWithDict((Dict or long) arg); |
michael@0 | 454 | |
michael@0 | 455 | void passUnionWithDefaultValue1(optional (double or DOMString) arg = ""); |
michael@0 | 456 | void passUnionWithDefaultValue2(optional (double or DOMString) arg = 1); |
michael@0 | 457 | void passUnionWithDefaultValue3(optional (double or DOMString) arg = 1.5); |
michael@0 | 458 | void passUnionWithDefaultValue4(optional (float or DOMString) arg = ""); |
michael@0 | 459 | void passUnionWithDefaultValue5(optional (float or DOMString) arg = 1); |
michael@0 | 460 | void passUnionWithDefaultValue6(optional (float or DOMString) arg = 1.5); |
michael@0 | 461 | void passUnionWithDefaultValue7(optional (unrestricted double or DOMString) arg = ""); |
michael@0 | 462 | void passUnionWithDefaultValue8(optional (unrestricted double or DOMString) arg = 1); |
michael@0 | 463 | void passUnionWithDefaultValue9(optional (unrestricted double or DOMString) arg = 1.5); |
michael@0 | 464 | void passUnionWithDefaultValue10(optional (unrestricted double or DOMString) arg = Infinity); |
michael@0 | 465 | void passUnionWithDefaultValue11(optional (unrestricted float or DOMString) arg = ""); |
michael@0 | 466 | void passUnionWithDefaultValue12(optional (unrestricted float or DOMString) arg = 1); |
michael@0 | 467 | void passUnionWithDefaultValue13(optional (unrestricted float or DOMString) arg = Infinity); |
michael@0 | 468 | |
michael@0 | 469 | void passNullableUnionWithDefaultValue1(optional (double or DOMString)? arg = ""); |
michael@0 | 470 | void passNullableUnionWithDefaultValue2(optional (double or DOMString)? arg = 1); |
michael@0 | 471 | void passNullableUnionWithDefaultValue3(optional (double or DOMString)? arg = null); |
michael@0 | 472 | void passNullableUnionWithDefaultValue4(optional (float or DOMString)? arg = ""); |
michael@0 | 473 | void passNullableUnionWithDefaultValue5(optional (float or DOMString)? arg = 1); |
michael@0 | 474 | void passNullableUnionWithDefaultValue6(optional (float or DOMString)? arg = null); |
michael@0 | 475 | void passNullableUnionWithDefaultValue7(optional (unrestricted double or DOMString)? arg = ""); |
michael@0 | 476 | void passNullableUnionWithDefaultValue8(optional (unrestricted double or DOMString)? arg = 1); |
michael@0 | 477 | void passNullableUnionWithDefaultValue9(optional (unrestricted double or DOMString)? arg = null); |
michael@0 | 478 | void passNullableUnionWithDefaultValue10(optional (unrestricted float or DOMString)? arg = ""); |
michael@0 | 479 | void passNullableUnionWithDefaultValue11(optional (unrestricted float or DOMString)? arg = 1); |
michael@0 | 480 | void passNullableUnionWithDefaultValue12(optional (unrestricted float or DOMString)? arg = null); |
michael@0 | 481 | |
michael@0 | 482 | void passSequenceOfUnions(sequence<(CanvasPattern or CanvasGradient)> arg); |
michael@0 | 483 | void passSequenceOfUnions2(sequence<(object or long)> arg); |
michael@0 | 484 | void passVariadicUnion((CanvasPattern or CanvasGradient)... arg); |
michael@0 | 485 | |
michael@0 | 486 | void passSequenceOfNullableUnions(sequence<(CanvasPattern or CanvasGradient)?> arg); |
michael@0 | 487 | void passVariadicNullableUnion((CanvasPattern or CanvasGradient)?... arg); |
michael@0 | 488 | void passMozMapOfUnions(MozMap<(CanvasPattern or CanvasGradient)> arg); |
michael@0 | 489 | // XXXbz no move constructor on some unions |
michael@0 | 490 | // void passMozMapOfUnions2(MozMap<(object or long)> arg); |
michael@0 | 491 | |
michael@0 | 492 | //(CanvasPattern or CanvasGradient) receiveUnion(); |
michael@0 | 493 | //(object or long) receiveUnion2(); |
michael@0 | 494 | //(CanvasPattern? or CanvasGradient) receiveUnionContainingNull(); |
michael@0 | 495 | //(CanvasPattern or CanvasGradient)? receiveNullableUnion(); |
michael@0 | 496 | //(object or long)? receiveNullableUnion2(); |
michael@0 | 497 | |
michael@0 | 498 | //attribute (CanvasPattern or CanvasGradient) writableUnion; |
michael@0 | 499 | //attribute (CanvasPattern? or CanvasGradient) writableUnionContainingNull; |
michael@0 | 500 | //attribute (CanvasPattern or CanvasGradient)? writableNullableUnion; |
michael@0 | 501 | |
michael@0 | 502 | // Date types |
michael@0 | 503 | void passDate(Date arg); |
michael@0 | 504 | void passNullableDate(Date? arg); |
michael@0 | 505 | void passOptionalDate(optional Date arg); |
michael@0 | 506 | void passOptionalNullableDate(optional Date? arg); |
michael@0 | 507 | void passOptionalNullableDateWithDefaultValue(optional Date? arg = null); |
michael@0 | 508 | void passDateSequence(sequence<Date> arg); |
michael@0 | 509 | void passNullableDateSequence(sequence<Date?> arg); |
michael@0 | 510 | void passDateMozMap(MozMap<Date> arg); |
michael@0 | 511 | Date receiveDate(); |
michael@0 | 512 | Date? receiveNullableDate(); |
michael@0 | 513 | |
michael@0 | 514 | // binaryNames tests |
michael@0 | 515 | void methodRenamedFrom(); |
michael@0 | 516 | void methodRenamedFrom(byte argument); |
michael@0 | 517 | readonly attribute byte attributeGetterRenamedFrom; |
michael@0 | 518 | attribute byte attributeRenamedFrom; |
michael@0 | 519 | |
michael@0 | 520 | void passDictionary(optional Dict x); |
michael@0 | 521 | [Cached, Pure] |
michael@0 | 522 | readonly attribute Dict readonlyDictionary; |
michael@0 | 523 | [Cached, Pure] |
michael@0 | 524 | readonly attribute Dict? readonlyNullableDictionary; |
michael@0 | 525 | [Cached, Pure] |
michael@0 | 526 | attribute Dict writableDictionary; |
michael@0 | 527 | [Cached, Pure, Frozen] |
michael@0 | 528 | readonly attribute Dict readonlyFrozenDictionary; |
michael@0 | 529 | [Cached, Pure, Frozen] |
michael@0 | 530 | readonly attribute Dict? readonlyFrozenNullableDictionary; |
michael@0 | 531 | [Cached, Pure, Frozen] |
michael@0 | 532 | attribute Dict writableFrozenDictionary; |
michael@0 | 533 | Dict receiveDictionary(); |
michael@0 | 534 | Dict? receiveNullableDictionary(); |
michael@0 | 535 | void passOtherDictionary(optional GrandparentDict x); |
michael@0 | 536 | void passSequenceOfDictionaries(sequence<Dict> x); |
michael@0 | 537 | void passMozMapOfDictionaries(MozMap<GrandparentDict> x); |
michael@0 | 538 | // No support for nullable dictionaries inside a sequence (nor should there be) |
michael@0 | 539 | // void passSequenceOfNullableDictionaries(sequence<Dict?> x); |
michael@0 | 540 | void passDictionaryOrLong(optional Dict x); |
michael@0 | 541 | void passDictionaryOrLong(long x); |
michael@0 | 542 | |
michael@0 | 543 | void passDictContainingDict(optional DictContainingDict arg); |
michael@0 | 544 | void passDictContainingSequence(optional DictContainingSequence arg); |
michael@0 | 545 | DictContainingSequence receiveDictContainingSequence(); |
michael@0 | 546 | |
michael@0 | 547 | // EnforceRange/Clamp tests |
michael@0 | 548 | void dontEnforceRangeOrClamp(byte arg); |
michael@0 | 549 | void doEnforceRange([EnforceRange] byte arg); |
michael@0 | 550 | void doClamp([Clamp] byte arg); |
michael@0 | 551 | [EnforceRange] attribute byte enforcedByte; |
michael@0 | 552 | [Clamp] attribute byte clampedByte; |
michael@0 | 553 | |
michael@0 | 554 | // Typedefs |
michael@0 | 555 | const myLong myLongConstant = 5; |
michael@0 | 556 | void exerciseTypedefInterfaces1(AnotherNameForTestJSImplInterface arg); |
michael@0 | 557 | AnotherNameForTestJSImplInterface exerciseTypedefInterfaces2(NullableTestJSImplInterface arg); |
michael@0 | 558 | void exerciseTypedefInterfaces3(YetAnotherNameForTestJSImplInterface arg); |
michael@0 | 559 | |
michael@0 | 560 | // Static methods and attributes |
michael@0 | 561 | // FIXME: Bug 863952 Static things are not supported yet |
michael@0 | 562 | /* |
michael@0 | 563 | static attribute boolean staticAttribute; |
michael@0 | 564 | static void staticMethod(boolean arg); |
michael@0 | 565 | static void staticMethodWithContext(any arg); |
michael@0 | 566 | */ |
michael@0 | 567 | |
michael@0 | 568 | // Overload resolution tests |
michael@0 | 569 | //void overload1(DOMString... strs); |
michael@0 | 570 | boolean overload1(TestJSImplInterface arg); |
michael@0 | 571 | TestJSImplInterface overload1(DOMString strs, TestJSImplInterface arg); |
michael@0 | 572 | void overload2(TestJSImplInterface arg); |
michael@0 | 573 | void overload2(optional Dict arg); |
michael@0 | 574 | void overload2(boolean arg); |
michael@0 | 575 | void overload2(DOMString arg); |
michael@0 | 576 | void overload2(Date arg); |
michael@0 | 577 | void overload3(TestJSImplInterface arg); |
michael@0 | 578 | void overload3(MyTestCallback arg); |
michael@0 | 579 | void overload3(boolean arg); |
michael@0 | 580 | void overload4(TestJSImplInterface arg); |
michael@0 | 581 | void overload4(TestCallbackInterface arg); |
michael@0 | 582 | void overload4(DOMString arg); |
michael@0 | 583 | void overload5(long arg); |
michael@0 | 584 | void overload5(MyTestEnum arg); |
michael@0 | 585 | void overload6(long arg); |
michael@0 | 586 | void overload6(boolean arg); |
michael@0 | 587 | void overload7(long arg); |
michael@0 | 588 | void overload7(boolean arg); |
michael@0 | 589 | void overload7(ByteString arg); |
michael@0 | 590 | void overload8(long arg); |
michael@0 | 591 | void overload8(TestJSImplInterface arg); |
michael@0 | 592 | void overload9(long? arg); |
michael@0 | 593 | void overload9(DOMString arg); |
michael@0 | 594 | void overload10(long? arg); |
michael@0 | 595 | void overload10(object arg); |
michael@0 | 596 | void overload11(long arg); |
michael@0 | 597 | void overload11(DOMString? arg); |
michael@0 | 598 | void overload12(long arg); |
michael@0 | 599 | void overload12(boolean? arg); |
michael@0 | 600 | void overload13(long? arg); |
michael@0 | 601 | void overload13(boolean arg); |
michael@0 | 602 | void overload14(optional long arg); |
michael@0 | 603 | void overload14(TestInterface arg); |
michael@0 | 604 | void overload15(long arg); |
michael@0 | 605 | void overload15(optional TestInterface arg); |
michael@0 | 606 | void overload16(long arg); |
michael@0 | 607 | void overload16(optional TestInterface? arg); |
michael@0 | 608 | |
michael@0 | 609 | // Variadic handling |
michael@0 | 610 | void passVariadicThirdArg(DOMString arg1, long arg2, TestJSImplInterface... arg3); |
michael@0 | 611 | |
michael@0 | 612 | // Conditionally exposed methods/attributes |
michael@0 | 613 | [Pref="abc.def"] |
michael@0 | 614 | readonly attribute boolean prefable1; |
michael@0 | 615 | [Pref="abc.def"] |
michael@0 | 616 | readonly attribute boolean prefable2; |
michael@0 | 617 | [Pref="ghi.jkl"] |
michael@0 | 618 | readonly attribute boolean prefable3; |
michael@0 | 619 | [Pref="ghi.jkl"] |
michael@0 | 620 | readonly attribute boolean prefable4; |
michael@0 | 621 | [Pref="abc.def"] |
michael@0 | 622 | readonly attribute boolean prefable5; |
michael@0 | 623 | [Pref="abc.def", Func="nsGenericHTMLElement::TouchEventsEnabled"] |
michael@0 | 624 | readonly attribute boolean prefable6; |
michael@0 | 625 | [Pref="abc.def", Func="nsGenericHTMLElement::TouchEventsEnabled"] |
michael@0 | 626 | readonly attribute boolean prefable7; |
michael@0 | 627 | [Pref="ghi.jkl", Func="nsGenericHTMLElement::TouchEventsEnabled"] |
michael@0 | 628 | readonly attribute boolean prefable8; |
michael@0 | 629 | [Pref="abc.def", Func="nsGenericHTMLElement::TouchEventsEnabled"] |
michael@0 | 630 | readonly attribute boolean prefable9; |
michael@0 | 631 | [Pref="abc.def"] |
michael@0 | 632 | void prefable10(); |
michael@0 | 633 | [Pref="abc.def", Func="nsGenericHTMLElement::TouchEventsEnabled"] |
michael@0 | 634 | void prefable11(); |
michael@0 | 635 | [Pref="abc.def", Func="TestFuncControlledMember"] |
michael@0 | 636 | readonly attribute boolean prefable12; |
michael@0 | 637 | [Pref="abc.def", Func="nsGenericHTMLElement::TouchEventsEnabled"] |
michael@0 | 638 | void prefable13(); |
michael@0 | 639 | [Pref="abc.def", Func="TestFuncControlledMember"] |
michael@0 | 640 | readonly attribute boolean prefable14; |
michael@0 | 641 | [Func="TestFuncControlledMember"] |
michael@0 | 642 | readonly attribute boolean prefable15; |
michael@0 | 643 | [Func="TestFuncControlledMember"] |
michael@0 | 644 | readonly attribute boolean prefable16; |
michael@0 | 645 | [Pref="abc.def", Func="TestFuncControlledMember"] |
michael@0 | 646 | void prefable17(); |
michael@0 | 647 | [Func="TestFuncControlledMember"] |
michael@0 | 648 | void prefable18(); |
michael@0 | 649 | [Func="TestFuncControlledMember"] |
michael@0 | 650 | void prefable19(); |
michael@0 | 651 | [Pref="abc.def", Func="TestFuncControlledMember", ChromeOnly] |
michael@0 | 652 | void prefable20(); |
michael@0 | 653 | [Func="TestFuncControlledMember", AvailableIn=CertifiedApps] |
michael@0 | 654 | void prefable21(); |
michael@0 | 655 | [Func="TestFuncControlledMember", AvailableIn=CertifiedApps] |
michael@0 | 656 | void prefable22(); |
michael@0 | 657 | [Pref="abc.def", Func="TestFuncControlledMember", AvailableIn=CertifiedApps] |
michael@0 | 658 | void prefable23(); |
michael@0 | 659 | [Pref="abc.def", Func="TestFuncControlledMember", AvailableIn=PrivilegedApps] |
michael@0 | 660 | void prefable24(); |
michael@0 | 661 | |
michael@0 | 662 | // Miscellania |
michael@0 | 663 | [LenientThis] attribute long attrWithLenientThis; |
michael@0 | 664 | // FIXME: Bug 863954 Unforgeable things get all confused when |
michael@0 | 665 | // non-JS-implemented interfaces inherit from JS-implemented ones or vice |
michael@0 | 666 | // versa. |
michael@0 | 667 | // [Unforgeable] readonly attribute long unforgeableAttr; |
michael@0 | 668 | // [Unforgeable, ChromeOnly] readonly attribute long unforgeableAttr2; |
michael@0 | 669 | // FIXME: Bug 863955 No stringifiers yet |
michael@0 | 670 | // stringifier; |
michael@0 | 671 | void passRenamedInterface(TestRenamedInterface arg); |
michael@0 | 672 | [PutForwards=writableByte] readonly attribute TestJSImplInterface putForwardsAttr; |
michael@0 | 673 | [PutForwards=writableByte, LenientThis] readonly attribute TestJSImplInterface putForwardsAttr2; |
michael@0 | 674 | [PutForwards=writableByte, ChromeOnly] readonly attribute TestJSImplInterface putForwardsAttr3; |
michael@0 | 675 | [Throws] void throwingMethod(); |
michael@0 | 676 | [Throws] attribute boolean throwingAttr; |
michael@0 | 677 | [GetterThrows] attribute boolean throwingGetterAttr; |
michael@0 | 678 | [SetterThrows] attribute boolean throwingSetterAttr; |
michael@0 | 679 | // legacycaller short(unsigned long arg1, TestInterface arg2); |
michael@0 | 680 | void passArgsWithDefaults(optional long arg1, |
michael@0 | 681 | optional TestInterface? arg2 = null, |
michael@0 | 682 | optional Dict arg3, optional double arg4 = 5.0, |
michael@0 | 683 | optional float arg5); |
michael@0 | 684 | attribute any jsonifierShouldSkipThis; |
michael@0 | 685 | attribute TestParentInterface jsonifierShouldSkipThis2; |
michael@0 | 686 | attribute TestCallbackInterface jsonifierShouldSkipThis3; |
michael@0 | 687 | jsonifier; |
michael@0 | 688 | |
michael@0 | 689 | // If you add things here, add them to TestCodeGen as well |
michael@0 | 690 | }; |
michael@0 | 691 | |
michael@0 | 692 | [NavigatorProperty="TestNavigator", JSImplementation="@mozilla.org/test;1"] |
michael@0 | 693 | interface TestNavigator { |
michael@0 | 694 | }; |
michael@0 | 695 | |
michael@0 | 696 | [Constructor, NavigatorProperty="TestNavigatorWithConstructor", JSImplementation="@mozilla.org/test;1"] |
michael@0 | 697 | interface TestNavigatorWithConstructor { |
michael@0 | 698 | }; |
michael@0 | 699 | |
michael@0 | 700 | interface TestCImplementedInterface : TestJSImplInterface { |
michael@0 | 701 | }; |
michael@0 | 702 | |
michael@0 | 703 | interface TestCImplementedInterface2 { |
michael@0 | 704 | }; |