| Index: mojo/common/data_pipe_utils.h
|
| diff --git a/mojo/common/data_pipe_utils.h b/mojo/common/data_pipe_utils.h
|
| index dc2197b6e07fd14a7d1f08ec4da610e852367a5c..5952d9a03ba510dbf84a4f45c0f46c5c8e50d6d6 100644
|
| --- a/mojo/common/data_pipe_utils.h
|
| +++ b/mojo/common/data_pipe_utils.h
|
| @@ -35,6 +35,23 @@ bool MOJO_COMMON_EXPORT BlockingCopyToString(
|
| ScopedDataPipeConsumerHandle source,
|
| std::string* contents);
|
|
|
| +// Return true and the first newline terminated line from source. Return false
|
| +// if more than max_line_length bytes are scanned without seeing a newline, or
|
| +// if the timeout is exceeded.
|
| +bool MOJO_COMMON_EXPORT BlockingPeekLine(
|
| + DataPipeConsumerHandle source,
|
| + std::string* line,
|
| + size_t max_line_length,
|
| + MojoDeadline timeout);
|
| +
|
| +// Return true and the first bytes_length bytes from source. Return false
|
| +// if the timeout is exceeded.
|
| +bool MOJO_COMMON_EXPORT BlockingPeekNBytes(
|
| + DataPipeConsumerHandle source,
|
| + std::string* bytes,
|
| + size_t bytes_length,
|
| + MojoDeadline timeout);
|
| +
|
| } // namespace common
|
| } // namespace mojo
|
|
|
|
|