Definition at line 310 of file root_pickle.py.
◆ __init__()
| def python.root_pickle.Unpickler.__init__ |
( |
|
self, |
|
|
|
file, |
|
|
|
use_proxy = True, |
|
|
|
use_hash = False |
|
) |
| |
Create a root unpickler.
FILE should be a Root TFile.
Definition at line 311 of file root_pickle.py.
311 def __init__ (self, file, use_proxy = True, use_hash = False):
312 """Create a root unpickler.
313 FILE should be a Root TFile.
315 self.__use_proxy = use_proxy
317 self.__io = Read_Wrapper()
318 pickle.Unpickler.__init__ (self, self.__io)
326 for k
in file.GetListOfKeys():
330 if cy > ctab.get(nm,0):
347 ret = htab.get ((nm,cy),
None)
349 print (
"did't find", nm, cy, len(htab))
◆ find_class()
| def python.root_pickle.Unpickler.find_class |
( |
|
self, |
|
|
|
module, |
|
|
|
name |
|
) |
| |
Definition at line 387 of file root_pickle.py.
387 def find_class (self, module, name):
388 if module ==
'copy_reg':
390 elif module ==
'__builtin__':
395 mod = sys.modules[module]
397 print (
"Making dummy module %s" % (module))
401 sys.modules[module] = mod
402 klass = getattr(mod, name)
404 except AttributeError:
405 print (
"Making dummy class %s.%s" % (module, name))
406 mod = sys.modules[module]
409 setattr (mod, name, Dummy)
◆ load()
| def python.root_pickle.Unpickler.load |
( |
|
self, |
|
|
|
key = None |
|
) |
| |
Read a pickled object representation from the open file.
Definition at line 359 of file root_pickle.py.
359 def load (self, key=None):
360 """Read a pickled object representation from the open file."""
365 save = _compat_hooks[0]()
368 s = self.__file.Get (key +
';%d' % self.__n)
369 self.__io.setvalue (s)
370 o = pickle.Unpickler.load(self)
374 save = _compat_hooks[1](save)
◆ persistent_load()
| def python.root_pickle.Unpickler.persistent_load |
( |
|
self, |
|
|
|
pid |
|
) |
| |
Definition at line 377 of file root_pickle.py.
377 def persistent_load (self, pid):
379 o = Root_Proxy (self.__file, pid)
381 o = self.__file.Get (pid)
◆ __file
| python.root_pickle.Unpickler.__file |
|
private |
◆ __io
| python.root_pickle.Unpickler.__io |
|
private |
◆ __n
| python.root_pickle.Unpickler.__n |
|
private |
◆ __use_proxy
| python.root_pickle.Unpickler.__use_proxy |
|
private |
The documentation for this class was generated from the following file: