| Index: Source/modules/serviceworkers/Headers.idl
|
| diff --git a/Source/modules/serviceworkers/HeaderMap.idl b/Source/modules/serviceworkers/Headers.idl
|
| similarity index 28%
|
| copy from Source/modules/serviceworkers/HeaderMap.idl
|
| copy to Source/modules/serviceworkers/Headers.idl
|
| index 38d198bda48eda69952f48a42f53e83ef8f72fd0..ad662b041327760603bd64417fda7a18f48a0880 100644
|
| --- a/Source/modules/serviceworkers/HeaderMap.idl
|
| +++ b/Source/modules/serviceworkers/Headers.idl
|
| @@ -3,26 +3,23 @@
|
| // found in the LICENSE file.
|
|
|
| // http://fetch.spec.whatwg.org/#headers-class
|
| -// FIXME: Fetch spec has renamed this to just 'Headers'
|
| -// FIXME: This should be defined as MapClass(DOMString, DOMString)
|
| -// once binding code supports it (http://crbug.com/347435).
|
| [
|
| Constructor,
|
| + Constructor(Headers input),
|
| + Constructor(Dictionary input),
|
| RuntimeEnabled=ServiceWorker,
|
| - Exposed=ServiceWorker
|
| -] interface HeaderMap {
|
| - readonly attribute unsigned long size;
|
| -
|
| - // FIXME: Define keys, values, entries.
|
| - // FIXME: Some of the method definitions (like set) don't strictly
|
| - // follow the MapClass's ones (http://heycam.github.io/webidl/#MapClass),
|
| - // as this is supposed to be a transient implementation until we have real
|
| - // MapClass.
|
| + Exposed=ServiceWorker,
|
| + RaisesException=Constructor
|
| +] interface Headers {
|
| + [RaisesException] void append(ByteString name, ByteString value);
|
| + [ImplementedAs=remove, RaisesException] void delete(ByteString key);
|
| + [TreatReturnedNullStringAs=Null, RaisesException] ByteString? get(ByteString key);
|
| + [RaisesException] sequence<ByteString> getAll(ByteString name);
|
| + [RaisesException] boolean has(ByteString key);
|
| + [RaisesException] void set(ByteString key, ByteString value);
|
|
|
| - void clear();
|
| - [ImplementedAs=remove] boolean delete(DOMString key);
|
| - DOMString get(DOMString key);
|
| - boolean has(DOMString key);
|
| - void set(DOMString key, DOMString value);
|
| - void forEach(HeaderMapForEachCallback callback, optional any thisArg);
|
| + // The followings are not defined in the spec yet.
|
| + // https://www.w3.org/Bugs/Public/show_bug.cgi?id=26102
|
| + readonly attribute unsigned long size;
|
| + void forEach(HeadersForEachCallback callback, optional any thisArg);
|
| };
|
|
|