Backed out changeset 8fc3326bce7f (bug 1943032) for causing failures at browser_tab_g...
[gecko.git] / dom / canvas / test / webgl-conf / checkout / deqp / temp_externs / es5.js
bloba7d444a8aa4936e9d7571eb9aea3253c9ead298a
1 /*
2 * Copyright 2009 The Closure Compiler Authors
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
8 * http://www.apache.org/licenses/LICENSE-2.0
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
17 /**
18 * @fileoverview Definitions for ECMAScript 5.
19 * @see http://www.ecma-international.org/publications/files/drafts/tc39-2009-025.pdf
20 * @externs
24 /**
25 * @param {Object|undefined} selfObj Specifies the object to which |this| should
26 * point when the function is run. If the value is null or undefined, it
27 * will default to the global object.
28 * @param {...*} var_args Additional arguments that are partially
29 * applied to fn.
30 * @return {!Function} A partially-applied form of the Function on which
31 * bind() was invoked as a method.
32 * @nosideeffects
33 * @see https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Function/bind
35 Function.prototype.bind = function(selfObj, var_args) {};
38 /**
39 * @this {String|string}
40 * @return {string}
41 * @nosideeffects
42 * @see http://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/String/Trim
44 String.prototype.trim = function() {};
47 /**
48 * @this {String|string}
49 * @return {string}
50 * @nosideeffects
51 * @see http://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/String/TrimLeft
53 String.prototype.trimLeft = function() {};
56 /**
57 * @this {String|string}
58 * @return {string}
59 * @nosideeffects
60 * @see http://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/String/TrimRight
62 String.prototype.trimRight = function() {};
65 /**
66 * A object property descriptor used by Object.create, Object.defineProperty,
67 * Object.defineProperties, Object.getOwnPropertyDescriptor.
69 * Note: not a real constructor.
70 * @constructor
72 var ObjectPropertyDescriptor = function(){};
74 /** @type {*} */
75 ObjectPropertyDescriptor.prototype.value;
77 /** @type {(function():?)||undefined} */
78 ObjectPropertyDescriptor.prototype.get;
80 /** @type {(function(?):void)||undefined} */
81 ObjectPropertyDescriptor.prototype.set;
83 /** @type {boolean|undefined} */
84 ObjectPropertyDescriptor.prototype.writable;
86 /** @type {boolean|undefined} */
87 ObjectPropertyDescriptor.prototype.enumerable;
89 /** @type {boolean|undefined} */
90 ObjectPropertyDescriptor.prototype.configurable;
93 /**
94 * @param {Object} proto
95 * @param {Object=} opt_properties A map of ObjectPropertyDescriptors.
96 * @return {!Object}
97 * @nosideeffects
98 * @see https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Object/create
100 Object.create = function(proto, opt_properties) {};
104 * @param {!Object} obj
105 * @param {string} prop
106 * @param {!Object} descriptor A ObjectPropertyDescriptor.
107 * @return {!Object}
108 * @see https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Object/defineProperty
110 Object.defineProperty = function(obj, prop, descriptor) {};
114 * @param {!Object} obj
115 * @param {!Object} props A map of ObjectPropertyDescriptors.
116 * @return {!Object}
117 * @see https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Object/defineProperties
119 Object.defineProperties = function(obj, props) {};
123 * @param {!Object} obj
124 * @param {string} prop
125 * @return {!ObjectPropertyDescriptor|undefined}
126 * @nosideeffects
127 * @see https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Object/getOwnPropertyDescriptor
129 Object.getOwnPropertyDescriptor = function(obj, prop) {};
133 * @param {!Object} obj
134 * @return {!Array.<string>}
135 * @nosideeffects
136 * @see https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Object/keys
138 Object.keys = function(obj) {};
142 * @param {!Object} obj
143 * @return {!Array.<string>}
144 * @nosideeffects
145 * @see https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Object/getOwnPropertyNames
147 Object.getOwnPropertyNames = function(obj) {};
151 * @param {!Object} obj
152 * @return {Object}
153 * @nosideeffects
154 * @see https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Object/GetPrototypeOf
156 Object.getPrototypeOf = function(obj) {};
160 * @param {T} obj
161 * @return {T}
162 * @template T
163 * @see https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Object/preventExtensions
165 Object.preventExtensions = function(obj) {};
169 * @param {T} obj
170 * @return {T}
171 * @template T
172 * @see https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Object/seal
174 Object.seal = function(obj) {};
178 * @param {T} obj
179 * @return {T}
180 * @template T
181 * @see https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Object/freeze
183 Object.freeze = function(obj) {};
187 * @param {!Object} obj
188 * @return {boolean}
189 * @nosideeffects
190 * @see https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Object/isExtensible
192 Object.isExtensible = function(obj) {};
196 * @param {!Object} obj
197 * @return {boolean}
198 * @nosideeffects
199 * @see https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Object/isSealed
201 Object.isSealed = function(obj) {};
205 * @param {!Object} obj
206 * @return {boolean}
207 * @nosideeffects
208 * @see https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Object/isFrozen
210 Object.isFrozen = function(obj) {};
214 * As per ECMAScript 5, 15.12.3.
215 * @param {string=} opt_key The JSON key for this object.
216 * @return {*} The serializable representation of this object. Note that this
217 * need not be a string. See http://goo.gl/PEUvs.
219 Object.prototype.toJSON = function(opt_key) {};
223 * @see https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Date/toISOString
224 * @return {string}
226 Date.prototype.toISOString = function() {};
230 * @param {*=} opt_ignoredKey
231 * @return {string}
232 * @override
234 Date.prototype.toJSON = function(opt_ignoredKey) {};
238 * A fake type to model the JSON object.
239 * @constructor
241 var JSONType = function() {};
245 * @param {string} jsonStr The string to parse.
246 * @param {(function(string, *) : *)=} opt_reviver
247 * @return {*} The JSON object.
248 * @throws {Error}
249 * @nosideeffects
251 JSONType.prototype.parse = function(jsonStr, opt_reviver) {};
255 * @param {*} jsonObj Input object.
256 * @param {(Array.<string>|(function(string, *) : *)|null)=} opt_replacer
257 * @param {(number|string)=} opt_space
258 * @return {string} JSON string which represents jsonObj.
259 * @throws {Error}
260 * @nosideeffects
262 JSONType.prototype.stringify = function(jsonObj, opt_replacer, opt_space) {};
266 * @type {!JSONType}
267 * @suppress {duplicate}
269 var JSON;