+
    FhRt                        R t ^ RIHt ^ RIt^ RIt^ RIt^ RIt^ RIt ^ RIH	t	  ^ RIHt ^ RIHtHt ^ t^t ^ RIHtHt RtRtR	tR
t]P6                  R+8  d   ]]3t ! R R]4      t ! R R]4      t  ! R R]4      t! ! R R]]"4      t#R t$]PJ                  ! ]PL                  ]$R7      t'R]3R lt(]3R lt) ! R R]*4      t+ ! R R]+4      t, ! R R]+4      t- ! R R]+4      t. ! R  R!]+4      t/ ! R" R#]+4      t0 ! R$ R%]+4      t1 ! R& R']*4      t2 ! R( R)]*4      t3R* t4R#   ]
 d    ^ RIH	t	  ELi ; i  ]
 d    ]t ELi ; i  ]
 d    ^ RIHtHt ]t ELi ; i),zApply JSON-Patches (RFC 6902) )unicode_literalsN)Sequence)MappingProxyType)JsonPointerJsonPointerException)MutableMappingMutableSequenceu    Stefan Kögl <stefan@skoegl.net>z1.33z0https://github.com/stefankoegl/python-json-patchzModified BSD Licensec                       ] tR t^PtRtRtR# )JsonPatchExceptionzBase Json Patch exception N__name__
__module____qualname____firstlineno____doc____static_attributes__r       )lib/python3.14/site-packages/jsonpatch.pyr
   r
   P       #r   r
   c                       ] tR t^TtRtRtR# )InvalidJsonPatchz+Raised if an invalid JSON Patch is created r   Nr   r   r   r   r   r   T   s    6r   r   c                       ] tR t^XtRtRtR# )JsonPatchConflictzRaised if patch could not be applied due to conflict situation such as:
- attempt to add object key when it already exists;
- attempt to operate with nonexistence object key;
- attempt to insert value to array at position beyond its size;
- etc.
r   Nr   r   r   r   r   r   X   s    r   r   c                       ] tR t^atRtRtR# )JsonPatchTestFailedzA Test operation failed r   Nr   r   r   r   r   r   a   r   r   r   c                    \         P                  ! \        4      pV  F  w  r#W,          P                  V4       K  	  \	        R VP                  4        4       4      # )z'Convert duplicate keys values to lists.c              3   `   "   T F$  w  rT\        V4      ^8X  d
   V^ ,          MT3x  K&  	  R# 5i   N)len).0keyvaluess   &  r   	<genexpr>multidict.<locals>.<genexpr>l   s1       )KC 
3v;!+fQi8(s   ,.)collectionsdefaultdictlistappenddictitems)ordered_pairsmdictr"   values   &   r   	multidictr/   e   sT     ##D)E#

%  $   !;;=  r   )object_pairs_hookFc                    \        V\        4      '       d   \        P                  WR7      pM\        WR7      pVP	                  W4      # )aL  Apply list of patches to specified json document.

:param doc: Document object.
:type doc: dict

:param patch: JSON patch as list of dicts or raw JSON-encoded string.
:type patch: list or str

:param in_place: While :const:`True` patch will modify target document.
                 By default patch will be applied to document copy.
:type in_place: bool

:param pointer_cls: JSON pointer class to use.
:type pointer_cls: Type[JsonPointer]

:return: Patched document object.
:rtype: dict

>>> doc = {'foo': 'bar'}
>>> patch = [{'op': 'add', 'path': '/baz', 'value': 'qux'}]
>>> other = apply_patch(doc, patch)
>>> doc is not other
True
>>> other == {'foo': 'bar', 'baz': 'qux'}
True
>>> patch = [{'op': 'add', 'path': '/baz', 'value': 'qux'}]
>>> apply_patch(doc, patch, in_place=True) == {'foo': 'bar', 'baz': 'qux'}
True
>>> doc == other
True
pointer_cls)
isinstance
basestring	JsonPatchfrom_stringapply)docpatchin_placer3   s   &&&&r   apply_patchr<   x   s>    B %$$%%e%E%9;;s%%r   c                0    \         P                  WVR7      # )a  Generates patch by comparing two document objects. Actually is
a proxy to :meth:`JsonPatch.from_diff` method.

