Package pyamf :: Package adapters :: Module _sets

[hide private]
[frames] | no frames]

# Source Code for Module pyamf.adapters._sets

     1  # Copyright (c) 2007-2009 The PyAMF Project.
     2  # See LICENSE for details.
     3
     4  """
     5  Adapter for the stdlib C{sets} module.
     6
     7  @since: 0.4
     8  """
     9
    10  import sets
    11
    12  import pyamf
    13  from pyamf.adapters import util
    14
    15  if hasattr(sets, 'ImmutableSet'):
    16      pyamf.add_type(sets.ImmutableSet, util.to_tuple)
    17
    18  if hasattr(sets, 'Set'):
    19      pyamf.add_type(sets.Set, util.to_tuple)
    20