| OLD | NEW |
| (Empty) |
| 1 // Copyright (c) 2011 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. | |
| 4 | |
| 5 #define IPC_MESSAGE_IMPL | |
| 6 #include "content/common/p2p_messages.h" | |
| 7 | |
| 8 namespace IPC { | |
| 9 | |
| 10 void ParamTraits<P2PSocketAddress>::Write(Message* m, const param_type& p) { | |
| 11 WriteParam(m, p.address); | |
| 12 WriteParam(m, p.port); | |
| 13 } | |
| 14 | |
| 15 bool ParamTraits<P2PSocketAddress>::Read(const Message* m, | |
| 16 void** iter, | |
| 17 param_type* p) { | |
| 18 return | |
| 19 ReadParam(m, iter, &p->address) && | |
| 20 ReadParam(m, iter, &p->port); | |
| 21 } | |
| 22 | |
| 23 void ParamTraits<P2PSocketAddress>::Log(const param_type& p, std::string* l) { | |
| 24 l->append("("); | |
| 25 LogParam(p.address, l); | |
| 26 l->append(", "); | |
| 27 LogParam(p.port, l); | |
| 28 l->append(")"); | |
| 29 } | |
| 30 | |
| 31 } // namespace IPC | |
| OLD | NEW |