예제 #1
0
파일: whoville.py 프로젝트: anilkunwar/OOF2
 def resume_writing(self):           # a useful skill for job applicants
     if _debuglocks:
         debug.dumpCaller()
         debug.fmsg('resuming writing', self, id(self))
     self.rwLock.write_resume()
     if _debuglocks:
         debug.fmsg('resumed writing', self, id(self))
예제 #2
0
 def resume_writing(self):  # a useful skill for job applicants
     if _debuglocks:
         debug.dumpCaller()
         debug.fmsg('resuming writing', self, id(self))
     self.rwLock.write_resume()
     if _debuglocks:
         debug.fmsg('resumed writing', self, id(self))
예제 #3
0
파일: whoville.py 프로젝트: anilkunwar/OOF2
 def end_writing(self):
     parent = self.getParent()       # See comment above
     if parent:
         parent.end_reading() 
     if _debuglocks:
         debug.dumpCaller()
         debug.fmsg('end writing', self, id(self))
     self.rwLock.write_release()
예제 #4
0
파일: whoville.py 프로젝트: anilkunwar/OOF2
 def end_reading(self):
     parent = self.getParent()
     if parent:
         parent.end_reading()
     self.rwLock.read_release()
     if _debuglocks:
         debug.dumpCaller()
         debug.fmsg('ended reading', self, id(self), self.rwLock.nReaders())
예제 #5
0
 def end_writing(self):
     parent = self.getParent()  # See comment above
     if parent:
         parent.end_reading()
     if _debuglocks:
         debug.dumpCaller()
         debug.fmsg('end writing', self, id(self))
     self.rwLock.write_release()
예제 #6
0
 def end_reading(self):
     parent = self.getParent()
     if parent:
         parent.end_reading()
     self.rwLock.read_release()
     if _debuglocks:
         debug.dumpCaller()
         debug.fmsg('ended reading', self, id(self), self.rwLock.nReaders())
예제 #7
0
파일: whoville.py 프로젝트: anilkunwar/OOF2
 def reserve(self):
     if _debuglocks:
         debug.dumpCaller()
         debug.fmsg('reserving', self)
     self.reservation_lock.acquire()
     if _debuglocks:
         debug.fmsg('reserved', self)
     self.have_reservation = 1
     switchboard.notify("made reservation", self)
예제 #8
0
 def reserve(self):
     if _debuglocks:
         debug.dumpCaller()
         debug.fmsg('reserving', self)
     self.reservation_lock.acquire()
     if _debuglocks:
         debug.fmsg('reserved', self)
     self.have_reservation = 1
     switchboard.notify("made reservation", self)
예제 #9
0
파일: whoville.py 프로젝트: anilkunwar/OOF2
 def begin_reading(self):
     if _debuglocks:
         debug.dumpCaller()
         debug.fmsg('acquiring read lock', self, id(self))
     self.rwLock.read_acquire()
     parent = self.getParent()
     if parent:
         parent.begin_reading()
     if _debuglocks:
         debug.fmsg('acquired read lock', self, id(self),
                    self.rwLock.nReaders())
예제 #10
0
 def begin_reading(self):
     if _debuglocks:
         debug.dumpCaller()
         debug.fmsg('acquiring read lock', self, id(self))
     self.rwLock.read_acquire()
     parent = self.getParent()
     if parent:
         parent.begin_reading()
     if _debuglocks:
         debug.fmsg('acquired read lock', self, id(self),
                    self.rwLock.nReaders())
예제 #11
0
파일: whoville.py 프로젝트: anilkunwar/OOF2
 def begin_writing(self):
     if _debuglocks:
         debug.dumpCaller()
         debug.fmsg('acquiring write lock', self, id(self))
     self.rwLock.write_acquire()
     # While changing an object, make sure that its parents don't
     # change as well, because that could effectively change the
     # object...  Since we're not actually changing the parent, we
     # just acquire the read lock.
     parent = self.getParent()
     if parent:
         parent.begin_reading()
     if _debuglocks:
         debug.fmsg('acquired write lock', self, id(self))
예제 #12
0
 def begin_writing(self):
     if _debuglocks:
         debug.dumpCaller()
         debug.fmsg('acquiring write lock', self, id(self))
     self.rwLock.write_acquire()
     # While changing an object, make sure that its parents don't
     # change as well, because that could effectively change the
     # object...  Since we're not actually changing the parent, we
     # just acquire the read lock.
     parent = self.getParent()
     if parent:
         parent.begin_reading()
     if _debuglocks:
         debug.fmsg('acquired write lock', self, id(self))
예제 #13
0
파일: whoville.py 프로젝트: anilkunwar/OOF2
 def pause_writing(self):
     if _debuglocks:
         debug.dumpCaller()
         debug.fmsg('pause writing', self, id(self))
     self.rwLock.write_pause()
예제 #14
0
 def pause_writing(self):
     if _debuglocks:
         debug.dumpCaller()
         debug.fmsg('pause writing', self, id(self))
     self.rwLock.write_pause()