U
    '1eb                     @   sF   d Z dZG dd dZedkrBedddZe Zee ee dS )	z3.3.0zBData structure to hold a collection of attributes, used by styles.c                   @   s(   e Zd ZdZdd Zdd Zdd ZdS )	ABagaS  
    'Attribute Bag' - a trivial BAG class for holding attributes.

    This predates modern Python.  Doing this again, we'd use a subclass
    of dict.

    You may initialize with keyword arguments.
    a = ABag(k0=v0,....,kx=vx,....) ==> getattr(a,'kx')==vx

    c = a.clone(ak0=av0,.....) copy with optional additional attributes.
    c                 K   s   | j | d S N)__dict__update)selfattr r   6/tmp/pip-unpacked-wheel-109iniqw/reportlab/lib/abag.py__init__   s    zABag.__init__c                 K   s"   | j f | j}|r|j| |S r   )	__class__r   r   )r   r   nr   r   r   clone   s     z
ABag.clonec                    s>   | j  t  }|  d| jjd fdd|D f S )Nz%s(%s)z, c                    s   g | ]}d | | f qS )z%s=%rr   ).0kDr   r   
<listcomp>   s     z!ABag.__repr__.<locals>.<listcomp>)r   listkeyssortr
   __name__join)r   Kr   r   r   __repr__   s    zABag.__repr__N)r   
__module____qualname____doc__r	   r   r   r   r   r   r   r      s   r   __main__   Zhello)acN)__version__r   r   r   ZABr   ZCDprintr   r   r   r   <module>   s   