OLD | NEW |
(Empty) | |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #ifndef ScriptReadableStreamController_h |
| 6 #define ScriptReadableStreamController_h |
| 7 |
| 8 #include "bindings/core/v8/ScriptValue.h" |
| 9 #include <v8.h> |
| 10 |
| 11 namespace blink { |
| 12 |
| 13 class ScriptReadableStreamController { |
| 14 public: |
| 15 explicit ScriptReadableStreamController(ScriptValue stream); |
| 16 void close(); |
| 17 double desiredSize() const; |
| 18 |
| 19 template<typename ChunkType> |
| 20 void enqueue(ChunkType) const; |
| 21 |
| 22 template<typename ErrorType> |
| 23 void error(ErrorType); |
| 24 |
| 25 private: |
| 26 ScriptValue m_stream; |
| 27 }; |
| 28 |
| 29 } // namespace blink |
| 30 |
| 31 #endif // ScriptReadableStreamController_h |
OLD | NEW |