OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 NET_DNS_MOCK_MDNS_SOCKET_FACTORY_H_ | 5 #ifndef NET_DNS_MOCK_MDNS_SOCKET_FACTORY_H_ |
6 #define NET_DNS_MOCK_MDNS_SOCKET_FACTORY_H_ | 6 #define NET_DNS_MOCK_MDNS_SOCKET_FACTORY_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "net/dns/mdns_client_impl.h" | 10 #include "net/dns/mdns_client_impl.h" |
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
51 MOCK_CONST_METHOD1(LeaveGroup, int(const IPAddressNumber& address)); | 51 MOCK_CONST_METHOD1(LeaveGroup, int(const IPAddressNumber& address)); |
52 | 52 |
53 MOCK_METHOD1(SetMulticastInterface, int(uint32 interface_index)); | 53 MOCK_METHOD1(SetMulticastInterface, int(uint32 interface_index)); |
54 MOCK_METHOD1(SetMulticastTimeToLive, int(int ttl)); | 54 MOCK_METHOD1(SetMulticastTimeToLive, int(int ttl)); |
55 MOCK_METHOD1(SetMulticastLoopbackMode, int(bool loopback)); | 55 MOCK_METHOD1(SetMulticastLoopbackMode, int(bool loopback)); |
56 | 56 |
57 MOCK_METHOD1(SetDiffServCodePoint, int(DiffServCodePoint dscp)); | 57 MOCK_METHOD1(SetDiffServCodePoint, int(DiffServCodePoint dscp)); |
58 | 58 |
59 MOCK_METHOD0(DetachFromThread, void()); | 59 MOCK_METHOD0(DetachFromThread, void()); |
60 | 60 |
61 void SetResponsePacket(std::string response_packet); | 61 void SetResponsePacket(const std::string& response_packet); |
62 | 62 |
63 int HandleRecvNow(IOBuffer* buffer, int size, IPEndPoint* address, | 63 int HandleRecvNow(IOBuffer* buffer, int size, IPEndPoint* address, |
64 const CompletionCallback& callback); | 64 const CompletionCallback& callback); |
65 | 65 |
66 int HandleRecvLater(IOBuffer* buffer, int size, IPEndPoint* address, | 66 int HandleRecvLater(IOBuffer* buffer, int size, IPEndPoint* address, |
67 const CompletionCallback& callback); | 67 const CompletionCallback& callback); |
68 | 68 |
69 private: | 69 private: |
70 std::string response_packet_; | 70 std::string response_packet_; |
71 IPEndPoint local_address_; | 71 IPEndPoint local_address_; |
(...skipping 24 matching lines...) Expand all Loading... |
96 ScopedVector<DatagramServerSocket>* sockets); | 96 ScopedVector<DatagramServerSocket>* sockets); |
97 | 97 |
98 scoped_refptr<IOBuffer> recv_buffer_; | 98 scoped_refptr<IOBuffer> recv_buffer_; |
99 int recv_buffer_size_; | 99 int recv_buffer_size_; |
100 CompletionCallback recv_callback_; | 100 CompletionCallback recv_callback_; |
101 }; | 101 }; |
102 | 102 |
103 } // namespace net | 103 } // namespace net |
104 | 104 |
105 #endif // NET_DNS_MOCK_MDNS_SOCKET_FACTORY_H_ | 105 #endif // NET_DNS_MOCK_MDNS_SOCKET_FACTORY_H_ |
OLD | NEW |