:param src: Data source document object.
:type src: dict

:param dst: Data source document object.
:type dst: dict

:param pointer_cls: JSON pointer class to use.
:type pointer_cls: Type[JsonPointer]

>>> src = {'foo': 'bar', 'numbers': [1, 3, 4, 8]}
>>> dst = {'baz': 'qux', 'numbers': [1, 4, 7]}
>>> patch = make_patch(src, dst)
>>> new = patch.apply(src)
>>> new == dst
True
r2   )r6   	from_diff)srcdstr3   s   &&&r   
make_patchrA      s    * s[AAr   c                      a  ] tR t^t o Rt]3R ltR tR tR t	R t
]R 4       t]R 4       t]P                  R	 4       tR
tV tR# )PatchOperationz'A single operation inside a JSON Patch.c                   W n         VP                  R 4      '       g   \        R4      h\        VR ,          V P                   4      '       d(   VR ,          P                  V n        VR ,          V n        M/VR ,          V n         V P                  V P
                  4      V n        Wn        R#   \         d   p\        R4      hRp?ii ; i)pathz#Operation must have a 'path' memberzInvalid 'path'N)	r3   __contains__r   r4   rE   locationpointer	TypeError	operation)selfrJ   r3   exs   &&& r   __init__PatchOperation.__init__   s    &%%f--"#HIIi')9)9::%f-22DM$V,DL%f-DM9#//> #  9&'7889s    B* *C5C  Cc                    \        R4      h)zGAbstract method that applies a patch operation to the specified object.z%should implement the patch operation.)NotImplementedError)rK   objs   &&r   r8   PatchOperation.apply   s    !"IJJr   c                Z    \        \        V P                  P                  4       4      4      # N)hash	frozensetrJ   r+   rK   s   &r   __hash__PatchOperation.__hash__   s    Idnn224566r   c                d    \        V\        4      '       g   R # V P                  VP                  8H  # F)r4   rC   rJ   rK   others   &&r   __eq__PatchOperation.__eq__   s%    %00~~00r   c                    W8X  * # rT   r   r\   s   &&r   __ne__PatchOperation.__ne__       !!r   c                R    R P                  V P                  P                  RR 4      # )/N)joinrH   partsrW   s   &r   rE   PatchOperation.path   s"    xx**3B/00r   c                     \        V P                  P                  R,          4      #   \         d!    T P                  P                  R,          u # i ; i)r   rf   )intrH   rh   
ValueErrorrW   s   &r   r"   PatchOperation.key   sE    	*t||))"-.. 	*<<%%b))	*s   %( (AAc                    \        V4      V P                  P                  R&   V P                  P                  V n        V P                  V P
                  R&   R# )r   rE   Nrf   )strrH   rh   rE   rG   rJ   )rK   r.   s   &&r   r"   rm      s=    !$U2))!%vr   )rG   rJ   rH   r3   N)r   r   r   r   r   r   rM   r8   rX   r^   ra   propertyrE   r"   setterr   __classdictcell____classdict__s   @r   rC   rC      se     1.9 #$K71
" 1 1 * * 	ZZ/ /r   rC   c                   6   a  ] tR t^t o RtR tR tR tRtV t	R# )RemoveOperationz/Removes an object property or an array element.c                <   V P                   P                  V4      w  r#\        V\        4      '       d1   \        V\        4      '       g   \        R P                  V4      4      h W# V#   \        \        3 d"   pRP                  T4      p\        T4      hRp?ii ; i)zinvalid array index '{0}'z(can't remove a non-existent object '{0}'N)
rH   to_lastr4   r   rk   r   formatKeyError
IndexErrorr   )rK   rQ   subobjpartrL   msgs   &&    r   r8   RemoveOperation.apply   s    ||++C0fh''
40E0E&'B'I'I$'OPP	)
 
	 *% 	)<CCDIC#C((	)s   %A) )B:BBc                    V P                   V8X  d6   V P                  V8  d   V ;P                  ^,          un        V# V^,          pV# r   rE   r"   rK   rE   r"   s   &&&r   _on_undo_removeRemoveOperation._on_undo_remove   s=    99xx3A 
 q
