Update V8 to version 4.6.61.
[chromium-blink-merge.git] / ipc / ipc_channel_common.cc
blob5438c661a301d5f7e467c646618242e5a53aef7b
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 #include "ipc/ipc_channel.h"
7 namespace IPC {
9 // static
10 scoped_ptr<Channel> Channel::CreateClient(
11 const IPC::ChannelHandle& channel_handle,
12 Listener* listener,
13 AttachmentBroker* broker) {
14 return Channel::Create(channel_handle, Channel::MODE_CLIENT, listener,
15 broker);
18 // static
19 scoped_ptr<Channel> Channel::CreateNamedServer(
20 const IPC::ChannelHandle& channel_handle,
21 Listener* listener,
22 AttachmentBroker* broker) {
23 return Channel::Create(channel_handle, Channel::MODE_NAMED_SERVER, listener,
24 broker);
27 // static
28 scoped_ptr<Channel> Channel::CreateNamedClient(
29 const IPC::ChannelHandle& channel_handle,
30 Listener* listener,
31 AttachmentBroker* broker) {
32 return Channel::Create(channel_handle, Channel::MODE_NAMED_CLIENT, listener,
33 broker);
36 #if defined(OS_POSIX)
37 // static
38 scoped_ptr<Channel> Channel::CreateOpenNamedServer(
39 const IPC::ChannelHandle& channel_handle,
40 Listener* listener,
41 AttachmentBroker* broker) {
42 return Channel::Create(channel_handle, Channel::MODE_OPEN_NAMED_SERVER,
43 listener, broker);
45 #endif
47 // static
48 scoped_ptr<Channel> Channel::CreateServer(
49 const IPC::ChannelHandle& channel_handle,
50 Listener* listener,
51 AttachmentBroker* broker) {
52 return Channel::Create(channel_handle, Channel::MODE_SERVER, listener,
53 broker);
56 Channel::~Channel() {
59 bool Channel::IsSendThreadSafe() const {
60 return false;
63 } // namespace IPC