Backed out changeset 8fc3326bce7f (bug 1943032) for causing failures at browser_tab_g...
[gecko.git] / dom / canvas / test / webgl-conf / checkout / deqp / temp_externs / webstorage.js
blobeee69d258145dccebc98e1b02f482d2e280f890d
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.
16 /**
17 * @fileoverview Definitions for W3C's WebStorage specification.
18 * This file depends on html5.js.
19 * @externs
22 /**
23 * @interface
24 * @see http://www.w3.org/TR/2011/CR-webstorage-20111208/#the-storage-interface
26 function Storage() {}
28 /**
29 * @type {number}
30 * @const
32 Storage.prototype.length;
34 /**
35 * @param {number} index
36 * @return {?string}
38 Storage.prototype.key = function(index) {};
40 /**
41 * @param {string} key
42 * @return {?string}
44 Storage.prototype.getItem = function(key) {};
46 /**
47 * @param {string} key
48 * @param {string} data
49 * @return {void}
51 Storage.prototype.setItem = function(key, data) {};
53 /**
54 * @param {string} key
55 * @return {void}
57 Storage.prototype.removeItem = function(key) {};
59 /**
60 * @return {void}
62 Storage.prototype.clear = function() {};
64 /**
65 * @interface
66 * @see http://www.w3.org/TR/2011/CR-webstorage-20111208/#the-sessionstorage-attribute
68 function WindowSessionStorage() {}
70 /**
71 * @type {Storage}
73 WindowSessionStorage.prototype.sessionStorage;
75 /**
76 * Window implements WindowSessionStorage
78 * @type {Storage}
80 Window.prototype.sessionStorage;
82 /**
83 * @interface
84 * @see http://www.w3.org/TR/2011/CR-webstorage-20111208/#the-localstorage-attribute
86 function WindowLocalStorage() {}
88 /**
89 * @type {Storage}
91 WindowLocalStorage.prototype.localStorage;
93 /**
94 * Window implements WindowLocalStorage
96 * @type {Storage}
98 Window.prototype.localStorage;
101 * This is the storage event interface.
102 * @see http://www.w3.org/TR/2011/CR-webstorage-20111208/#the-storage-event
103 * @extends {Event}
104 * @constructor
106 function StorageEvent() {}
109 * @type {string}
111 StorageEvent.prototype.key;
114 * @type {?string}
116 StorageEvent.prototype.oldValue;
119 * @type {?string}
121 StorageEvent.prototype.newValue;
124 * @type {string}
126 StorageEvent.prototype.url;
129 * @type {?Storage}
131 StorageEvent.prototype.storageArea;
134 * @param {string} typeArg
135 * @param {boolean} canBubbleArg
136 * @param {boolean} cancelableArg
137 * @param {string} keyArg
138 * @param {?string} oldValueArg
139 * @param {?string} newValueArg
140 * @param {string} urlArg
141 * @param {?Storage} storageAreaArg
142 * @return {void}
144 StorageEvent.prototype.initStorageEvent = function(typeArg, canBubbleArg,
145 cancelableArg, keyArg,
146 oldValueArg, newValueArg,
147 urlArg, storageAreaArg) {};