OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 MOJO_SHELL_DATA_PIPE_UTILS_H_ | 5 #ifndef MOJO_SHELL_DATA_PIPE_UTILS_H_ |
6 #define MOJO_SHELL_DATA_PIPE_UTILS_H_ | 6 #define MOJO_SHELL_DATA_PIPE_UTILS_H_ |
7 | 7 |
| 8 #include <stdint.h> |
| 9 |
8 #include <string> | 10 #include <string> |
9 | 11 |
10 #include "base/callback_forward.h" | 12 #include "base/callback_forward.h" |
11 #include "mojo/common/mojo_common_export.h" | 13 #include "mojo/common/mojo_common_export.h" |
12 #include "mojo/public/cpp/system/core.h" | 14 #include "mojo/public/cpp/system/core.h" |
13 | 15 |
14 namespace base { | 16 namespace base { |
15 class FilePath; | 17 class FilePath; |
16 class TaskRunner; | 18 class TaskRunner; |
17 } | 19 } |
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
49 // Synchronously copies data from source to the destination file returning true | 51 // Synchronously copies data from source to the destination file returning true |
50 // on success and false on error. In case of an error, |destination| holds the | 52 // on success and false on error. In case of an error, |destination| holds the |
51 // data that could be read from the source before the error occured. | 53 // data that could be read from the source before the error occured. |
52 bool MOJO_COMMON_EXPORT BlockingCopyToFile(ScopedDataPipeConsumerHandle source, | 54 bool MOJO_COMMON_EXPORT BlockingCopyToFile(ScopedDataPipeConsumerHandle source, |
53 const base::FilePath& destination); | 55 const base::FilePath& destination); |
54 | 56 |
55 } // namespace common | 57 } // namespace common |
56 } // namespace mojo | 58 } // namespace mojo |
57 | 59 |
58 #endif // MOJO_SHELL_DATA_PIPE_UTILS_H_ | 60 #endif // MOJO_SHELL_DATA_PIPE_UTILS_H_ |
OLD | NEW |