Convert a virtual path to its corresponding path on the hosting system. Args: virtpath : path on the emulated system. the path may be either absolute or relative Returns: the corresponding path on the hosting system
(self, virtpath: str)
| 309 | return str(absvpath) |
| 310 | |
| 311 | def virtual_to_host_path(self, virtpath: str) -> str: |
| 312 | """Convert a virtual path to its corresponding path on the hosting system. |
| 313 | |
| 314 | Args: |
| 315 | virtpath : path on the emulated system. the path may be either absolute |
| 316 | or relative |
| 317 | |
| 318 | Returns: the corresponding path on the hosting system |
| 319 | """ |
| 320 | |
| 321 | absvpath = self.__virtual_resolve(virtpath) |
| 322 | hostpath = self.__virtual_to_host_path(absvpath) |
| 323 | |
| 324 | return str(hostpath) |
| 325 | |
| 326 | def is_safe_host_path(self, hostpath: str) -> bool: |
| 327 | hpath = Path(hostpath) |