-
Notifications
You must be signed in to change notification settings - Fork 240
/
azure.ai.textanalytics.AnalyzeHealthcareEntitiesLROPoller.yml
181 lines (174 loc) · 8.02 KB
/
azure.ai.textanalytics.AnalyzeHealthcareEntitiesLROPoller.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
### YamlMime:PythonClass
uid: azure.ai.textanalytics.AnalyzeHealthcareEntitiesLROPoller
name: AnalyzeHealthcareEntitiesLROPoller
fullName: azure.ai.textanalytics.AnalyzeHealthcareEntitiesLROPoller
module: azure.ai.textanalytics
inheritances:
- azure.core.polling._poller.LROPoller
constructor:
syntax: 'AnalyzeHealthcareEntitiesLROPoller(client: Any, initial_response: Any,
deserialization_callback: Callable[[Any], PollingReturnType_co], polling_method:
PollingMethod[PollingReturnType_co])'
parameters:
- name: client
isRequired: true
- name: initial_response
isRequired: true
- name: deserialization_callback
isRequired: true
- name: polling_method
isRequired: true
methods:
- uid: azure.ai.textanalytics.AnalyzeHealthcareEntitiesLROPoller.add_done_callback
name: add_done_callback
summary: 'Add callback function to be run once the long running operation
has completed - regardless of the status of the operation.'
signature: 'add_done_callback(func: Callable) -> None'
parameters:
- name: func
description: 'Callback function that takes at least one
argument, a completed LongRunningOperation.'
isRequired: true
types:
- <xref:callable>
- uid: azure.ai.textanalytics.AnalyzeHealthcareEntitiesLROPoller.cancel
name: cancel
summary: Cancel the operation currently being polled.
signature: 'cancel(**kwargs: Any) -> LROPoller[None]'
keywordOnlyParameters:
- name: polling_interval
description: 'The polling interval to use to poll the cancellation status.
The default value is 5 seconds.'
types:
- <xref:int>
return:
description: Returns an instance of an LROPoller that returns None.
types:
- <xref:azure.core.polling.LROPoller>[<xref:None>]
exceptions:
- type: azure.core.exceptions.HttpResponseError
description: When the operation has already reached a terminal state.
examples:
- "Cancel an existing health operation.<!--[!code-python[Main](les\\sample_analyze_healthcare_entities_with_cancellation.py\
\ )]-->\n\n<!-- literal_block {\"ids\": [], \"classes\": [], \"names\": [], \"\
dupnames\": [], \"backrefs\": [], \"source\": \"C:\\\\hostedtoolcache\\\\windows\\\
\\Python\\\\3.11.9\\\\x64\\\\Lib\\\\site-packages\\\\py2docfx\\\\dist_temp\\\\\
8\\\\azure-ai-textanalytics-5.3.0\\\\samples\\\\sample_analyze_healthcare_entities_with_cancellation.py\"\
, \"xml:space\": \"preserve\", \"force\": false, \"language\": \"python\", \"\
highlight_args\": {\"linenostart\": 1}, \"linenos\": false} -->\n\n````python\n\
\n import os\n from azure.core.exceptions import HttpResponseError\n from\
\ azure.core.credentials import AzureKeyCredential\n from azure.ai.textanalytics\
\ import TextAnalyticsClient\n\n endpoint = os.environ[\"AZURE_LANGUAGE_ENDPOINT\"\
]\n key = os.environ[\"AZURE_LANGUAGE_KEY\"]\n\n text_analytics_client = TextAnalyticsClient(\n\
\ endpoint=endpoint,\n credential=AzureKeyCredential(key),\n )\n\
\n documents = [\n \"RECORD #333582770390100 | MH | 85986313 | | 054351\
\ | 2/14/2001 12:00:00 AM | \\\n CORONARY ARTERY DISEASE | Signed | DIS\
\ | Admission Date: 5/22/2001 \\\n Report Status: Signed Discharge Date:\
\ 4/24/2001 ADMISSION DIAGNOSIS: \\\n CORONARY ARTERY DISEASE. HISTORY OF\
\ PRESENT ILLNESS: \\\n The patient is a 54-year-old gentleman with a history\
\ of progressive angina over the past several months. \\\n The patient had\
\ a cardiac catheterization in July of this year revealing total occlusion of\
\ the RCA and \\\n 50% left main disease , with a strong family history\
\ of coronary artery disease with a brother dying at \\\n the age of 52\
\ from a myocardial infarction and another brother who is status post coronary\
\ artery bypass grafting. \\\n The patient had a stress echocardiogram done\
\ on July , 2001 , which showed no wall motion abnormalities ,\\\n but this\
\ was a difficult study due to body habitus. The patient went for six minutes\
\ with minimal ST depressions \\\n in the anterior lateral leads , thought\
\ due to fatigue and wrist pain , his anginal equivalent. Due to the patient's\
\ \\\n increased symptoms and family history and history left main disease\
\ with total occasional of his RCA was referred \\\n for revascularization\
\ with open heart surgery.\"\n ]\n\n poller = text_analytics_client.begin_analyze_healthcare_entities(documents)\n\
\n try:\n poller.cancel()\n except HttpResponseError as e:\n #\
\ If the operation has already reached a terminal state it cannot be cancelled.\n\
\ print(e)\n\n else:\n print(\"Healthcare entities analysis was\
\ successfully cancelled.\")\n\n\n ````\n"
- uid: azure.ai.textanalytics.AnalyzeHealthcareEntitiesLROPoller.continuation_token
name: continuation_token
summary: Return a continuation token that allows to restart the poller later.
signature: continuation_token() -> str
return:
description: An opaque continuation token
types:
- <xref:str>
- uid: azure.ai.textanalytics.AnalyzeHealthcareEntitiesLROPoller.done
name: done
summary: Check status of the long running operation.
signature: done() -> bool
return:
description: '''True'' if the process has completed, else ''False''.'
types:
- <xref:bool>
- uid: azure.ai.textanalytics.AnalyzeHealthcareEntitiesLROPoller.polling_method
name: polling_method
summary: Return the polling method associated to this poller.
signature: polling_method() -> AnalyzeHealthcareEntitiesLROPollingMethod
return:
description: AnalyzeHealthcareEntitiesLROPollingMethod
types:
- <xref:AnalyzeHealthcareEntitiesLROPollingMethod>
- uid: azure.ai.textanalytics.AnalyzeHealthcareEntitiesLROPoller.remove_done_callback
name: remove_done_callback
summary: Remove a callback from the long running operation.
signature: 'remove_done_callback(func: Callable) -> None'
parameters:
- name: func
description: The function to be removed from the callbacks.
isRequired: true
types:
- <xref:callable>
exceptions:
- type: ValueError
description: if the long running operation has already completed.
- uid: azure.ai.textanalytics.AnalyzeHealthcareEntitiesLROPoller.result
name: result
summary: 'Return the result of the long running operation, or
the result available after the specified timeout.'
signature: 'result(timeout: float | None = None) -> PollingReturnType_co'
parameters:
- name: timeout
description: Period of time to wait before getting back control.
defaultValue: None
types:
- <xref:float>
return:
description: The deserialized resource of the long running operation, if one is
available.
types:
- <xref:any>
- <xref:None>
exceptions:
- type: azure.core.exceptions.HttpResponseError
description: Server problem with the query.
- uid: azure.ai.textanalytics.AnalyzeHealthcareEntitiesLROPoller.status
name: status
summary: Returns the current status string.
signature: status() -> str
return:
description: The current status string
types:
- <xref:str>
- uid: azure.ai.textanalytics.AnalyzeHealthcareEntitiesLROPoller.wait
name: wait
summary: 'Wait on the long running operation for a specified length
of time. You can check if this call as ended with timeout with the
"done()" method.'
signature: 'wait(timeout: float | None = None) -> None'
parameters:
- name: timeout
description: 'Period of time to wait for the long running
operation to complete (in seconds).'
isRequired: true
types:
- <xref:float>
exceptions:
- type: azure.core.exceptions.HttpResponseError
description: Server problem with the query.
attributes:
- uid: azure.ai.textanalytics.AnalyzeHealthcareEntitiesLROPoller.details
name: details
summary: Long-running operation metadata.
return:
description: A mapping of details about the long-running operation.
types:
- <xref:typing.Mapping>[<xref:str>, <xref:typing.Any>]