def METHOD_NAME(self, scan_id):
    time.sleep(0.01)
    for res in self.results:
        if res.result_type == 'log':
            self.add_scan_log(
                scan_id,
                res.host,
                res.hostname,
                res.name,
                res.value,
                res.port,
            )
        if res.result_type == 'error':
            self.add_scan_error(
                scan_id,
                res.host,
                res.hostname,
                res.name,
                res.value,
                res.port,
            )
        elif res.result_type == 'host-detail':
            self.add_scan_host_detail(
                scan_id,
                res.host,
                res.hostname,
                res.name,
                res.value,
            )
        elif res.result_type == 'alarm':
            self.add_scan_alarm(
                scan_id,
                res.host,
                res.hostname,
                res.name,
                res.value,
                res.port,
                res.test_id,
                res.severity,
                res.qod,
            )
        else:
            raise ValueError(res.result_type)