r   c                    V P                   V8X  d6   V P                  V8  d   V ;P                  ^,          un        V# V^,          pV# r   r   r   s   &&&r   _on_undo_addRemoveOperation._on_undo_add  =    99xx#~A 
 q
r   r   N
r   r   r   r   r   r8   r   r   r   rr   rs   s   @r   rv   rv      s     9 r   rv   c                   6   a  ] tR tRt o RtR tR tR tRtV t	R# )AddOperationi  z,Adds an object property or an array element.c                N    V P                   R ,          pT P                  P	                  T4      w  rE\        T\        4      '       dQ   TR8X  d   TP                  T4       T# T\        T4      8  g   T^ 8  d   \        R4      hTP                  YR4        T# \        T\        4      '       d   Tf   TpT# Y$T&    T# Tf$   \        RP                  \        T4      4      4      h\        RP                  T P                  T4      4      h  \         d   p\        R4      hRp?ii ; i)r.   /The operation does not contain a 'value' memberN-zcan't insert outside of listinvalid document type {0}2unable to fully resolve json pointer {0}, part {1})rJ   rz   r   rH   rx   r4   r   r)   r    r   insertr   rI   ry   typerG   )rK   rQ   r.   rL   r|   r}   s   &&    r   r8   AddOperation.apply  s#   	CNN7+E
 ||++C0fo..s{e$& 
# F#tax'(FGG d* 
 //| 
  %t 
	 | ; B B4< PQQ'(\(c(cdhdqdqsw(xyy5  	C"AC C	Cs   D	 	D$DD$c                    V P                   V8X  d6   V P                  V8  d   V ;P                  ^,          un        V# V^,          pV# r   r   r   s   &&&r   r   AddOperation._on_undo_remove3  r   r   c                    V P                   V8X  d6   V P                  V8  d   V ;P                  ^,          un        V# V^,          pV# r   r   r   s   &&&r   r   AddOperation._on_undo_add;  r   r   r   Nr   rs   s   @r   r   r     s     6@ r   r   c                   6   a  ] tR tRt o RtR tR tR tRtV t	R# )ReplaceOperationiD  z?Replaces an object property or an array element by a new value.c                X    V P                   R ,          pT P                  P	                  T4      w  rETf   T# TR8X  d   \        R4      h\        T\        4      '       d$   T\        T4      8  g   T^ 8  d   \        R4      hM\        T\        4      '       d$   YT9  d   RP                  T4      p\        T4      hMLTf$   \        RP                  \        T4      4      4      h\        RP                  T P                  T4      4      hY$T&   T#   \         d   p\        R4      hRp?ii ; i)	r.   r   Nr   z7'path' with '-' can't be applied to 'replace' operationzcan't replace outside of listz)can't replace a non-existent object '{0}'r   r   )rJ   rz   r   rH   rx   r4   r   r    r   r   ry   rI   r   rG   )rK   rQ   r.   rL   r|   r}   r~   s   &&     r   r8   ReplaceOperation.applyG  s%   	CNN7+E
 ||++C0<L3;"#\]]fo..s6{"dQh'(GHH '/ //!AHHN',, " | ; B B4< PQQ'(\(c(cdhdqdqsw(xyyt
