OLD | NEW |
(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 #include "content/common/presentation/presentation_message.h" |
| 6 |
| 7 namespace content { |
| 8 |
| 9 MessageRequest::MessageRequest( |
| 10 const std::string& presentation_url, |
| 11 const std::string& presentation_id, |
| 12 const std::string& message) |
| 13 : presentation_url(presentation_url), |
| 14 presentation_id(presentation_id), |
| 15 type(TEXT), |
| 16 message(message) { |
| 17 } |
| 18 |
| 19 MessageRequest::MessageRequest( |
| 20 const std::string& presentation_url, |
| 21 const std::string& presentation_id, |
| 22 const std::vector<uint8_t>& data) |
| 23 : presentation_url(presentation_url), |
| 24 presentation_id(presentation_id), |
| 25 type(ARRAY_BUFFER), |
| 26 data(data) { |
| 27 } |
| 28 |
| 29 MessageRequest::MessageRequest(presentation::MessageRequestPtr request) |
| 30 : presentation_url(request->presentation_url), |
| 31 presentation_id(request->presentation_id), |
| 32 type(static_cast<PresentationMessageType>(request->type)), |
| 33 message(request->message), |
| 34 data(request->data) { |
| 35 } |
| 36 |
| 37 MessageRequest::~MessageRequest() { |
| 38 } |
| 39 |
| 40 } // namespace content |
| 41 |
OLD | NEW |