File manager - Edit - /opt/imh-python/lib/python2.7/site-packages/werkzeug/debug/repr.pyc
Back
� �[�Rc @ s' d Z d d l Z d d l Z d d l Z d d l m Z y d d l m Z Wn e k rg d Z n Xd d l m Z d d l m Z m Z m Z m Z m Z e � Z e j d � Z e e � Z d Z d Z d � Z e d � Z d e f d � � YZ e � Z d � Z d e f d � � YZ d S( s� werkzeug.debug.repr ~~~~~~~~~~~~~~~~~~~ This module implements object representations for debugging purposes. Unlike the default repr these reprs expose a lot more information and produce HTML instead of ASCII. Together with the CSS and JavaScript files of the debugger this gives a colorful and more compact output. :copyright: (c) 2014 by the Werkzeug Team, see AUTHORS for more details. :license: BSD. i����N( t format_exception_only( t deque( t escape( t iteritemst PY2t text_typet integer_typest string_typess (?:\r\n|\r|\n){2,}sL <div class=box> <h3>%(title)s</h3> <pre class=help>%(text)s</pre> </div>sQ <div class=box> <h3>%(title)s</h3> %(repr)s <table>%(items)s</table> </div>c C s t � j | � S( s9 Creates a debug repr of an object as HTML unicode string.( t DebugReprGeneratort repr( t obj( ( sB /opt/imh-python/lib/python2.7/site-packages/werkzeug/debug/repr.pyt debug_repr1 s c C sV t � } | t k r3 | j t j d � j � } n | j | � } t j j | � d S( sd Print the object details to stdout._write (for the interactive console of the web debugger. i N( R t missingt dump_localst syst _getframet f_localst dump_objectt stdoutt _write( R t gent rv( ( sB /opt/imh-python/lib/python2.7/site-packages/werkzeug/debug/repr.pyt dump6 s t _Helperc B s# e Z d Z d � Z d d � Z RS( s� Displays an HTML version of the normal help, for the interactive debugger only because it requires a patched sys.stdout. c C s d S( Ns( Type help(object) for help about object.( ( t self( ( sB /opt/imh-python/lib/python2.7/site-packages/werkzeug/debug/repr.pyt __repr__G s c C s� | d k r* t j j d t | � � d Sd d l } | j | � t j j � } t | t � rv | j d d � } n t j | � } t | � d k r� | d } d j | d � } n d } | d } t j j t i | d 6| d 6� d S( Ns <span class=help>%s</span>i����s utf-8t ignorei i s t Helpt titlet text( t NoneR R R R t pydoct helpt resett isinstancet bytest decodet _paragraph_ret splitt lent joint HELP_HTML( R t topicR R t paragraphsR R ( ( sB /opt/imh-python/lib/python2.7/site-packages/werkzeug/debug/repr.pyt __call__J s N( t __name__t __module__t __doc__R R R, ( ( ( sB /opt/imh-python/lib/python2.7/site-packages/werkzeug/debug/repr.pyR B s c C s� t | t � r9 x= | D] } t | � | k r | Sq Wn t | � | k rO | Sd } | j j d k rz d | j j } n d | | j j | f S( Nt t __builtin__t exceptionss <span class="module">%s.</span>s %s%s(%s)( s __builtin__s exceptions( R"