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

Unified Diff: Source/modules/navigatorconnect/ServicePortCollection.cpp

Issue 1192913003: Start implementing new navigator.connect API (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: override instead of virtual Created 5 years, 6 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
Index: Source/modules/navigatorconnect/ServicePortCollection.cpp
diff --git a/Source/modules/navigatorconnect/ServicePortCollection.cpp b/Source/modules/navigatorconnect/ServicePortCollection.cpp
new file mode 100644
index 0000000000000000000000000000000000000000..b9d8df1dedd6c92e9e9d5e5d0d7c4595b33e59f5
--- /dev/null
+++ b/Source/modules/navigatorconnect/ServicePortCollection.cpp
@@ -0,0 +1,59 @@
+// Copyright 2015 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#include "config.h"
+#include "modules/navigatorconnect/ServicePortCollection.h"
+
+#include "core/dom/DOMException.h"
+#include "core/dom/ExceptionCode.h"
+#include "modules/EventTargetModules.h"
+
+namespace blink {
+
+PassRefPtrWillBeRawPtr<ServicePortCollection> ServicePortCollection::create(ExecutionContext* context)
+{
+ return adoptRefWillBeNoop(new ServicePortCollection(context));
+}
+
+ServicePortCollection::~ServicePortCollection()
+{
+}
+
+ScriptPromise ServicePortCollection::connect(ScriptState* scriptState, const String& url, const ServicePortConnectOptions& options)
+{
+ return ScriptPromise::rejectWithDOMException(scriptState, DOMException::create(NotSupportedError));
+}
+
+ScriptPromise ServicePortCollection::match(ScriptState* scriptState, const ServicePortMatchOptions& options)
+{
+ return ScriptPromise::rejectWithDOMException(scriptState, DOMException::create(NotSupportedError));
+}
+
+ScriptPromise ServicePortCollection::matchAll(ScriptState* scriptState, const ServicePortMatchOptions& options)
+{
+ return ScriptPromise::rejectWithDOMException(scriptState, DOMException::create(NotSupportedError));
+}
+
+const AtomicString& ServicePortCollection::interfaceName() const
+{
+ return EventTargetNames::ServicePortCollection;
+}
+
+ExecutionContext* ServicePortCollection::executionContext() const
+{
+ return ContextLifecycleObserver::executionContext();
+}
+
+DEFINE_TRACE(ServicePortCollection)
+{
+ EventTargetWithInlineData::trace(visitor);
+ ContextLifecycleObserver::trace(visitor);
+}
+
+ServicePortCollection::ServicePortCollection(ExecutionContext* context)
+ : ContextLifecycleObserver(context)
+{
+}
+
+} // namespace blink

Powered by Google App Engine
This is Rietveld 408576698