Closes the `IOLoop`, freeing any resources used. If ``all_fds`` is true, all file descriptors registered on the IOLoop will be closed (not just the ones created by the `IOLoop` itself). Many applications will only use a single `IOLoop` that runs for the enti
(self, all_fds: bool = False)
| 356 | self.make_current() |
| 357 | |
| 358 | def close(self, all_fds: bool = False) -> None: |
| 359 | """Closes the `IOLoop`, freeing any resources used. |
| 360 | |
| 361 | If ``all_fds`` is true, all file descriptors registered on the |
| 362 | IOLoop will be closed (not just the ones created by the |
| 363 | `IOLoop` itself). |
| 364 | |
| 365 | Many applications will only use a single `IOLoop` that runs for the |
| 366 | entire lifetime of the process. In that case closing the `IOLoop` |
| 367 | is not necessary since everything will be cleaned up when the |
| 368 | process exits. `IOLoop.close` is provided mainly for scenarios |
| 369 | such as unit tests, which create and destroy a large number of |
| 370 | ``IOLoops``. |
| 371 | |
| 372 | An `IOLoop` must be completely stopped before it can be closed. This |
| 373 | means that `IOLoop.stop()` must be called *and* `IOLoop.start()` must |
| 374 | be allowed to return before attempting to call `IOLoop.close()`. |
| 375 | Therefore the call to `close` will usually appear just after |
| 376 | the call to `start` rather than near the call to `stop`. |
| 377 | |
| 378 | .. versionchanged:: 3.1 |
| 379 | If the `IOLoop` implementation supports non-integer objects |
| 380 | for "file descriptors", those objects will have their |
| 381 | ``close`` method when ``all_fds`` is true. |
| 382 | """ |
| 383 | raise NotImplementedError() |
| 384 | |
| 385 | @typing.overload |
| 386 | def add_handler( |
no outgoing calls