| 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 // Accessor classes to read and write networking related structures. | 5 // Accessor classes to read and write networking related structures. |
| 6 | 6 |
| 7 part of os; | 7 part of os; |
| 8 | 8 |
| 9 class LinuxAddrInfo extends AddrInfo { | 9 class LinuxAddrInfo extends AddrInfo { |
| 10 LinuxAddrInfo() : super._(); | 10 LinuxAddrInfo() : super._(); |
| 11 LinuxAddrInfo.fromAddress(int address) : super._fromAddress(address); | 11 LinuxAddrInfo.fromAddress(int address) : super._fromAddress(address); |
| 12 | 12 |
| 13 ForeignMemory get addr { | 13 ForeignMemory get addr { |
| 14 int offset = _addrlenOffset + wordSize; | 14 int offset = _addrlenOffset + wordSize; |
| 15 return new ForeignMemory.fromAddress(getWord(offset), addrlen); | 15 return new ForeignMemory.fromAddress(getWord(offset), addrlen); |
| 16 } | 16 } |
| 17 | 17 |
| 18 get canonname { | 18 get canonname { |
| 19 int offset = _addrlenOffset + wordSize * 2; | 19 int offset = _addrlenOffset + wordSize * 2; |
| 20 return getWord(offset); | 20 return getWord(offset); |
| 21 } | 21 } |
| 22 | 22 |
| 23 AddrInfo get next { | 23 AddrInfo get next { |
| 24 int offset = _addrlenOffset + wordSize * 3; | 24 int offset = _addrlenOffset + wordSize * 3; |
| 25 return new LinuxAddrInfo.fromAddress(getWord(offset)); | 25 return new LinuxAddrInfo.fromAddress(getWord(offset)); |
| 26 } | 26 } |
| 27 } | 27 } |
| OLD | NEW |