OLD | NEW |
1 // Copyright (c) 2015, the Fletch project authors. Please see the AUTHORS file | 1 // Copyright (c) 2015, the Dartino project authors. Please see the AUTHORS file |
2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
3 // BSD-style license that can be found in the LICENSE.md file. | 3 // BSD-style license that can be found in the LICENSE.md file. |
4 | 4 |
5 library mdns.src.native_protocol_client; | 5 library mdns.src.native_protocol_client; |
6 | 6 |
7 import 'dart:async'; | 7 import 'dart:async'; |
8 import 'dart:collection'; | 8 import 'dart:collection'; |
9 import 'dart:io'; | 9 import 'dart:io'; |
10 | 10 |
11 import 'package:mdns/mdns.dart'; | 11 import 'package:mdns/mdns.dart'; |
(...skipping 146 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
158 if (event == RawSocketEvent.READ) { | 158 if (event == RawSocketEvent.READ) { |
159 Datagram datagram = _incoming.receive(); | 159 Datagram datagram = _incoming.receive(); |
160 List<ResourceRecord> response = decodeMDnsResponse(datagram.data); | 160 List<ResourceRecord> response = decodeMDnsResponse(datagram.data); |
161 if (response != null) { | 161 if (response != null) { |
162 cache.updateRecords(response); | 162 cache.updateRecords(response); |
163 _resolver.handleResponse(response); | 163 _resolver.handleResponse(response); |
164 } | 164 } |
165 } | 165 } |
166 } | 166 } |
167 } | 167 } |
OLD | NEW |