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

Side by Side Diff: remoting/host/setup/native_messaging_writer.h

Issue 49113003: It2Me native messaging: GYP and source refactoring (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 1 month 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 | Annotate | Revision Log
OLDNEW
(Empty)
1 // Copyright 2013 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 REMOTING_HOST_SETUP_NATIVE_MESSAGING_WRITER_H_
6 #define REMOTING_HOST_SETUP_NATIVE_MESSAGING_WRITER_H_
7
8 #include "base/platform_file.h"
9 #include "net/base/file_stream.h"
10
11 namespace base {
12 class Value;
13 } // namespace base
14
15 namespace remoting {
16
17 // This class is used for sending messages to the Native Messaging client
18 // webapp.
19 class NativeMessagingWriter {
20 public:
21 explicit NativeMessagingWriter(base::PlatformFile handle);
22 ~NativeMessagingWriter();
23
24 // Sends a message to the Native Messaging client, returning true if
25 // successful.
26 bool WriteMessage(const base::Value& message);
27
28 private:
29 net::FileStream write_stream_;
30 bool fail_;
31
32 DISALLOW_COPY_AND_ASSIGN(NativeMessagingWriter);
33 };
34
35 } // namespace remoting
36
37 #endif // REMOTING_HOST_SETUP_NATIVE_MESSAGING_WRITER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698