| 36 | |
| 37 | |
| 38 | class Mac2Options( |
| 39 | AppiumOptions, |
| 40 | AppPathOption, |
| 41 | PrerunOption, |
| 42 | PostrunOption, |
| 43 | ArgumentsOption, |
| 44 | BootstrapRootOption, |
| 45 | BundleIdOption, |
| 46 | EnvironmentOption, |
| 47 | ServerStartupTimeoutOption, |
| 48 | ShowServerLogsOption, |
| 49 | SkipAppKillOption, |
| 50 | SystemHostOption, |
| 51 | SystemPortOption, |
| 52 | WebDriverAgentMacUrlOption, |
| 53 | ): |
| 54 | @PrerunOption.prerun.setter # type: ignore |
| 55 | def prerun(self, value: Dict[str, str]) -> None: |
| 56 | """ |
| 57 | A mapping containing either 'script' or 'command' key. The value of |
| 58 | each key must be a valid AppleScript script or command to be |
| 59 | executed after before Mac2Driver session is started. See |
| 60 | https://github.com/appium/appium-mac2-driver#applescript-commands-execution |
| 61 | for more details. |
| 62 | """ |
| 63 | PrerunOption.prerun.fset(self, value) # type: ignore |
| 64 | |
| 65 | @PostrunOption.postrun.setter # type: ignore |
| 66 | def postrun(self, value: Dict[str, str]) -> None: |
| 67 | """ |
| 68 | A mapping containing either 'script' or 'command' key. The value of |
| 69 | each key must be a valid AppleScript script or command to be |
| 70 | executed after Mac2Driver session is stopped. See |
| 71 | https://github.com/appium/appium-mac2-driver#applescript-commands-execution |
| 72 | for more details. |
| 73 | """ |
| 74 | PostrunOption.postrun.fset(self, value) # type: ignore |
| 75 | |
| 76 | @SystemPortOption.system_port.setter # type: ignore |
| 77 | def system_port(self, value: int) -> None: |
| 78 | """ |
| 79 | Set the number of the port for the internal server to listen on. |
| 80 | If not provided then Mac2Driver will use the default port 10100. |
| 81 | """ |
| 82 | SystemPortOption.system_port.fset(self, value) # type: ignore |
| 83 | |
| 84 | @SystemHostOption.system_host.setter # type: ignore |
| 85 | def system_host(self, value: str) -> None: |
| 86 | """ |
| 87 | Set the number of the port for the internal server to listen on. |
| 88 | If not provided then Mac2Driver will use the default host |
| 89 | address 127.0.0.1. You could set it to 0.0.0.0 to make the |
| 90 | server listening on all available network interfaces. |
| 91 | It is also possible to set the particular interface name, for example en1. |
| 92 | """ |
| 93 | SystemHostOption.system_host.fset(self, value) # type: ignore |
| 94 | |
| 95 | @BundleIdOption.bundle_id.setter # type: ignore |