Use ExtensionRegistry::enabled_extensions instead of deprecated ExtensionService...
[chromium-blink-merge.git] / mojo / embedder / platform_channel_utils_posix.h
blob7ec5fa50818ee4f8d2203680da8eaf7c31e0c20a
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
3 // found in the LICENSE file.
5 #ifndef MOJO_EMBEDDER_PLATFORM_CHANNEL_UTILS_POSIX_H_
6 #define MOJO_EMBEDDER_PLATFORM_CHANNEL_UTILS_POSIX_H_
8 #include <stddef.h>
9 #include <sys/types.h> // For |ssize_t|.
11 #include "mojo/embedder/platform_handle.h"
12 #include "mojo/system/system_impl_export.h"
14 struct iovec; // Declared in <sys/uio.h>.
16 namespace mojo {
17 namespace embedder {
19 // Use these to write to a socket created using |PlatformChannelPair| (or
20 // equivalent). These are like |write()| and |writev()|, but handle |EINTR| and
21 // never raise |SIGPIPE|. (Note: On Mac, the suppression of |SIGPIPE| is set up
22 // by |PlatformChannelPair|.)
23 MOJO_SYSTEM_IMPL_EXPORT ssize_t PlatformChannelWrite(PlatformHandle h,
24 const void* bytes,
25 size_t num_bytes);
26 MOJO_SYSTEM_IMPL_EXPORT ssize_t PlatformChannelWritev(PlatformHandle h,
27 struct iovec* iov,
28 size_t num_iov);
30 } // namespace embedder
31 } // namespace mojo
33 #endif // MOJO_EMBEDDER_PLATFORM_CHANNEL_UTILS_POSIX_H_