+
    bIi                         R t Rt^ RIHtHt ^ RIHt ^ RIHt  ! R R4      t	 ! R R4      t
 ! R	 R
]4      tR tRR ltR tR tRR ltR# )z3.3.0a  Framework for objects whose assignments are checked. Used by graphics.

We developed reportlab/graphics prior to Python 2 and metaclasses. For the
graphics, we wanted to be able to declare the attributes of a class, check
them on assignment, and convert from string arguments.  Examples of
attrmap-based objects can be found in reportlab/graphics/shapes.  It lets
us defined structures like the one below, which are seen more modern form in
Django models and other frameworks.

We'll probably replace this one day soon, hopefully with no impact on client
code.

class Rect(SolidShape):
    """Rectangle, possibly with rounded corners."""

    _attrMap = AttrMap(BASE=SolidShape,
        x = AttrMapValue(isNumber),
        y = AttrMapValue(isNumber),
        width = AttrMapValue(isNumber),
        height = AttrMapValue(isNumber),
        rx = AttrMapValue(isNumber),
        ry = AttrMapValue(isNumber),
        )


)
isAnythingDerivedValue)isSeq)	rl_configc                   0   a  ] tR t^#t o RtR tR tRtV tR# )CallableValuez(a class to allow callable initial valuesc                *    Wn         W n        W0n        R # Nfuncargskw)selfr   r   r   s   &&*,~C:\Users\petid\OneDrive\Desktop\Maestro\MAESTRO CLAUDE\MAESTRO\maestro-backend\venv\Lib\site-packages\reportlab/lib/attrmap.py__init__CallableValue.__init__%   s    		    c                N    V P                   ! V P                  / V P                  B # r	   r
   )r   s   &r   __call__CallableValue.__call__+   s    yy$)).dgg..r   )r   r   r   N)	__name__
__module____qualname____firstlineno____doc__r   r   __static_attributes____classdictcell____classdict__s   @r   r   r   #   s     2/ /r   r   c                   :   a  ] tR t^.t o RtRR ltR tR tRtV t	R# )AttrMapValuez,Simple multi-value holder for attribute mapsNc                    T;'       g    \         V n        W n        W0n        W@n        VP                  4        F  w  rg\        WV4       K  	  R # r	   )r   validatedesc_initial_advancedUsageitemssetattr)r   r"   r#   initialadvancedUsager   kvs   &&&&&,  r   r   AttrMapValue.__init__0   s=     ..J	+88:CAD1 r   c                    VR 8X  d=   \        V P                  \        4      '       d   V P                  4       # V P                  # VR8X  d   ^ # \        V4      h)r(   hidden)
isinstancer$   r   AttributeError)r   names   &&r   __getattr__AttrMapValue.__getattr__8   sD    ?$--66t}}8N== 8^T""r   c                    R RP                  V P                  P                  4        Uu. uF  pRV,          NK  	  up4      ,          # u upi )zAttrMapValue(%s)z, z%s=%r)join__dict__r&   )r   is   & r   __repr__AttrMapValue.__repr__A   s=    !DIIDMMDWDWDY.ZDYqw{{DY.Z$[[[.Zs   A
)r%   r$   r#   r"   )NNN    )
r   r   r   r   r   r   r2   r8   r   r   r   s   @r   r    r    .   s     6#\ \r   r    c                   @   a  ] tR t^Dt o R. 3R ltR t. 3R ltRtV tR# )AttrMapNc                   / pV'       d   \        V\        4      '       d   TpMe\        V4      '       g   V3pV FK  p\        VR V 4      pW`Jd   V'       d   VP	                  V4       K0  K2  \        R\        V4      ,          4      h	  \        P                  W4       V P                  V4       V P	                  V4       R# )_attrMapzBASE=%s has wrong kind of valueN)
r/   r<   r   getattrupdate
ValueErrorasciidictr   remove)r   BASEUNWANTEDr   dataBams   &&&,   r   r   AttrMap.__init__E   s    $w''T{{D7DA :d3B~t{{22()JUSTX)UVV  	d HBr   c                B    V F  p W K  	  R #   \          d     K  i ; ir	   )KeyError)r   unwantedr*   s   && r   rD   AttrMap.removeW   s*    AG   s   c                @    \        WR 7      pVP                  V4       V# ))rE   rF   )r<   r@   )r   rF   r   cs   &&, r   cloneAttrMap.clone^   s    0	r    )	r   r   r   r   r   rD   rQ   r   r   r   s   @r   r<   r<   D   s#      $   r   r<   c                   \         P                  '       Ed'   V P                  pV'       Ed   V^ ,          R8w  Ed   \        V\        4      '       d   MW9   dN   W1,          P
                  p V! V4      pV'       g*   \        RV: RV RV P                  P                   24      hM\        V P                  VR	4      p\        V\        4      '       dE   \        VR
R	4      pV'       d   V! W4       R	# \        V P                  P                   RV R24      h\        RV: RV P                  P                  : 24      h\        V P                  VR	4      p\        V\        4      '       dE   \        VR
R	4      pV'       d   V! W4       R	# \        V P                  P                   RV R24      hVR8X  d8   V P                  P                  4        V P                  P                  V4       R	# W P                  V&   R	#   \         d9   pTP                  T P                  P                   RT RT RT: R24      ThR	p?ii ; i)z validate setattr(obj,name,value)_zIllegal assignment of z to z
 in class . ()Nfsetz has no setterzIllegal attribute 'z' in class r6   )r   shapeCheckingr>   r/   r   r"   r0   	__class__r   	Exceptionr?   propertyr6   clearr@   )	objr1   valueaMapr"   reproprZ   s	   &&&      r   validateSetattrrf   c   s   ||4DGcM %..:..} A ,/EeYdSWRXXbcfcpcpcycybz-{||  s}}T$7d8,,"4t4DS,0F0F/Gqn-]^^(QUWZWdWdWmWm)noo3==d+D$x  tF4(O CMM$:$:#;1TF.!QRR	z	E""T7 ! g++)?)?(@$q