7  	C"AC C	Cs   D D)D$$D)c                    V# rT   r   r   s   &&&r   r    ReplaceOperation._on_undo_removeg      
r   c                    V# rT   r   r   s   &&&r   r   ReplaceOperation._on_undo_addj  r   r   r   Nr   rs   s   @r   r   r   D  s     I@ r   r   c                   z   a  ] tR tRt o RtR t]R 4       t]R 4       t]P                  R 4       tR t
R tR	tV tR
# )MoveOperationin  z?Moves an object property or an array element to a new location.c                *    \        V P                  R ,          V P                  4      '       d   V P                  R ,          pM#V P                  V P                  R ,          4      p VP                  V4      w  rE WE,          pT P                  T8X  d   T# \        T\        4      '       d-   T P                  P                  T4      '       d   \        R4      h\        RRRT P                  R ,          /T P                  R7      P                  T4      p\        RRRT P                  R	T/T P                  R7      P                  T4      pT#   \         d   p\	        R4      hRp?ii ; i  \        \        3 d   p\        \        T4      4      hRp?ii ; i)
from.The operation does not contain a 'from' memberNz*Cannot move values into their own childrenopremoverE   r2   addr.   )r4   rJ   r3   rz   r   rx   r{   r   ro   rH   r   containsrv   r8   r   rG   rK   rQ   from_ptrrL   r|   r}   r.   s   &&     r   r8   MoveOperation.applyq  sv   	B$..0$2B2BCC>>&1++DNN6,BC
  '',	-LE
 <<8#Jfn--%%h//#$PQQ(DNN6*
 '') */s 	
 %DMMU
 ''	) */s	 	 
;  	B"@B B	B *% 	-#CG,,	-s6   A E
 "E
 :E( 
E%E  E%(F9FFc                    V P                  V P                  R ,          4      pRP                  VP                  RR 4      # )r   re   Nrf   )r3   rJ   rg   rh   rK   r   s   & r   	from_pathMoveOperation.from_path  s5    ##DNN6$:;xxs+,,r   c                    V P                  V P                  R ,          4      p \        VP                  R,          4      #   \         d    TP                  R,          u # i ; i)r   rf   )r3   rJ   rk   rh   rI   r   s   & r   from_keyMoveOperation.from_key  sR    ##DNN6$:;	&x~~b)** 	&>>"%%	&s   A   A! A!c                    V P                  V P                  R ,          4      p\        V4      VP                  R&   VP                  V P                  R &   R# )r   Nrf   )r3   rJ   ro   rh   rE   )rK   r.   r   s   && r   r   r     s?    ##DNN6$:; Zr!)vr   c                   V P                   V8X  d5   V P                  V8  d   V ;P                  ^,          un        M	V^,          pV P                  V8X  d6   V P                  V8  d   V ;P                  ^,          un        V# V^,          pV# r   r   r   rE   r"   r   s   &&&r   r   MoveOperation._on_undo_remove  sl    >>T!}}#"q99xx#~A 
 q
r   c                   V P                   V8X  d5   V P                  V8  d   V ;P                  ^,          un        M	V^,          pV P                  V8X  d6   V P                  V8  d   V ;P                  ^,          un        V# V^,          pV# r   r   r   s   &&&r   r   MoveOperation._on_undo_add  sl    >>T!}}s""q99xx#~A 
 q
r   r   N)r   r   r   r   r   r8   rp   r   r   rq   r   r   r   rr   rs   s   @r   r   r   n  s]     I#J - - & & __/ /
 r   r   c                   *   a  ] tR tRt o RtR tRtV tR# )TestOperationi  z!Test value by specified location.c           
         V P                   P                  V4      w  r#Vf   TpMV P                   P                  W#4      p  V P                  R,          pYF8w  d2   Rp\	        TP                  T\        T4      T\        T4      4      4      hT#   \         d   p\	        \        T4      4      hR p?ii ; i  \         d   p\        R4      hR p?ii ; i)Nr.   r   z0{0} ({1}) is not equal to tested value {2} ({3}))rH   rx   walkr   r   ro   rJ   rz   r   ry   r   )rK   rQ   r|   r}   valrL   r.   r~   s   &&      r   r8   TestOperation.apply  s    	/<<//4LF|ll''5	CNN7+E
 <DC%cjjd3i16U'E F F 
 $ 	/%c"g..	/
  	C"AC C	Cs4   #B B B6 B3B..B36CCCr   Nr   r   r   r   r   r8   r   rr   rs   s   @r   r   r     s     + r   r   c                   *   a  ] tR tRt o RtR tRtV tR# )CopyOperationi  z@Copies an object property or an array element to a new location c                    V P                  V P                  R ,          4      pTP	                  T4      w  rE \
        P                  ! YE,          4      p\        RRRT P                  RT/T P                   R7      P                  T4      pT#   \         d   p\        R4      hRp?ii ; i  \        \        3 d   p\        \        T4      4      hRp?ii ; i)r   r   Nr   r   rE   r.   r2   )r3   rJ   rz   r   rx   copydeepcopyr{   r   ro   r   rG   r8   r   s   &&     r   r8   CopyOperation.apply  s    	B''v(>?H
  '',	-MM&,/E %DMMU
 ''	) */s	 	 
