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

Unified Diff: Source/core/streams/ReadableStream.cpp

Issue 1001233002: Streams Implementation Update: Reader name and Stream methods (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 years, 9 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/core/streams/ReadableStream.h ('k') | Source/core/streams/ReadableStream.idl » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/streams/ReadableStream.cpp
diff --git a/Source/core/streams/ReadableStream.cpp b/Source/core/streams/ReadableStream.cpp
index 91ecb5b8e7c26f2424fd856e15c3b9fbf81079fc..92ac8a87bceb92eb7f076a89f3d1bb8532553598 100644
--- a/Source/core/streams/ReadableStream.cpp
+++ b/Source/core/streams/ReadableStream.cpp
@@ -12,7 +12,7 @@
#include "core/dom/DOMException.h"
#include "core/dom/ExceptionCode.h"
#include "core/dom/ExecutionContext.h"
-#include "core/streams/ExclusiveStreamReader.h"
+#include "core/streams/ReadableStreamReader.h"
#include "core/streams/UnderlyingSource.h"
namespace blink {
@@ -171,7 +171,7 @@ void ReadableStream::readInternalPostAction()
ScriptValue ReadableStream::read(ScriptState* scriptState, ExceptionState& exceptionState)
{
if (m_reader) {
- exceptionState.throwTypeError("this stream is locked to an ExclusiveStreamReader");
+ exceptionState.throwTypeError("this stream is locked to a ReadableStreamReader");
return ScriptValue();
}
return readInternal(scriptState, exceptionState);
@@ -197,7 +197,7 @@ ScriptPromise ReadableStream::readyInternal(ScriptState* scriptState)
ScriptPromise ReadableStream::cancel(ScriptState* scriptState, ScriptValue reason)
{
if (m_reader)
- return ScriptPromise::reject(scriptState, V8ThrowException::createTypeError(scriptState->isolate(), "this stream is locked to an ExclusiveStreamReader"));
+ return ScriptPromise::reject(scriptState, V8ThrowException::createTypeError(scriptState->isolate(), "this stream is locked to a ReadableStreamReader"));
if (m_state == Closed)
return ScriptPromise::cast(scriptState, v8::Undefined(scriptState->isolate()));
if (m_state == Errored)
@@ -249,7 +249,7 @@ void ReadableStream::didSourceStart()
callPullIfNeeded();
}
-ExclusiveStreamReader* ReadableStream::getReader(ExceptionState& exceptionState)
+ReadableStreamReader* ReadableStream::getReader(ExceptionState& exceptionState)
{
if (m_state == Closed) {
exceptionState.throwTypeError("this stream is already closed");
@@ -260,13 +260,13 @@ ExclusiveStreamReader* ReadableStream::getReader(ExceptionState& exceptionState)
return nullptr;
}
if (m_reader) {
- exceptionState.throwTypeError("already locked to an ExclusiveStreamReader");
+ exceptionState.throwTypeError("already locked to a ReadableStreamReader");
return nullptr;
}
- return new ExclusiveStreamReader(this);
+ return new ReadableStreamReader(this);
}
-void ReadableStream::setReader(ExclusiveStreamReader* reader)
+void ReadableStream::setReader(ReadableStreamReader* reader)
{
ASSERT((reader && !m_reader) || (!reader && m_reader));
m_reader = reader;
« no previous file with comments | « Source/core/streams/ReadableStream.h ('k') | Source/core/streams/ReadableStream.idl » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698