| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 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 | 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 WebServicePortProviderClient_h | 5 #ifndef WebServicePortProviderClient_h |
| 6 #define WebServicePortProviderClient_h | 6 #define WebServicePortProviderClient_h |
| 7 | 7 |
| 8 #include "public/platform/WebCommon.h" | 8 #include "public/platform/WebCommon.h" |
| 9 #include "public/platform/WebMessagePortChannel.h" |
| 10 #include "public/platform/modules/navigator_services/WebServicePort.h" |
| 9 | 11 |
| 10 namespace blink { | 12 namespace blink { |
| 11 | 13 |
| 14 class WebString; |
| 15 |
| 12 // Interface implemented by blink, used for communication back from embedding | 16 // Interface implemented by blink, used for communication back from embedding |
| 13 // code to blink. An instance of this interface is passed to the embedder when | 17 // code to blink. An instance of this interface is passed to the embedder when |
| 14 // a WebServicePortProvider is created. | 18 // a WebServicePortProvider is created. |
| 15 class WebServicePortProviderClient { | 19 class BLINK_PLATFORM_EXPORT WebServicePortProviderClient { |
| 16 public: | 20 public: |
| 17 // Post a message to one of the ports owned by a ServicePortCollection. | 21 // Post a message to one of the ports owned by a ServicePortCollection. |
| 18 virtual void postMessage(WebServicePortID, const WebString&, const WebMessag
ePortChannelArray&) = 0; | 22 virtual void postMessage(WebServicePortID, const WebString&, const WebMessag
ePortChannelArray&) = 0; |
| 19 | 23 |
| 20 protected: | 24 protected: |
| 21 virtual ~WebServicePortProviderClient() {} | 25 virtual ~WebServicePortProviderClient() {} |
| 22 }; | 26 }; |
| 23 | 27 |
| 24 } // namespace blink | 28 } // namespace blink |
| 25 | 29 |
| 26 #endif // WebServicePortProviderClient_h | 30 #endif // WebServicePortProviderClient_h |
| OLD | NEW |