-=[ Mr. Bumblebee ]=-
_Indonesia_

Path : /usr/lib/python2.7/dist-packages/bzrlib/plugins/weave_fmt/
File Upload :
Current File : //usr/lib/python2.7/dist-packages/bzrlib/plugins/weave_fmt/workingtree.pyc

σ
ψΩOc@@sγdZddlmZddlmZddlmZmZm	Z	m
Z
mZm
Z
mZddlmZddlmZddlmZddlmZdd	lmZd
„Zdefd„ƒYZd
efd„ƒYZdS(sWeave-era working tree objects.i(tabsolute_import(tStringIO(t	conflictsterrorst	inventorytosutilstrevisiont	transformtxml5(tneeds_read_lock(tMutableTree(tLocalTransport(tWorkingTreeFormat(tPreDirStateWorkingTreecC@s6x/tjD]$}|j|ƒr
|t|ƒ Sq
WdS(N(t_mod_conflictstCONFLICT_SUFFIXEStendswithtlen(tpathtsuffix((sH/usr/lib/python2.7/dist-packages/bzrlib/plugins/weave_fmt/workingtree.pytget_conflicted_stem+stWorkingTreeFormat2cB@sheZdZeZeZdZeZeZ	d„Z
d„Zddded„Z
d„Zed„ZRS(skThe second working tree format.

    This format modified the hash cache from the format 1 hash cache.
    s
Branch-FoRMaTcC@sdS(s/See WorkingTreeFormat.get_format_description().sWorking tree format 2((tself((sH/usr/lib/python2.7/dist-packages/bzrlib/plugins/weave_fmt/workingtree.pytget_format_descriptionAscC@setƒ}tjƒ}tjj||dtƒ|jdƒ|jd||ƒ|j	dd|ƒdS(sWorkaround: create control files for a remote working tree.

        This ensures that it can later be updated and dealt with locally,
        since BzrDirFormat6 and BzrDirFormat5 cannot represent dirs with
        no working tree.  (See bug #43064).
        tworkingiRspending-mergestN(
RRt	InventoryRt
serializer_v5twrite_inventorytTruetseektput_filet	put_bytes(Rt	transportt	file_modetsiotinv((sH/usr/lib/python2.7/dist-packages/bzrlib/plugins/weave_fmt/workingtree.pyt_stub_initialize_on_transportEs	
cC@st|jtƒs*tj|jjƒ‚n|dk	r?|}n|jƒ}|dkrotj	|j
ƒƒ}n|jƒz|j|ƒWd|j
ƒXtjƒ}t|jjdƒ||dtd|d|d|jƒ}|jj|ƒ}	|	jƒdk	r|j|	jƒƒntj|ƒr/g}
n||	fg}
|j|
ƒtj|	|ƒxtjdD]}||ƒqiW|S(s#See WorkingTreeFormat.initialize().Nt.t	_internalt_formatt_bzrdirt_control_filestpost_build_tree(t
isinstanceR!RRtNotLocalUrltbasetNonetopen_brancht
_mod_revisiontensure_nullt
last_revisiont
lock_writetgenerate_revision_historytunlockRRtWorkingTree2troot_transportt
local_abspathRt
control_filest
repositoryt
revision_treetget_root_idtset_root_idtis_nulltset_parent_treesRt
build_treeR
thooks(Rta_bzrdirtrevision_idtfrom_branchtaccelerator_treethardlinktbranchR$twtt
basis_treetparent_treesthook((sH/usr/lib/python2.7/dist-packages/bzrlib/plugins/weave_fmt/workingtree.pyt
initializeSs<	
	
cC@s3tt|ƒjƒddlm}|ƒ|_dS(Ni(t
BzrDirFormat6(tsuperRt__init__tbzrlib.plugins.weave_fmt.bzrdirRNt_matchingbzrdir(RRN((sH/usr/lib/python2.7/dist-packages/bzrlib/plugins/weave_fmt/workingtree.pyRPysc
C@sv|st‚nt|jtƒs9tj|jjƒ‚nt|jj	dƒdt
d|d|d|jƒjƒ}|S(sΉReturn the WorkingTree object for a_bzrdir

        _found is a private parameter, do not use it. It is used to indicate
               if format probing has already been done.
        R&R'R(R)R*(
tNotImplementedErrorR,R!RRR-R.R7R8R9RR0R:(RRCt_foundRI((sH/usr/lib/python2.7/dist-packages/bzrlib/plugins/weave_fmt/workingtree.pytopen~s	N(t__name__t
__module__t__doc__Rtupgrade_recommendedt%requires_normalized_unicode_filenamestcase_sensitive_filenametFalsetmissing_parent_conflictstsupports_versioned_directoriesRR%R/RMRPRU(((sH/usr/lib/python2.7/dist-packages/bzrlib/plugins/weave_fmt/workingtree.pyR1s		%	R7cB@s\eZdZd„Zd„Zd„Zd„Zd„Zed„ƒZ	d„Z
d„ZRS(	s‘This is the Format 2 working tree.

    This was the first weave based working tree.
     - uses os locks for locking.
     - uses the branch last-revision.
    cO@s<tt|ƒj|||Ž|jdkr8|jƒndS(N(ROR7RPt
_inventoryR/tread_working_inventory(Rtbasedirtargstkwargs((sH/usr/lib/python2.7/dist-packages/bzrlib/plugins/weave_fmt/workingtree.pyRP™scC@sd|jƒfgS(s=Return the references needed to perform a check of this tree.ttrees(R3(R((sH/usr/lib/python2.7/dist-packages/bzrlib/plugins/weave_fmt/workingtree.pyt_get_check_refs€scC@s@|jjƒy|jjƒ|SWn|jjƒ‚nXdS(sSee WorkingTree.lock_tree_write().

        In Format2 WorkingTrees we have a single lock for the branch and tree
        so lock_tree_write() degrades to lock_write().

        :return: An object with an unlock method which will release the lock
            obtained.
        N(RHR4R*R6(R((sH/usr/lib/python2.7/dist-packages/bzrlib/plugins/weave_fmt/workingtree.pytlock_tree_write©s	


cC@se|jjdkr?|jƒ|jr2|jƒn|jƒnz|jjƒSWd|jjƒXdS(Ni(R*t_lock_countt_cleanupt_inventory_is_modifiedtflusht_write_hashcache_if_dirtyR6RH(R((sH/usr/lib/python2.7/dist-packages/bzrlib/plugins/weave_fmt/workingtree.pyR6Ίs
	

cc@smtƒ}x]|jƒD]O}|d}t|ƒ}|dkrDqn||kr|j|ƒ|VqqWdS(Ni(tsett
list_filesRR/tadd(Rt
conflictedtinfoRtstem((sH/usr/lib/python2.7/dist-packages/bzrlib/plugins/weave_fmt/workingtree.pyt_iter_conflictsΚs	

c	C@s=tjƒ}x*|jƒD]}t}y+tj|j|ƒƒdkrOt}nWntj	k
rlt}nX|tkrοxsdD]h}y5tj|j||ƒƒ}|dkrΊt}nWntj	k
rΧt}nX|tkr€Pq€q€Wnidt6dt6|}|j
tjj|d|d|j
|ƒƒƒqW|S(	Ntfiles.THISs.OTHERs
text conflictscontents conflictRtfile_id(s.THISs.OTHER(RtConflictListRrRRt	file_kindtabspathR\Rt
NoSuchFiletappendtConflicttfactorytpath2id(RRRottextRtkindtctype((sH/usr/lib/python2.7/dist-packages/bzrlib/plugins/weave_fmt/workingtree.pyRΥs.




cC@stj|j|ƒ‚dS(N(RtUnsupportedOperationt
set_conflicts(Rtarg((sH/usr/lib/python2.7/dist-packages/bzrlib/plugins/weave_fmt/workingtree.pyRοscC@stj|j|ƒ‚dS(N(RR€t
add_conflicts(RR‚((sH/usr/lib/python2.7/dist-packages/bzrlib/plugins/weave_fmt/workingtree.pyRƒςs(RVRWRXRPReRfR6RrR	RRRƒ(((sH/usr/lib/python2.7/dist-packages/bzrlib/plugins/weave_fmt/workingtree.pyR7‘s						N(RXt
__future__Rt	cStringIORtbzrlibRRRRRRR1RRtbzrlib.decoratorsR	tbzrlib.mutabletreeR
tbzrlib.transport.localRtbzrlib.workingtreeRtbzrlib.workingtree_3R
RRR7(((sH/usr/lib/python2.7/dist-packages/bzrlib/plugins/weave_fmt/workingtree.pyt<module>s4		`

Copyright © 2017 || Recoded By Mr.Bumblebee