OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 IPC_IPC_CHANNEL_WIN_H_ | 5 #ifndef IPC_IPC_CHANNEL_WIN_H_ |
6 #define IPC_IPC_CHANNEL_WIN_H_ | 6 #define IPC_IPC_CHANNEL_WIN_H_ |
7 | 7 |
8 #include "ipc/ipc_channel.h" | 8 #include "ipc/ipc_channel.h" |
9 | 9 |
10 #include <queue> | 10 #include <queue> |
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
46 | 46 |
47 | 47 |
48 private: | 48 private: |
49 // ChannelReader implementation. | 49 // ChannelReader implementation. |
50 ReadState ReadData(char* buffer, int buffer_len, int* bytes_read) override; | 50 ReadState ReadData(char* buffer, int buffer_len, int* bytes_read) override; |
51 bool ShouldDispatchInputMessage(Message* msg) override; | 51 bool ShouldDispatchInputMessage(Message* msg) override; |
52 bool GetNonBrokeredAttachments(Message* msg) override; | 52 bool GetNonBrokeredAttachments(Message* msg) override; |
53 bool DidEmptyInputBuffers() override; | 53 bool DidEmptyInputBuffers() override; |
54 void HandleInternalMessage(const Message& msg) override; | 54 void HandleInternalMessage(const Message& msg) override; |
55 base::ProcessId GetSenderPID() override; | 55 base::ProcessId GetSenderPID() override; |
56 bool IsAttachmentBrokerEndpoint() override; | |
57 | 56 |
58 static const base::string16 PipeName(const std::string& channel_id, | 57 static const base::string16 PipeName(const std::string& channel_id, |
59 int32* secret); | 58 int32* secret); |
60 bool CreatePipe(const IPC::ChannelHandle &channel_handle, Mode mode); | 59 bool CreatePipe(const IPC::ChannelHandle &channel_handle, Mode mode); |
61 | 60 |
62 bool ProcessConnection(); | 61 bool ProcessConnection(); |
63 bool ProcessOutgoingMessages(base::MessageLoopForIO::IOContext* context, | 62 bool ProcessOutgoingMessages(base::MessageLoopForIO::IOContext* context, |
64 DWORD bytes_written); | 63 DWORD bytes_written); |
65 | 64 |
66 // Returns |false| on channel error. | 65 // Returns |false| on channel error. |
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
134 // |broker_| must outlive this instance. | 133 // |broker_| must outlive this instance. |
135 AttachmentBroker* broker_; | 134 AttachmentBroker* broker_; |
136 | 135 |
137 base::WeakPtrFactory<ChannelWin> weak_factory_; | 136 base::WeakPtrFactory<ChannelWin> weak_factory_; |
138 DISALLOW_COPY_AND_ASSIGN(ChannelWin); | 137 DISALLOW_COPY_AND_ASSIGN(ChannelWin); |
139 }; | 138 }; |
140 | 139 |
141 } // namespace IPC | 140 } // namespace IPC |
142 | 141 |
143 #endif // IPC_IPC_CHANNEL_WIN_H_ | 142 #endif // IPC_IPC_CHANNEL_WIN_H_ |
OLD | NEW |