!  	B"@B B	B *% 	-#CG,,	-s.   "B B* B'B""B'*C;CCr   Nr   rs   s   @r   r   r     s     K r   r   c                     a  ] tR tRt o ]! ]P                  4      t]! ]4      t	]
! R]R]R]R]R]R]/4      t ]3R ltR	 tR
 t]tR tR tR tR t]R]3R l4       t]RR]3R l4       tRR lt]R 4       t RR lt!R t"Rt#V t$R# )r6   i  r   r   replacemovetestr   c                    Wn         W n        V P                    F5  p\        V\        4      '       d   \	        R 4      hV P                  V4       K7  	  R# )zMDocument is expected to be sequence of operations, got a sequence of strings.N)r:   r3   r4   r5   r   _get_operation)rK   r:   r3   r   s   &&& r   rM   JsonPatch.__init__2  sQ    
& **B "j))& (P Q Q # r   c                "    V P                  4       # )zstr(self) -> self.to_string())	to_stringrW   s   &r   __str__JsonPatch.__str__J  s    ~~r   c                ,    \        V P                  4      # rT   )boolr:   rW   s   &r   __bool__JsonPatch.__bool__N      DJJr   c                ,    \        V P                  4      # rT   )iterr:   rW   s   &r   __iter__JsonPatch.__iter__S  r   r   c                >    \        \        V P                  4      4      # rT   )rU   tuple_opsrW   s   &r   rX   JsonPatch.__hash__V  s    E$))$%%r   c                d    \        V\        4      '       g   R # V P                  VP                  8H  # r[   )r4   r6   r   r\   s   &&r   r^   JsonPatch.__eq__Y  s%    %++yyEJJ&&r   c                    W8X  * # rT   r   r\   s   &&r   ra   JsonPatch.__ne__^  rc   r   Nc                P    T;'       g    V P                   pV! V4      pV ! WSR7      # )a`  Creates JsonPatch instance from string source.

:param patch_str: JSON patch as raw string.
:type patch_str: str

:param loads: A function of one argument that loads a serialized
              JSON string.
:type loads: function

:param pointer_cls: JSON pointer class to use.
:type pointer_cls: Type[JsonPointer]

:return: :class:`JsonPatch` instance.
r2   )json_loader)cls	patch_strloadsr3   r   r:   s   &&&&  r   r7   JsonPatch.from_stringa  s*      ..sI&522r   Tc                    T;'       g    V P                   p\        WWeR7      pVP                  RRW4       \        VP	                  4       4      pV ! WR7      # )a  Creates JsonPatch instance based on comparison of two document
objects. Json patch would be created for `src` argument against `dst`
one.

