def Delete(self):
    "Deletes the simulator asynchronously.\n\n    The simulator state should be SHUTDOWN when deleting it. Otherwise, it will\n    raise exception.\n\n    Raises:\n      ios_errors.SimError: The simulator's state is not SHUTDOWN.\n    "
    if (xcode_info_util.GetXcodeVersionNumber() < 900):
        sim_state = self.GetSimulatorState()
        if (sim_state != ios_constants.SimState.SHUTDOWN):
            raise ios_errors.SimError(('Can only delete the simulator with state SHUTDOWN. The current state of simulator %s is %s.' % (self._simulator_id, sim_state)))
    logging.info('Deleting simulator %s asynchronously.', self.simulator_id)
    subprocess.Popen(['xcrun', 'simctl', 'delete', self.simulator_id], stdout=subprocess.PIPE, stderr=subprocess.PIPE, preexec_fn=os.setpgrp)
    if os.path.exists(self.simulator_log_root_dir):
        shutil.rmtree(self.simulator_log_root_dir, ignore_errors=True)
    self._simulator_id = None
Deletes the simulator asynchronously.

The simulator state should be SHUTDOWN when deleting it. Otherwise, it will
raise exception.

Raises:
  ios_errors.SimError: The simulator's state is not SHUTDOWN.
def Delete(self):
    "Deletes the simulator asynchronously.\n\n    The simulator state should be SHUTDOWN when deleting it. Otherwise, it will\n    raise exception.\n\n    Raises:\n      ios_errors.SimError: The simulator's state is not SHUTDOWN.\n    "
    if (xcode_info_util.GetXcodeVersionNumber() < 900):
        sim_state = self.GetSimulatorState()
        if (sim_state != ios_constants.SimState.SHUTDOWN):
            raise ios_errors.SimError(('Can only delete the simulator with state SHUTDOWN. The current state of simulator %s is %s.' % (self._simulator_id, sim_state)))
    logging.info('Deleting simulator %s asynchronously.', self.simulator_id)
    subprocess.Popen(['xcrun', 'simctl', 'delete', self.simulator_id], stdout=subprocess.PIPE, stderr=subprocess.PIPE, preexec_fn=os.setpgrp)
    if os.path.exists(self.simulator_log_root_dir):
        shutil.rmtree(self.simulator_log_root_dir, ignore_errors=True)
    self._simulator_id = None