Package pyamf :: Package adapters :: Module _collections
[hide private]
[frames] | no frames]

Source Code for Module pyamf.adapters._collections

 1  # Copyright (c) 2007-2009 The PyAMF Project. 
 2  # See LICENSE.txt for details. 
 3   
 4  """ 
 5  collections adapter module. 
 6   
 7  @since: 0.5 
 8  """ 
 9   
10  import collections 
11   
12  import pyamf 
13  from pyamf.adapters import util 
14   
15   
16  if hasattr(collections, 'deque'): 
17      pyamf.add_type(collections.deque, util.to_list) 
18   
19  if hasattr(collections, 'defaultdict'): 
20      pyamf.add_type(collections.defaultdict, util.to_dict) 
21