RSTYS\\]&^_effgs   ,G= =I 3H;;I c                    V P                   p\        V P                  RR4      pV'       d   W2J d   VP                  4       V3# VR3# W2J d   VP                  4       V n         R# R# )zclone obj._attrMap if requiredr>   N)r>   r?   r\   rQ   )r`   retAoAs   &&  r   _privateAttrMaprk      sU    A	z$	/B
7779b= d7N7779CL r   c                    VP                  R4      p\        V4      ^ 8X  d   R# V^ R  F  p\        W4      p K  	  WR,          3# )zPLocate the object src.P for P a string, return parent and name of attribute
    rV   )NN)splitlenr?   )srcPps   && r   _findObjectAndAttrrs      sG     	
A
1v{1RA#/C bEzr   c                     \        V R 4      '       g_   V P                  p^ RIpVP                  VP                  V3VP
                  ,           R . R\        V RR4      \        3R l/4      V n        R# R# )__attrproxy__N__setattr__c                     V! WW#4      # r	   rS   )r   r*   r+   osahooks   &&&&&r   <lambda>!hook__setattr__.<locals>.<lambda>   s    Y]^befYkr   )hasattrr\   newclassobjr   	__bases__r?   ry   )r`   Cr}   s   &  r   hook__setattr__r      sc    3''MMll1::qd1;;.>Rgc-.MSWkmn (r   Nc                "   \        V R4      '       g   Q R4       h\        V ^4      w  rg\        V4      '       g   V3p. p. p	V FI  p
\        V
4      '       d   V
^ ,          V
R,          r\        W
4      w  rV'       g   K<  \	        VRR4      pKK  	  R# )z6
Add a proxy attribute 'name' to src with targets dst
r>   zsrc object has no _attrMap:   NNN)r|   rk   r   rs   r?   )rp   r1   r"   r#   r(   dstri   rj   DDVdrd   r`   attrdAs   &&&&&&         r   addProxyAttributer      s    
 3z""@$@@"C"EA::STs
A	B88Q42q&s-	3Z-B r   )r:   )NNNN)__version__r   reportlab.lib.validatorsr   r   reportlab.lib.utilsr   	reportlabr   r   r    rC   r<   rf   rk   rs   r   r   rS   r   r   <module>r      s[    	4 > % 	/ 	/\ \,d >)#V%	n.r   