%PDF- %PDF-
| Direktori : /proc/self/root/proc/thread-self/root/lib64/python2.7/site-packages/zmq/utils/ |
| Current File : //proc/self/root/proc/thread-self/root/lib64/python2.7/site-packages/zmq/utils/jsonapi.pyc |
�
+�{Wc @ s� d Z d d l m Z m Z d Z d d d g Z x3 e D]+ Z y e e � Z Wn e k
ra q8 XPq8 Wd � Z
d � Z d d d
g Z d S( s� Priority based json library imports.
Always serializes to bytes instead of unicode for zeromq compatibility
on Python 2 and 3.
Use ``jsonapi.loads()`` and ``jsonapi.dumps()`` for guaranteed symmetry.
Priority: ``simplejson`` > ``jsonlib2`` > stdlib ``json``
``jsonapi.loads/dumps`` provide kwarg-compatibility with stdlib json.
``jsonapi.jsonmod`` will be the module of the actual underlying implementation.
i����( t bytest unicodet
simplejsont jsonlib2t jsonc K sP d | k r d | d <n t j | | � } t | t � rL | j d � } n | S( sf Serialize object to JSON bytes (utf-8).
See jsonapi.jsonmod.dumps for details on kwargs.
t
separatorst ,t :t utf8( R R ( t jsonmodt dumpst
isinstanceR t encode( t ot kwargst s( ( s7 /usr/lib64/python2.7/site-packages/zmq/utils/jsonapi.pyR
s
c K s= t t k r- t | t � r- | j d � } n t j | | � S( sc Load object from JSON bytes (utf-8).
See jsonapi.jsonmod.loads for details on kwargs.
R ( t strR R R t decodeR t loads( R R ( ( s7 /usr/lib64/python2.7/site-packages/zmq/utils/jsonapi.pyR / s R R
R N(
t __doc__t zmq.utils.strtypesR R t NoneR t priorityt modt
__import__t ImportErrorR
R t __all__( ( ( s7 /usr/lib64/python2.7/site-packages/zmq/utils/jsonapi.pyt <module>
s