OwlCyberSecurity - MANAGER
Edit File: _adapters.cpython-312.pyc
� e��g� � � � d dl Zd dlZd dlZd dlZddlmZ G d� dej j � Z G d� dej j � Zy)� N� )� FoldedCasec � � e Zd Zd� Zy)� RawPolicyc �� � | j j t j |dd� �� j � j � � }|� d|� | j � �S )N� c � � y)NT� )�lines �K/opt/hc_python/lib/python3.12/site-packages/importlib_metadata/_adapters.py�<lambda>z RawPolicy.fold.<locals>.<lambda> s � �$� )�prefix� predicatez: )�linesep�join�textwrap�indent�lstrip� splitlines)�self�name�value�foldeds r �foldzRawPolicy.fold sP � ����"�"��O�O�E�'�=N�O� �V�X� �Z�\� �� ��r�&��$�,�,��0�0r N)�__name__� __module__�__qualname__r r r r r r s � �1r r c � � � e Zd ZdZ e eeg d�� � Z dej j f� fd�Zd� Z� fd�Z � fd�Zd� Z� fd �Zed � � Z� xZS )�Messagea� Specialized Message subclass to handle metadata naturally. Reads values that may have newlines in them and converts the payload to the Description. >>> msg_text = textwrap.dedent(''' ... Name: Foo ... Version: 3.0 ... License: blah ... de-blah ... <BLANKLINE> ... First line of description. ... Second line of description. ... <BLANKLINE> ... Fourth line! ... ''').lstrip().replace('<BLANKLINE>', '') >>> msg = Message(email.message_from_string(msg_text)) >>> msg['Description'] 'First line of description.\nSecond line of description.\n\nFourth line!\n' Message should render even if values contain newlines. >>> print(msg) Name: Foo Version: 3.0 License: blah de-blah Description: First line of description. Second line of description. <BLANKLINE> Fourth line! <BLANKLINE> <BLANKLINE> ) � ClassifierzObsoletes-Dist�PlatformzProject-URLz Provides-DistzProvides-Extraz Requires-DistzRequires-ExternalzSupported-Platform�Dynamic�origc �l �� t �| � | � }t |� j t |� � |S �N)�super�__new__�vars�update)�clsr$ �res� __class__s �r r( zMessage.__new__M s, �� ��g�o�c�"���S� ����d��$�� r c �. � | j � | _ y r&