:param src: Data source document object.
:type src: dict

:param dst: Data source document object.
:type dst: dict

:param dumps: A function of one argument that produces a serialized
              JSON string.
:type dumps: function

:param pointer_cls: JSON pointer class to use.
:type pointer_cls: Type[JsonPointer]

:return: :class:`JsonPatch` instance.

>>> src = {'foo': 'bar', 'numbers': [1, 3, 4, 8]}
>>> dst = {'baz': 'qux', 'numbers': [1, 4, 7]}
>>> patch = JsonPatch.from_diff(src, dst)
>>> new = patch.apply(src)
>>> new == dst
True
r2    N)json_dumperDiffBuilder_compare_valuesr(   execute)	r   r?   r@   optimizationdumpsr3   r   builderopss	   &&&&&&   r   r>   JsonPatch.from_diffu  sO    > ..scMD#37??$%300r   c                R    T;'       g    V P                   pV! V P                  4      # )z!Returns patch set as JSON string.)r   r:   )rK   r   r   s   && r   r   JsonPatch.to_string  s$    //t//4::&&r   c                T    \        \        V P                  V P                  4      4      # rT   )r   mapr   r:   rW   s   &r   r   JsonPatch._ops  s    S,,djj9::r   c                    V'       g   \         P                  ! V4      pV P                   F  pVP                  V4      pK  	  V# )zApplies the patch to a given object.

:param obj: Document object.
:type obj: dict

:param in_place: Tweaks the way how patch would be applied - directly to
                 specified `obj` or to its copy.
:type in_place: bool

:return: Modified `obj`.
)r   r   r   r8   )rK   rQ   r;   rJ   s   &&& r   r8   JsonPatch.apply  s8     --$CI//#&C # 
r   c                   R V9  d   \        R4      hVR ,          p\        V\        4      '       g   \        R4      hW P                  9  d   \        RP	                  V4      4      hV P                  V,          pV! WP
                  R7      # )r   z&Operation does not contain 'op' memberzOperation's op must be a stringzUnknown operation {0!r}r2   )r   r4   r5   
operationsry   r3   )rK   rJ   r   r   s   &&  r   r   JsonPatch._get_operation  sx    y "#KLLt_"j))"#DEE__$"#<#C#CB#GHHoob!9*:*:;;r   )r:   r3   rT   r[   )%r   r   r   r   staticmethodjsonr   r   
_jsonloadsr   r   rv   r   r   r   r   r   r   r   rM   r   r   __nonzero__r   rX   r^   ra   classmethodr7   r>   r   rp   r   r8   r   r   rr   rs   s   @r   r6   r6     s     tzz*Kz*K!/|## J,Z +6 $0   K &'
" *.K 3 3& (,D#"1 "1H'
 ; ;*< <r   r6   c                      a  ] tR tRt o ]P
                  ]3R ltR tR t	R t
R tR tR tR	 tR
 tR tR tR tR tR tRtV tR# )r   i  c                z    W0n         W@n        / / .V n        . . .V n        . ;V n        pWn        W n        WUR .VR&   R # )NNNN)r   r3   index_storageindex_storage2_DiffBuilder__rootsrc_docdst_doc)rK   r
  r  r   r3   roots   &&&&& r   rM   DiffBuilder.__init__  sI    
& "X!2hdt$Qr   c                   V\        V4      3p V P                  V,          pVP                  V4      pVf   V.WT&   R # WT,          P                  V4       R #   \         d(    T P
                  T,          P                  YB34        R # i ; irT   )r   r  getr)   rI   r  )rK   r.   indexst	typed_keystoragestoreds   &&&&   r   store_indexDiffBuilder.store_index  s~    DK(			?((,G[[+F~&+W""))%0 	?#**I+=>	?s   -A A .B	B	c                   V\        V4      3p V P                  V,          P                  V4      pV'       d   VP                  4       # R#   \         dl    T P
                  T,          p\        \        T4      ^,
          RR4       F3  pYV,          ^ ,          T8X  g   K  TP                  T4      ^,          u u # 	   R# i ; i)r   Nrf   )r   r  r  poprI   r  ranger    )rK   r.   r  r  r  r  is   &&&    r   
