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

Side by Side Diff: third_party/WebKit/Source/modules/fetch/Body.h

Issue 2292763002: [Fetch API] Implement Request.formData and Response.formData. (Closed)
Patch Set: Created 3 years, 11 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
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef Body_h 5 #ifndef Body_h
6 #define Body_h 6 #define Body_h
7 7
8 #include "bindings/core/v8/ActiveScriptWrappable.h" 8 #include "bindings/core/v8/ActiveScriptWrappable.h"
9 #include "bindings/core/v8/ScriptPromise.h" 9 #include "bindings/core/v8/ScriptPromise.h"
10 #include "bindings/core/v8/ScriptValue.h" 10 #include "bindings/core/v8/ScriptValue.h"
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
49 49
50 virtual bool bodyUsed(); 50 virtual bool bodyUsed();
51 bool isBodyLocked(); 51 bool isBodyLocked();
52 52
53 // ScriptWrappable override. 53 // ScriptWrappable override.
54 bool hasPendingActivity() const override; 54 bool hasPendingActivity() const override;
55 55
56 DEFINE_INLINE_VIRTUAL_TRACE() { ContextLifecycleObserver::trace(visitor); } 56 DEFINE_INLINE_VIRTUAL_TRACE() { ContextLifecycleObserver::trace(visitor); }
57 57
58 private: 58 private:
59 // TODO(e_hakkinen): Fix |mimeType()| to always contain parameters and
60 // remove |contentType()|.
61 virtual String contentType() const = 0;
59 virtual String mimeType() const = 0; 62 virtual String mimeType() const = 0;
60 63
61 // Body consumption algorithms will reject with a TypeError in a number of 64 // Body consumption algorithms will reject with a TypeError in a number of
62 // error conditions. This method wraps those up into one call which returns 65 // error conditions. This method wraps those up into one call which returns
63 // an empty ScriptPromise if the consumption may proceed, and a 66 // an empty ScriptPromise if the consumption may proceed, and a
64 // ScriptPromise rejected with a TypeError if it ought to be blocked. 67 // ScriptPromise rejected with a TypeError if it ought to be blocked.
65 ScriptPromise rejectInvalidConsumption(ScriptState*); 68 ScriptPromise rejectInvalidConsumption(ScriptState*);
66 }; 69 };
67 70
68 } // namespace blink 71 } // namespace blink
69 72
70 #endif // Body_h 73 #endif // Body_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698