Ignore:
Timestamp:
04/22/06 16:40:43 (9 years ago)
Author:
xi
Message:

Add support for pickling/unpickling python objects.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • pyyaml/trunk/lib/yaml/__init__.py

    r146 r147  
    232232    Dumper.add_representer(data_type, representer) 
    233233 
     234def add_multi_representer(data_type, multi_representer, Dumper=Dumper): 
     235    """ 
     236    Add a representer for the given type. 
     237    Multi-representer is a function accepting a Dumper instance 
     238    and an instance of the given data type or subtype 
     239    and producing the corresponding representation node. 
     240    """ 
     241    Dumper.add_multi_representer(data_type, multi_representer) 
     242 
    234243class YAMLObjectMetaclass(type): 
    235244    """ 
Note: See TracChangeset for help on using the changeset viewer.