take_indexDiffBuilder.take_index  s    DK(			-''+//	:Fzz|#   	-))"-G3w<>2r2:a=I-";;q>!,, 3	-s   9A ACC;C Cc                V    V P                   pV^ ,          pW2V.;V^&   V^ &   V^ ,          # )    r	  )rK   r   r  lasts   &&  r   r   DiffBuilder.insert  s4    {{Aw!,,Q$q'Awr   c                *    Vw  r#pW2^&   W#^ &   . VR&   R# )r   r  Nr   )rK   r  	link_prev	link_next_s   &&   r   r   DiffBuilder.remove  s#    "'	a ! !ar   c              #  n   "   V P                   pV^,          pW2Jd   V^,          x  V^,          pK  R# 5ir   r  )rK   startr  currs   &&  r   	iter_fromDiffBuilder.iter_from  s4     {{Qxq'M7D    35c              #  n   "   V P                   pV^,          pW!Jd   V^,          x  V^,          pK  R# 5ir   r  )rK   r  r)  s   &  r   r   DiffBuilder.__iter__  s4     {{Awq'M7D r,  c           	   #    "   V P                   pV^,          pW!Jd   V^,          VJd   V^,          V^,          ^,          rCVP                  VP                  8X  d   \        V4      \        8X  dk   \        V4      \        8X  dW   \        RRRVP                  RVP                  R,          /V P                  R7      P                  x  V^,          ^,          pK  V^,          P                  x  V^,          pK  R# 5i)r   r   r   rE   r.   r2   N)r	  rG   r   rv   r   r   rJ   r3   )rK   r  r)  op_first	op_seconds   &    r   r   DiffBuilder.execute  s     {{AwAwd"&*1gtAwqz)$$	(:(::X/9Y<7*i	 2 2!4!4W!=, $(#3#3	5 6?Y	?
  71:Dq'###7D s   C;C=c                   V P                  V\        4      pVe   V^,          p\        VP                  4      \        8X  dX   \        V4      \        8X  dD   V P                  V4       F.  pVP                  VP                  VP                  4      Vn        K0  	  V P                  V4       VP                  \        W4      8w  dD   \        RRRVP                  R\        W4      /V P                  R7      pV P                  V4       R # R # \        RRR\        W4      RV/V P                  R7      pV P                  V4      pV P                  W8\         4       R # )Nr   r   r   rE   r2   r   r.   )r  
_ST_REMOVEr   r"   rk   r*  r   rE   r   rG   
_path_joinr   r3   r   r   r  _ST_ADD)	rK   rE   r"   itemr  r   vnew_op	new_indexs	   &&&&     r   _item_addedDiffBuilder._item_added  s   j1qBBFF|s"tCyC'7.A..rww?BF / KK{{j33&&BKKJt1(  $//	1
 F# 4 "e
4-#  ++	-F
 F+ITg6r   c           	        \        R RR\        W4      /V P                  R7      pV P                  V\        4      pV P                  V4      pVEe   V^,          pVP                  P                  V P                  4      ^ ,          p\        V4      \        8X  dD   V P                  V4       F.  p	V	P                  VP                  VP                  4      Vn        K0  	  V P                  V4       VP                   VP                   8w  d8   \#        R RRVP                   RVP                   /V P                  R7      pWF^&   R# V P                  V4       R# V P%                  W6\&        4       R# )r   r   rE   r2   Nr   r   )rv   r5  r3   r  r6  r   rH   rx   r  r   r(   r*  r   rE   r"   r   rG   r   r  r4  )
