Result returned by methods that poll for the status of an asynchronous job. Upon completion of the job, no additional information is returned. This class acts as a tagged union. Only one of the ``is_*`` methods will return true. To get the associated value of a tag (if one exists),
| 154 | PollResultBase_validator = bv.Union(PollResultBase) |
| 155 | |
| 156 | class PollEmptyResult(PollResultBase): |
| 157 | """ |
| 158 | Result returned by methods that poll for the status of an asynchronous job. |
| 159 | Upon completion of the job, no additional information is returned. |
| 160 | |
| 161 | This class acts as a tagged union. Only one of the ``is_*`` methods will |
| 162 | return true. To get the associated value of a tag (if one exists), use the |
| 163 | corresponding ``get_*`` method. |
| 164 | |
| 165 | :ivar async.PollEmptyResult.complete: The asynchronous job has completed |
| 166 | successfully. |
| 167 | """ |
| 168 | |
| 169 | # Attribute is overwritten below the class definition |
| 170 | complete = None |
| 171 | |
| 172 | def is_complete(self): |
| 173 | """ |
| 174 | Check if the union tag is ``complete``. |
| 175 | |
| 176 | :rtype: bool |
| 177 | """ |
| 178 | return self._tag == 'complete' |
| 179 | |
| 180 | def _process_custom_annotations(self, annotation_type, field_path, processor): |
| 181 | super(PollEmptyResult, self)._process_custom_annotations(annotation_type, field_path, processor) |
| 182 | |
| 183 | PollEmptyResult_validator = bv.Union(PollEmptyResult) |
| 184 |