Get a specific Snapshot in the File by its id .. note:: If snapshots have not been pulled, they will be pulled upon calling this. :param id: Id of Snapshot :return: Snapshot object, if one with that id exists. Else, None :raises: RuntimeError if there was an error pulling snapshots
(self, id: str)
| 315 | return result |
| 316 | |
| 317 | def get_snapshot_by_id(self, id: str) -> Optional['snapshot.CollabSnapshot']: |
| 318 | """ |
| 319 | Get a specific Snapshot in the File by its id |
| 320 | |
| 321 | .. note:: If snapshots have not been pulled, they will be pulled upon calling this. |
| 322 | |
| 323 | :param id: Id of Snapshot |
| 324 | :return: Snapshot object, if one with that id exists. Else, None |
| 325 | :raises: RuntimeError if there was an error pulling snapshots |
| 326 | """ |
| 327 | if not self.has_pulled_snapshots: |
| 328 | self.pull_snapshots() |
| 329 | |
| 330 | value = core.BNRemoteFileGetSnapshotById(self._handle, id) |
| 331 | if value is None: |
| 332 | return None |
| 333 | return snapshot.CollabSnapshot(value) |
| 334 | |
| 335 | def pull_snapshots(self, progress: 'util.ProgressFuncType' = util.nop): |
| 336 | """ |
nothing calls this directly
no test coverage detected