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

Side by Side Diff: content/public/browser/presentation_connection_message.h

Issue 2617143006: [Presentation API] Move Presentation API structs to public/common (Closed)
Patch Set: Rebase Created 3 years, 11 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 unified diff | Download patch
OLDNEW
(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 CONTENT_PUBLIC_BROWSER_PRESENTATION_CONNECTION_MESSAGE_H_
6 #define CONTENT_PUBLIC_BROWSER_PRESENTATION_CONNECTION_MESSAGE_H_
7
8 #include <stdint.h>
9
10 #include <memory>
11 #include <string>
12 #include <vector>
13
14 #include "content/common/content_export.h"
15
16 namespace content {
17
18 enum PresentationMessageType {
19 TEXT,
20 BINARY,
21 };
22
23 // Represents a presentation connection message.
24 // If this is a text message, |data| is null; otherwise, |message| is null.
25 // Empty messages are allowed.
26 struct CONTENT_EXPORT PresentationConnectionMessage {
27 public:
28 explicit PresentationConnectionMessage(PresentationMessageType type);
29 ~PresentationConnectionMessage();
30
31 bool is_binary() const;
32 const PresentationMessageType type;
33 std::string message;
34 std::unique_ptr<std::vector<uint8_t>> data;
35 };
36
37 } // namespace content
38
39 #endif // CONTENT_PUBLIC_BROWSER_PRESENTATION_CONNECTION_MESSAGE_H_
OLDNEW
« no previous file with comments | « content/public/browser/BUILD.gn ('k') | content/public/browser/presentation_connection_message.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698