rK   rE   r"   r7  r9  r  r:  r   
added_itemr8  s
   &&&&      r   _item_removedDiffBuilder._item_removed5  s+    (Jt)"
 '') g.KK'	qB
 ++DLL9!<JJ4'.A^^BGGRVV<BF / KK"++-&&FOOBKK(  $//	1
  &! I& Tj9r   c                p    V P                  \        R RR\        W4      RV/V P                  R7      4       R# )r   r   rE   r.   r2   N)r   r   r5  r3   )rK   rE   r"   r7  s   &&&&r   _item_replacedDiffBuilder._item_replacedV  s:    $)Jt)T&
 ''	) 	*r   c                   \        VP                  4       4      p\        VP                  4       4      pWT,
          pWE,
          pV F%  pV P                  V\        V4      W(,          4       K'  	  V F%  pV P	                  V\        V4      W8,          4       K'  	  WE,           F"  pV P                  WW(,          W8,          4       K$  	  R # rT   )setkeysr?  ro   r;  r   )	rK   rE   r?   r@   src_keysdst_keys
added_keysremoved_keysr"   s	   &&&&     r   _compare_dictsDiffBuilder._compare_dicts]  s    sxxz?sxxz?(
*CtSXsx8   CT3s8SX6  &&C  CHch? 'r   c                   \        V4      \        V4      rT\        WE4      p\        WE4      p\        V4       EF  pW8  d   W(,          W8,          rW8X  d   K!  \	        V	\
        4      '       d4   \	        V
\
        4      '       d   V P                  \        W4      W4       Kj  \	        V	\        4      '       d4   \	        V
\        4      '       d   V P                  \        W4      W4       K  V P                  WV	4       V P                  WV
4       K  WE8  d   V P                  WW(,          4       K  V P                  WW8,          4       EK  	  R # rT   )r    maxminr  r4   r   rK  r5  r   _compare_listsr?  r;  )rK   rE   r?   r@   len_srclen_dstmax_lenmin_lenr"   oldnews   &&&&       r   rP  DiffBuilder._compare_listsl  s    s8SXg'g'>C}8SXS:^44sN33''
4(=sH_55"388''
4(=sH &&t#6$$T4"""4#(;   CH5- "r   c                   \        V\        4      '       d4   \        V\        4      '       d   V P                  \        W4      W44       R # \        V\        4      '       d4   \        V\        4      '       d   V P                  \        W4      W44       R # V P                  V4      V P                  V4      8X  d   R # V P                  WV4       R # rT   )r4   r   rK  r5  r   rP  r   rB  )rK   rE   r"   r?   r@   s   &&&&&r   r   DiffBuilder._compare_values  s    c>**3//
4 5s@_--300
4 5s@ ZZ_

3/ 3/r   )__rootr  r   r  r  r3   r
  N)r   r   r   r   r   r   r   rM   r  r  r   r   r*  r   r   r;  r?  rB  rK  rP  r   r   rr   rs   s   @r   r   r     s[     /3zz{ %?-(72:B*@680 0r   r   c                     Vf   V # V R,           \        V4      P                  RR4      P                  RR4      ,           # )Nre   ~z~0z~1)ro   r   r   s   &&r   r5  r5    s9    
{#:C((d3;;CFFFr   )   r  )5r   
__future__r   r&   r   	functoolsr   syscollections.abcr   ImportErrortypesr   r*   jsonpointerr   r   r6  r4  r   r   unicodero   
__author____version____website____license__version_infobytesr5   	Exceptionr
   r   r   AssertionErrorr   r/   partialr   r  r<   rA   objectrC   rv   r   r   r   r   r   r6   r   r5  r   r   r   <module>rp     s  B & '     
%(&
 : 
? 0
@$ vJ$ $7) 7* $,n $  tzzYG
 &+ %&P &1 B03/V 3/ln D1> 1h'~ 'TSN SlN 6N 2M< M<`T0& T0nGe  %$$%
    ;
Cs3   D  D4 E  D10D14	E EEE