관리-도구
편집 파일: contextlib.cpython-310.opt-1.pyc
o 6��fe � @ s~ d Z ddlZddlZddlZddlmZ ddlmZ ddlm Z m Z g d�ZG dd� dej�Z G d d � d ej�ZG dd� de�ZG d d� de�ZG dd� d�ZG dd� dee e�ZG dd� deee�Zdd� Zdd� ZG dd� de �ZG dd� de�ZG dd� de �ZG dd � d e�ZG d!d"� d"e�ZG d#d$� d$e �ZG d%d&� d&�ZG d'd(� d(ee �ZG d)d*� d*ee�ZG d+d,� d,e e�Z dS )-z4Utilities for with-statement contexts. See PEP 343.� N)�deque��wraps)� MethodType�GenericAlias) �asynccontextmanager�contextmanager�closing�nullcontext�AbstractContextManager�AbstractAsyncContextManager�AsyncExitStack�ContextDecorator� ExitStack�redirect_stdout�redirect_stderr�suppress�aclosingc @ �: e Zd ZdZee�Zdd� Zej dd� �Z edd� �ZdS ) r z,An abstract base class for context managers.c C � | S �z0Return `self` upon entering the runtime context.� ��selfr r �1/opt/alt/python310/lib64/python3.10/contextlib.py� __enter__ s z AbstractContextManager.__enter__c C s dS �z9Raise any exception triggered within the runtime context.Nr �r �exc_type� exc_value� tracebackr r r �__exit__ � zAbstractContextManager.__exit__c C � | t u rt�|dd�S tS )Nr r! )r �_collections_abc�_check_methods�NotImplemented��cls�Cr r r �__subclasshook__ s z'AbstractContextManager.__subclasshook__N)�__name__� __module__�__qualname__�__doc__�classmethodr �__class_getitem__r �abc�abstractmethodr! r* r r r r r � r c @ r ) r z9An abstract base class for asynchronous context managers.c � � �| S r r r r r r � __aenter__+ s �z&AbstractAsyncContextManager.__aenter__c � s �dS r r r r r r � __aexit__/ s �z%AbstractAsyncContextManager.__aexit__c C r# )Nr5 r6 )r r$ r% r&