def thaw(self, frz): del self[:] if not frz: return i = 0 while i < len(frz): i, (s,) = pack.unpack("!D", i, frz) self.append(s)
def thaw(self, frz): del self[:] if not frz: return i = 0 while i < len(frz): i, (s, ) = pack.unpack("!D", i, frz) self.append(s)
def _thaw(self): i = 0 self._thawedItems = dict([ (x, []) for x in self.streamDict ]) while (i < len(self._data)): i, (typeId, s) = pack.unpack('!BD', i, self._data) item = self.streamDict[typeId](s) self._thawedItems[typeId].append(item) assert(i == len(self._data)) self._data = None
def _thaw(self): i = 0 self._thawedItems = dict([ (x, {}) for x in self.streamDict ]) while (i < len(self._data)): i, (typeId, s) = pack.unpack("!BSH", i, self._data) item = self.streamDict[typeId](s) self._thawedItems[typeId][item] = True assert(i == len(self._data)) self._data = None
def _thaw(self): i = 0 self._thawedItems = dict([(x, []) for x in self.streamDict]) while (i < len(self._data)): i, (typeId, s) = pack.unpack('!BD', i, self._data) item = self.streamDict[typeId](s) self._thawedItems[typeId].append(item) assert (i == len(self._data)) self._data = None
def _thaw(self): i = 0 self._thawedItems = dict([(x, {}) for x in self.streamDict]) while (i < len(self._data)): i, (typeId, s) = pack.unpack("!BSH", i, self._data) item = self.streamDict[typeId](s) self._thawedItems[typeId][item] = True assert (i == len(self._data)) self._data = None
def twm(self, diff, base): assert(self == base) numRemoved, numAdded = struct.unpack("!HH", diff[0:4]) i = 4 for x in xrange(numRemoved + numAdded): i, (typeId, s) = pack.unpack("!BD", i, diff) item = self.streamDict[typeId](s) if x < numRemoved: l = self._items[typeId] del l[l.index(item)] else: self._items[typeId].append(item)
def twm(self, diff, base): assert (self == base) numRemoved, numAdded = struct.unpack("!HH", diff[0:4]) i = 4 for x in xrange(numRemoved + numAdded): i, (typeId, s) = pack.unpack("!BD", i, diff) item = self.streamDict[typeId](s) if x < numRemoved: l = self._items[typeId] del l[l.index(item)] else: self._items[typeId].append(item)