``seek`` update internal offset to ``offset``. :param int offset: offset to set the internal offset to :param int whence: optional, defaults to 0 for absolute file positioning, or 1 for relative to current location :rtype: None :Example: >>> hex(br.offset) '0x100000008L' >>> br
(self, offset: int, whence: Optional[int] = 0)
| 10446 | return struct.unpack(">Q", result)[0] |
| 10447 | |
| 10448 | def seek(self, offset: int, whence: Optional[int] = 0) -> None: |
| 10449 | """ |
| 10450 | ``seek`` update internal offset to ``offset``. |
| 10451 | |
| 10452 | :param int offset: offset to set the internal offset to |
| 10453 | :param int whence: optional, defaults to 0 for absolute file positioning, or 1 for relative to current location |
| 10454 | :rtype: None |
| 10455 | :Example: |
| 10456 | |
| 10457 | >>> hex(br.offset) |
| 10458 | '0x100000008L' |
| 10459 | >>> br.seek(0x100000000) |
| 10460 | >>> hex(br.offset) |
| 10461 | '0x100000000L' |
| 10462 | >>> |
| 10463 | """ |
| 10464 | if whence: |
| 10465 | self.seek_relative(offset) |
| 10466 | return |
| 10467 | core.BNSeekBinaryReader(self._handle, offset) |
| 10468 | |
| 10469 | def seek_relative(self, offset: int) -> None: |
| 10470 | """ |
no test coverage detected