@@ 1913-1925 (lines=13) @@ | ||
1910 | ||
1911 | return self._send_xml_command(cmd) |
|
1912 | ||
1913 | def __get_task(self, task_id: str, usage_type: UsageType) -> Any: |
|
1914 | if not task_id: |
|
1915 | raise RequiredArgument( |
|
1916 | function=self.get_task.__name__, argument='task_id' |
|
1917 | ) |
|
1918 | ||
1919 | cmd = XmlCommand("get_tasks") |
|
1920 | cmd.set_attribute("task_id", task_id) |
|
1921 | cmd.set_attribute("usage_type", usage_type.value) |
|
1922 | ||
1923 | # for single entity always request all details |
|
1924 | cmd.set_attribute("details", "1") |
|
1925 | return self._send_xml_command(cmd) |
|
1926 | ||
1927 | def resume_audit(self, audit_id: str) -> Any: |
|
1928 | """Resume an existing stopped audit |
@@ 2072-2084 (lines=13) @@ | ||
2069 | ||
2070 | return self._send_xml_command(cmd) |
|
2071 | ||
2072 | def __get_task(self, task_id: str, usage_type: UsageType) -> Any: |
|
2073 | if not task_id: |
|
2074 | raise RequiredArgument( |
|
2075 | function=self.get_task.__name__, argument='task_id' |
|
2076 | ) |
|
2077 | ||
2078 | cmd = XmlCommand("get_tasks") |
|
2079 | cmd.set_attribute("task_id", task_id) |
|
2080 | cmd.set_attribute("usage_type", usage_type.value) |
|
2081 | ||
2082 | # for single entity always request all details |
|
2083 | cmd.set_attribute("details", "1") |
|
2084 | return self._send_xml_command(cmd) |
|
2085 | ||
2086 | def resume_audit(self, audit_id: str) -> Any: |
|
2087 | """Resume an existing stopped audit |