~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/lockable_files.py

  • Committer: Martin Pool
  • Date: 2009-07-27 05:31:55 UTC
  • mto: This revision was merged to the branch mainline in revision 4587.
  • Revision ID: mbp@sourcefrog.net-20090727053155-kjzslpoyc1uu9ggq
Update LockableFiles docstring

Show diffs side-by-side

added added

removed removed

Lines of Context:
65
65
class LockableFiles(object):
66
66
    """Object representing a set of related files locked within the same scope.
67
67
 
68
 
    These files are used by a WorkingTree, Repository or Branch, and should
69
 
    generally only be touched by that object.
70
 
 
71
 
    LockableFiles also provides some policy on top of Transport for encoding
72
 
    control files as utf-8.
 
68
    This coordinates access to the lock along with providing a transaction.
73
69
 
74
70
    LockableFiles manage a lock count and can be locked repeatedly by
75
71
    a single caller.  (The underlying lock implementation generally does not
77
73
 
78
74
    Instances of this class are often called control_files.
79
75
 
80
 
    This object builds on top of a Transport, which is used to actually write
81
 
    the files to disk, and an OSLock or LockDir, which controls how access to
82
 
    the files is controlled.  The particular type of locking used is set when
83
 
    the object is constructed.  In older formats OSLocks are used everywhere.
84
 
    in newer formats a LockDir is used for Repositories and Branches, and
85
 
    OSLocks for the local filesystem.
86
 
 
87
76
    This class is now deprecated; code should move to using the Transport
88
77
    directly for file operations and using the lock or CountedLock for
89
78
    locking.