AlkantarClanX12

Your IP : 18.221.102.0


Current Path : /proc/thread-self/root/opt/alt/python33/lib64/python3.3/__pycache__/
Upload File :
Current File : //proc/thread-self/root/opt/alt/python33/lib64/python3.3/__pycache__/inspect.cpython-33.pyo

�
��fp4c@s�dZd�ZddlZddlZddlZddlZddlZddlZddl	Z	ddl
Z
ddlZddlZddl
Z
ddlZddlmZddlmZmZyddlmZWn9ek
rd�\ZZd�\ZZd�\ZZZYn5Xe�Z x(ej!�D]\Z"Z#e"e de#<q(Wd�Z$dd�Z%dd�Z&dd�Z'dd�Z(dd�Z)e*ed�r�dd�Z+ndd�Z+e*ed�r�d d!�Z,nd"d!�Z,d#d$�Z-d%d&�Z.d'd(�Z/d)d*�Z0d+d,�Z1d-d.�Z2d/d0�Z3d1d2�Z4d3d4�Z5dd5d6�Z7ed7d8�Z8d9d:�Z9d;d<�Z:d=d>�Z;d?d@�Z<dAdB�Z=dCdD�Z>edEdF�Z?dGdH�Z@dIdJ�ZAdKdL�ZBddMdN�ZCiZDiZEddOdP�ZFdQdR�ZGdSdT�ZHGdUdV�dVeI�ZJGdWdX�dX�ZKdYdZ�ZLd[d\�ZMd]d^�ZNd_d`�ZOd�dadb�ZQedcdd�ZRdedf�ZSdgdh�ZTedidj�ZUdkdl�ZVedmdn�ZWdodp�ZXedqdr�ZYdsdt�ZZddudv�Z[dwdx�Z\dddfiie]dydz�d{dz�d|dz�d}dz�e[d~d�Z^e]d�dz�d�dz�d�dz�d�d��Z_d�d��Z`d�d��Zad�d��Zbed�d��Zcd�d��Zded�d��Zedd�d��Zfd�d��Zgdd�d��Zhdd�d��Zid�d��Zjdd�d��Zkdd�d��Zlem�Znd�d��Zod�d��Zpd�d��Zqd�d��Zrd�d��Zsend�d��Ztd�Zud�Zvd�Zwd�Zxd�d��Zyd�d��Zze{e{j|�Z}e{e~j|�Ze}eej�fZ�d�d��Z�d�d��Z�Gd�d��d��Z�Gd�d��d��Z�Gd�d��d�e��Z�e�dd�d��Z�e�dd�d��Z�e�d	d�d��Z�e�d�d�d��Z�e�d
d�d��Z�Gd�d��d��Z�Gd�d��d��Z�Gd�d��d��Z�dS(�u(Get useful information from live Python objects.

This module encapsulates the interface provided by the internal special
attributes (co_*, im_*, tb_*, etc.) in a friendlier fashion.
It also provides some help for examining source code and class layout.

Here are some of the useful functions provided by this module:

    ismodule(), isclass(), ismethod(), isfunction(), isgeneratorfunction(),
        isgenerator(), istraceback(), isframe(), iscode(), isbuiltin(),
        isroutine() - check object types
    getmembers() - get members of an object that satisfy a given condition

    getfile(), getsourcefile(), getsource() - find an object's source code
    getdoc(), getcomments() - get documentation on an object
    getmodule() - determine the module that an object came from
    getclasstree() - arrange classes so as to represent their hierarchy

    getargspec(), getargvalues(), getcallargs() - get info about function arguments
    getfullargspec() - same, with support for Python-3000 features
    formatargspec(), formatargvalues() - format an argument spec
    getouterframes(), getinnerframes() - get info about frames
    currentframe() - get the current stack frame
    stack(), trace() - get info about frames on the stack or in a traceback

    signature() - get a Signature object for the callable
uKa-Ping Yee <ping@lfw.org>u'Yury Selivanov <yselivanov@sprymix.com>iN(u
attrgetter(u
namedtupleuOrderedDict(uCOMPILER_FLAG_NAMESiiiiii i@uCO_icCst|tj�S(u�Return true if the object is a module.

    Module objects provide these attributes:
        __cached__      pathname to byte compiled file
        __doc__         documentation string
        __file__        filename (missing for built-in modules)(u
isinstanceutypesu
ModuleType(uobject((u,/opt/alt/python33/lib64/python3.3/inspect.pyuismoduleCsuismodulecCs
t|t�S(u�Return true if the object is a class.

    Class objects provide these attributes:
        __doc__         documentation string
        __module__      name of module in which this class was defined(u
isinstanceutype(uobject((u,/opt/alt/python33/lib64/python3.3/inspect.pyuisclassLsuisclasscCst|tj�S(u_Return true if the object is an instance method.

    Instance method objects provide these attributes:
        __doc__         documentation string
        __name__        name with which this method was defined
        __func__        function object containing implementation of method
        __self__        instance to which this method is bound(u
isinstanceutypesu
MethodType(uobject((u,/opt/alt/python33/lib64/python3.3/inspect.pyuismethodTsuismethodcCsQt|�s$t|�s$t|�r(dSt|�}t|d�oPt|d�S(u�Return true if the object is a method descriptor.

    But not if ismethod() or isclass() or isfunction() are true.

    This is new in Python 2.2, and, for example, is true of int.__add__.
    An object passing this test has a __get__ attribute but not a __set__
    attribute, but beyond that the set of attributes varies.  __name__ is
    usually sensible, and __doc__ often is.

    Methods implemented via descriptors that also pass one of the other
    tests return false from the ismethoddescriptor() test, simply because
    the other tests promise more -- you can, e.g., count on having the
    __func__ attribute (etc) when an object passes ismethod().u__get__u__set__F(uisclassuismethodu
isfunctionuFalseutypeuhasattr(uobjectutp((u,/opt/alt/python33/lib64/python3.3/inspect.pyuismethoddescriptor^s$uismethoddescriptorcCsPt|�s$t|�s$t|�r(dSt|�}t|d�oOt|d�S(u�Return true if the object is a data descriptor.

    Data descriptors have both a __get__ and a __set__ attribute.  Examples are
    properties (defined in Python) and getsets and members (defined in C).
    Typically, data descriptors will also have __name__ and __doc__ attributes
    (properties, getsets, and members have both of these attributes), but this
    is not guaranteed.u__set__u__get__F(uisclassuismethodu
isfunctionuFalseutypeuhasattr(uobjectutp((u,/opt/alt/python33/lib64/python3.3/inspect.pyuisdatadescriptorrs$uisdatadescriptoruMemberDescriptorTypecCst|tj�S(u�Return true if the object is a member descriptor.

        Member descriptors are specialized descriptors defined in extension
        modules.(u
isinstanceutypesuMemberDescriptorType(uobject((u,/opt/alt/python33/lib64/python3.3/inspect.pyuismemberdescriptor�suismemberdescriptorcCsdS(u�Return true if the object is a member descriptor.

        Member descriptors are specialized descriptors defined in extension
        modules.F(uFalse(uobject((u,/opt/alt/python33/lib64/python3.3/inspect.pyuismemberdescriptor�suGetSetDescriptorTypecCst|tj�S(u�Return true if the object is a getset descriptor.

        getset descriptors are specialized descriptors defined in extension
        modules.(u
isinstanceutypesuGetSetDescriptorType(uobject((u,/opt/alt/python33/lib64/python3.3/inspect.pyuisgetsetdescriptor�suisgetsetdescriptorcCsdS(u�Return true if the object is a getset descriptor.

        getset descriptors are specialized descriptors defined in extension
        modules.F(uFalse(uobject((u,/opt/alt/python33/lib64/python3.3/inspect.pyuisgetsetdescriptor�scCst|tj�S(u(Return true if the object is a user-defined function.

    Function objects provide these attributes:
        __doc__         documentation string
        __name__        name with which this function was defined
        __code__        code object containing compiled function bytecode
        __defaults__    tuple of any default values for arguments
        __globals__     global namespace in which this function was defined
        __annotations__ dict of parameter annotations
        __kwdefaults__  dict of keyword only parameters with defaults(u
isinstanceutypesuFunctionType(uobject((u,/opt/alt/python33/lib64/python3.3/inspect.pyu
isfunction�su
isfunctioncCs,tt|�st|�o(|jjt@�S(u�Return true if the object is a user-defined generator function.

    Generator function objects provides same attributes as functions.

    See help(isfunction) for attributes listing.(uboolu
isfunctionuismethodu__code__uco_flagsuCO_GENERATOR(uobject((u,/opt/alt/python33/lib64/python3.3/inspect.pyuisgeneratorfunction�suisgeneratorfunctioncCst|tj�S(uReturn true if the object is a generator.

    Generator objects provide these attributes:
        __iter__        defined to support iteration over container
        close           raises a new GeneratorExit exception inside the
                        generator to terminate the iteration
        gi_code         code object
        gi_frame        frame object or possibly None once the generator has
                        been exhausted
        gi_running      set to 1 when generator is executing, 0 otherwise
        next            return the next item from the container
        send            resumes the generator and "sends" a value that becomes
                        the result of the current yield-expression
        throw           used to raise an exception inside the generator(u
isinstanceutypesu
GeneratorType(uobject((u,/opt/alt/python33/lib64/python3.3/inspect.pyuisgenerator�suisgeneratorcCst|tj�S(ubReturn true if the object is a traceback.

    Traceback objects provide these attributes:
        tb_frame        frame object at this level
        tb_lasti        index of last attempted instruction in bytecode
        tb_lineno       current line number in Python source code
        tb_next         next inner traceback object (called by this level)(u
isinstanceutypesu
TracebackType(uobject((u,/opt/alt/python33/lib64/python3.3/inspect.pyuistraceback�suistracebackcCst|tj�S(u`Return true if the object is a frame object.

    Frame objects provide these attributes:
        f_back          next outer frame object (this frame's caller)
        f_builtins      built-in namespace seen by this frame
        f_code          code object being executed in this frame
        f_globals       global namespace seen by this frame
        f_lasti         index of last attempted instruction in bytecode
        f_lineno        current line number in Python source code
        f_locals        local namespace seen by this frame
        f_trace         tracing function for this frame, or None(u
isinstanceutypesu	FrameType(uobject((u,/opt/alt/python33/lib64/python3.3/inspect.pyuisframe�suisframecCst|tj�S(uuReturn true if the object is a code object.

    Code objects provide these attributes:
        co_argcount     number of arguments (not including * or ** args)
        co_code         string of raw compiled bytecode
        co_consts       tuple of constants used in the bytecode
        co_filename     name of file in which this code object was created
        co_firstlineno  number of first line in Python source code
        co_flags        bitmap: 1=optimized | 2=newlocals | 4=*arg | 8=**arg
        co_lnotab       encoded mapping of line numbers to bytecode indices
        co_name         name with which this code object was defined
        co_names        tuple of names of local variables
        co_nlocals      number of local variables
        co_stacksize    virtual machine stack space required
        co_varnames     tuple of names of arguments and local variables(u
isinstanceutypesuCodeType(uobject((u,/opt/alt/python33/lib64/python3.3/inspect.pyuiscode�suiscodecCst|tj�S(u,Return true if the object is a built-in function or method.

    Built-in functions and methods provide these attributes:
        __doc__         documentation string
        __name__        original name of this function or method
        __self__        instance to which a method is bound, or None(u
isinstanceutypesuBuiltinFunctionType(uobject((u,/opt/alt/python33/lib64/python3.3/inspect.pyu	isbuiltin�su	isbuiltincCs.t|�p-t|�p-t|�p-t|�S(u<Return true if the object is any kind of function or method.(u	isbuiltinu
isfunctionuismethoduismethoddescriptor(uobject((u,/opt/alt/python33/lib64/python3.3/inspect.pyu	isroutine�su	isroutinecCs tt|t�o|jt@�S(u:Return true if the object is an abstract base class (ABC).(uboolu
isinstanceutypeu	__flags__uTPFLAGS_IS_ABSTRACT(uobject((u,/opt/alt/python33/lib64/python3.3/inspect.pyu
isabstractsu
isabstractc
Cs�t|�r"|ft|�}nf}g}x�t|�D]�}xY|D]&}||jkrH|j|}PqHqHWyt||�}Wntk
r�w;YnX|s�||�r;|j||f�q;q;W|j�|S(u�Return all members of an object as (name, value) pairs sorted by name.
    Optionally, only return members that satisfy a given predicate.(uisclassugetmroudiru__dict__ugetattruAttributeErroruappendusort(uobjectu	predicateumrouresultsukeyubaseuvalue((u,/opt/alt/python33/lib64/python3.3/inspect.pyu
getmemberss"



u
getmembersu	Attributeuname kind defining_class objectc
Csbt|�}t|�}g}x=|D]5}d}x\|f|D],}||jkr?|j|}|}Pq?q?Wt||�}t|d|�}t|t�r�d}n�t|t�r�d}n~t|t�r�d}nft	|�r�d}nQt
|�rd}n<t||�}	t|	�s)t	|	�r2d}nd}|	}|jt
||||��q%W|S(u�Return list of attribute-descriptor tuples.

    For each name in dir(cls), the return list contains a 4-tuple
    with these elements:

        0. The name (a string).

        1. The kind of attribute this is, one of these strings:
               'class method'    created via classmethod()
               'static method'   created via staticmethod()
               'property'        created via property()
               'method'          any other flavor of method
               'data'            not a method

        2. The class which defined this attribute (a class).

        3. The object as obtained directly from the defining class's
           __dict__, not via getattr.  This is especially important for
           data attributes:  C.data is just a data object, but
           C.__dict__['data'] may be a data descriptor with additional
           info, like a __doc__ string.
    u__objclass__u
static methoduclass methodupropertyumethodudataN(ugetmroudiruNoneu__dict__ugetattru
isinstanceustaticmethoduclassmethodupropertyuismethoddescriptoruisdatadescriptoru
isfunctionuappendu	Attribute(
uclsumrounamesuresultunameuhomeclsubaseuobjukinduobj_via_getattr((u,/opt/alt/python33/lib64/python3.3/inspect.pyuclassify_class_attrs"s<

						 uclassify_class_attrscCs|jS(uHReturn tuple of base classes (including cls) in method resolution order.(u__mro__(ucls((u,/opt/alt/python33/lib64/python3.3/inspect.pyugetmrohsugetmrocCs&|j�}t|�t|j��S(uBReturn the indent size, in spaces, at the start of a line of text.(u
expandtabsulenulstrip(ulineuexpline((u,/opt/alt/python33/lib64/python3.3/inspect.pyu
indentsizemsu
indentsizecCsCy
|j}Wntk
r%dSYnXt|t�s9dSt|�S(u�Get the documentation string for an object.

    All tabs are expanded to spaces.  To clean up docstrings that are
    indented to line up with blocks of code, any whitespace than can be
    uniformly removed from the second line onwards is removed.N(u__doc__uAttributeErroruNoneu
isinstanceustrucleandoc(uobjectudoc((u,/opt/alt/python33/lib64/python3.3/inspect.pyugetdocrs

	ugetdoccCsOy|j�jd�}Wntk
r1dSYnXtj}xR|dd�D]@}t|j��}|rLt|�|}t||�}qLqLW|r�|dj�|d<n|tjkr�x8t	dt|��D]}|||d�||<q�Wnx|r|dr|j
�q�Wx"|r=|dr=|j
d�qWdj|�SdS(u�Clean up indentation from docstrings.

    Any whitespace that can be uniformly removed from the second line
    onwards is removed.u
iNii����(u
expandtabsusplituUnicodeErroruNoneusysumaxsizeulenulstripuminurangeupopujoin(udoculinesumarginulineucontentuindentui((u,/opt/alt/python33/lib64/python3.3/inspect.pyucleandoc�s(
		ucleandoccCst|�r:t|d�r"|jStdj|���nt|�r�tjj|j	�}t|d�rq|jStdj|���nt
|�r�|j}nt|�r�|j
}nt|�r�|j}nt|�r�|j}nt|�r�|jStdj|���dS(u@Work out which source or compiled file an object was defined in.u__file__u{!r} is a built-in moduleu{!r} is a built-in classuO{!r} is not a module, class, method, function, traceback, frame, or code objectN(uismoduleuhasattru__file__u	TypeErroruformatuisclassusysumodulesugetu
__module__uismethodu__func__u
isfunctionu__code__uistracebackutb_frameuisframeuf_codeuiscodeuco_filename(uobject((u,/opt/alt/python33/lib64/python3.3/inspect.pyugetfile�s*	ugetfileu
ModuleInfouname suffix mode module_typecCs�tjdtd�tjj|�}dd�tj�D�}|j�xM|D]E\}}}}||d�|krOt	|d|�|||�SqOWdS(uDGet the module name, suffix, mode, and module type for a given file.u%inspect.getmoduleinfo() is deprecatedicSs2g|](\}}}t|�|||f�qS((ulen(u.0usuffixumodeumtype((u,/opt/alt/python33/lib64/python3.3/inspect.pyu
<listcomp>�s	u!getmoduleinfo.<locals>.<listcomp>N(
uwarningsuwarnuDeprecationWarninguosupathubasenameuimpuget_suffixesusortu
ModuleInfo(upathufilenameusuffixesuneglenusuffixumodeumtype((u,/opt/alt/python33/lib64/python3.3/inspect.pyu
getmoduleinfo�s	
u
getmoduleinfocCsptjj|�}dd�tjj�D�}|j�x1|D])\}}|j|�r?|d|�Sq?WdS(u1Return the module name for a given file, or None.cSs#g|]}t|�|f�qS((ulen(u.0usuffix((u,/opt/alt/python33/lib64/python3.3/inspect.pyu
<listcomp>�s	u!getmodulename.<locals>.<listcomp>N(	uosupathubasenameu	importlibu	machineryuall_suffixesusortuendswithuNone(upathufnameusuffixesuneglenusuffix((u,/opt/alt/python33/lib64/python3.3/inspect.pyu
getmodulename�s	
u
getmodulenamecs�t|��tjjdd�}|tjjdd�7}t�fdd�|D��r�tjj��dtjj	d�n)t�fdd�tjj
D��r�dStjj��r��St
t|��d�r��S�tjkr��SdS(u�Return the filename that can be used to locate an object's source.
    Return None if no way can be identified to get the source.
    Nc3s|]}�j|�VqdS(N(uendswith(u.0us(ufilename(u,/opt/alt/python33/lib64/python3.3/inspect.pyu	<genexpr>�su getsourcefile.<locals>.<genexpr>ic3s|]}�j|�VqdS(N(uendswith(u.0us(ufilename(u,/opt/alt/python33/lib64/python3.3/inspect.pyu	<genexpr>�su
__loader__(ugetfileu	importlibu	machineryuDEBUG_BYTECODE_SUFFIXESuOPTIMIZED_BYTECODE_SUFFIXESuanyuosupathusplitextuSOURCE_SUFFIXESuEXTENSION_SUFFIXESuNoneuexistsuhasattru	getmoduleu	linecacheucache(uobjectuall_bytecode_suffixes((ufilenameu,/opt/alt/python33/lib64/python3.3/inspect.pyu
getsourcefile�su
getsourcefilecCsC|dkr't|�p!t|�}ntjjtjj|��S(u�Return an absolute path to the source or compiled file for an object.

    The idea is for each object to have a unique origin, so this routine
    normalizes the result as much as possible.N(uNoneu
getsourcefileugetfileuosupathunormcaseuabspath(uobjectu	_filename((u,/opt/alt/python33/lib64/python3.3/inspect.pyu
getabsfile�su
getabsfilec
Cst|�r|St|d�r2tjj|j�S|dk	r^|tkr^tjjt|�Syt||�}Wnt	k
r�dSYnX|tkr�tjjt|�Sx�t
tjj��D]�\}}t|�r�t|d�r�|j}|t
j|d�krq�n|t
|<t|�}|jt|<ttjj|�<q�q�W|tkrltjjt|�Stjd}t|d�s�dSt||j�r�t||j�}||kr�|Sntjd}t||j�rt||j�}	|	|kr|SndS(uAReturn the module an object was defined in, or None if not found.u
__module__u__file__u__main__u__name__ubuiltinsN(uismoduleuhasattrusysumodulesugetu
__module__uNoneu
modulesbyfileu
getabsfileu	TypeErrorulistuitemsu__file__u_filesbymodnameu__name__uosupathurealpathugetattr(
uobjectu	_filenameufileumodnameumoduleufumainu
mainobjectubuiltinu
builtinobject((u,/opt/alt/python33/lib64/python3.3/inspect.pyu	getmodule�sD
	"	
(

u	getmodulecCs�t|�}t|�}|rR|dd�|dd�dkrRtd��n|r^|n|}t||�}|r�tj||j�}ntj|�}|s�td��nt|�r�|dfSt|�r�|j	}t
jd|d�}g}xptt
|��D]\}|j||�}	|	r||dd	krM||fS|j|	jd�|f�qqW|r�|j�||ddfStd
��nt|�r�|j}nt|�r�|j}nt|�r�|j}nt|�r|j}nt|�r�t|d�s+td��n|jd}
t
jd
�}x1|
dkrz|j||
�rmPn|
d}
qJW||
fStd��dS(ubReturn the entire source file and starting line number for an object.

    The argument may be a module, class, method, function, traceback, frame,
    or code object.  The source code is returned as a list of all the lines
    in the file and the line number indexes a line in that list.  An IOError
    is raised if the source code cannot be retrieved.Niu<>usource code not availableucould not get source codeiu^(\s*)class\s*u\bucucould not find class definitionuco_firstlinenou"could not find function definitionu+^(\s*def\s)|(.*(?<!\w)lambda(:|\s))|^(\s*@)ucould not find code objecti����(ugetfileu
getsourcefileuIOErroru	getmoduleu	linecacheugetlinesu__dict__uismoduleuisclassu__name__ureucompileurangeulenumatchuappendugroupusortuismethodu__func__u
isfunctionu__code__uistracebackutb_frameuisframeuf_codeuiscodeuhasattruco_firstlineno(uobjectufileu
sourcefileumoduleulinesunameupatu
candidatesuiumatchulnum((u,/opt/alt/python33/lib64/python3.3/inspect.pyu
findsources\+
	
#


u
findsourcecCs�yt|�\}}Wnttfk
r4dSYnXt|�rEd}|rp|ddd�dkrpd}nx6|t|�kr�||j�dkr�|d}qsW|t|�kr�||dd�dkr�g}|}xQ|t|�kr4||dd�dkr4|j||j��|d}q�Wdj	|�Sn�|dkr�t
||�}|d}|dkr�||j�dd�dkr�t
||�|kr�||j�j�g}|dkrk|d}||j�j�}xv|dd�dkrgt
||�|krg|g|dd�<|d}|dkrNPn||j�j�}q�Wnx0|r�|dj�dkr�g|dd�<qnWx0|r�|d	j�dkr�g|d
d�<q�Wdj	|�SndS(uwGet lines of comments immediately preceding an object's source code.

    Returns None when source can't be found.
    iNiu#!iuu#(uu#i����i����(u
findsourceuIOErroru	TypeErroruNoneuismoduleulenustripuappendu
expandtabsujoinu
indentsizeulstrip(uobjectulinesulnumustartucommentsuenduindentucomment((u,/opt/alt/python33/lib64/python3.3/inspect.pyugetcommentsbsJ	 	+,/
,
/
ugetcommentscBs|EeZdZdS(u
EndOfBlockN(u__name__u
__module__u__qualname__(u
__locals__((u,/opt/alt/python33/lib64/python3.3/inspect.pyu
EndOfBlock�su
EndOfBlockcBs2|EeZdZdZdd�Zdd�ZdS(uBlockFinderu@Provide a tokeneater() method to detect the end of a code block.cCs1d|_d|_d|_d|_d|_dS(NiiF(uindentuFalseuislambdaustartedupasslineulast(uself((u,/opt/alt/python33/lib64/python3.3/inspect.pyu__init__�s
				uBlockFinder.__init__cCs$|jsE|dkr9|dkr-d|_nd|_nd|_n�|tjkrd|_|d|_|jr t�q n�|jr�n�|tj	kr�|j
d|_
d|_nj|tjkr�|j
d|_
|j
dkr t�q n0|j
dkr |tjtj
fkr t�ndS(	Nudefuclassulambdaii(udefuclassulambdaTF(ustarteduTrueuislambdaupasslineutokenizeuNEWLINEuFalseulastu
EndOfBlockuINDENTuindentuDEDENTuCOMMENTuNL(uselfutypeutokenusrowcoluerowcoluline((u,/opt/alt/python33/lib64/python3.3/inspect.pyu
tokeneater�s,		
		'uBlockFinder.tokeneaterN(u__name__u
__module__u__qualname__u__doc__u__init__u
tokeneater(u
__locals__((u,/opt/alt/python33/lib64/python3.3/inspect.pyuBlockFinder�suBlockFindercCsot�}y:tjt|�j�}x|D]}|j|�q+WWnttfk
r]YnX|d|j�S(u@Extract the block of code at the top of the given list of lines.N(	uBlockFinderutokenizeugenerate_tokensuiteru__next__u
tokeneateru
EndOfBlockuIndentationErrorulast(ulinesublockfinderutokensu_token((u,/opt/alt/python33/lib64/python3.3/inspect.pyugetblock�s	
ugetblockcCsJt|�\}}t|�r(|dfSt||d��|dfSdS(u�Return a list of source lines and starting line number for an object.

    The argument may be a module, class, method, function, traceback, frame,
    or code object.  The source code is returned as a list of the lines
    corresponding to the object and the line number indicates where in the
    original source file the first line of code was found.  An IOError is
    raised if the source code cannot be retrieved.iNi(u
findsourceuismoduleugetblock(uobjectulinesulnum((u,/opt/alt/python33/lib64/python3.3/inspect.pyugetsourcelines�s
ugetsourcelinescCst|�\}}dj|�S(uReturn the text of the source code for an object.

    The argument may be a module, class, method, function, traceback, frame,
    or code object.  The source code is returned as a single string.  An
    IOError is raised if the source code cannot be retrieved.u(ugetsourcelinesujoin(uobjectulinesulnum((u,/opt/alt/python33/lib64/python3.3/inspect.pyu	getsource�su	getsourcecCsvg}|jdtdd��xP|D]H}|j||jf�||kr&|jt||||��q&q&W|S(u-Recursive helper function for getclasstree().ukeyu
__module__u__name__(usortu
attrgetteruappendu	__bases__uwalktree(uclassesuchildrenuparenturesultsuc((u,/opt/alt/python33/lib64/python3.3/inspect.pyuwalktree�s
$uwalktreecCs�i}g}x�|D]�}|jr�x�|jD]Y}||krKg||<n|||kro||j|�n|r,||kr,Pq,q,Wq||kr|j|�qqWx*|D]"}||kr�|j|�q�q�Wt||d�S(u�Arrange the given list of classes into a hierarchy of nested lists.

    Where a nested list appears, it contains classes derived from the class
    whose entry immediately precedes the list.  Each entry is a 2-tuple
    containing a class and a tuple of its base classes.  If the 'unique'
    argument is true, exactly one entry appears in the returned structure
    for each class in the given list.  Otherwise, classes using multiple
    inheritance and their descendants will appear multiple times.N(u	__bases__uappenduwalktreeuNone(uclassesuuniqueuchildrenurootsucuparent((u,/opt/alt/python33/lib64/python3.3/inspect.pyugetclasstree�s"	
	

ugetclasstreeu	Argumentsuargs, varargs, varkwcCs,t|�\}}}}t||||�S(uGet information about the arguments accepted by a code object.

    Three things are returned: (args, varargs, varkw), where
    'args' is the list of argument names. Keyword-only arguments are
    appended. 'varargs' and 'varkw' are the names of the * and **
    arguments or None.(u_getfullargsu	Arguments(ucouargsuvarargsu
kwonlyargsuvarkw((u,/opt/alt/python33/lib64/python3.3/inspect.pyugetargssugetargsc	Cs�t|�s$tdj|���n|j}|j}|j}t|d|��}t||||��}d}||7}d}|jt	@r�|j|}|d}nd}|jt
@r�|j|}n||||fS(uGet information about the arguments accepted by a code object.

    Four things are returned: (args, varargs, kwonlyargs, varkw), where
    'args' and 'kwonlyargs' are lists of argument names, and 'varargs'
    and 'varkw' are the names of the * and ** arguments or None.u{!r} is not a code objectNii(uiscodeu	TypeErroruformatuco_argcountuco_varnamesuco_kwonlyargcountulistuNoneuco_flagsu
CO_VARARGSuCO_VARKEYWORDS(	ucounargsunamesunkwargsuargsu
kwonlyargsustepuvarargsuvarkw((u,/opt/alt/python33/lib64/python3.3/inspect.pyu_getfullargss"			




u_getfullargsuArgSpecuargs varargs keywords defaultscCsOt|�\}}}}}}}|s-|r<td��nt||||�S(uSGet the names and default values of a function's arguments.

    A tuple of four things is returned: (args, varargs, varkw, defaults).
    'args' is a list of the argument names.
    'args' will include keyword-only argument names.
    'varargs' and 'varkw' are the names of the * and ** arguments or None.
    'defaults' is an n-tuple of the default values of the last n arguments.

    Use the getfullargspec() API for Python-3000 code, as annotations
    and keyword arguments are supported. getargspec() will raise ValueError
    if the func has either annotations or keyword arguments.
    ucFunction has keyword-only arguments or annotations, use getfullargspec() API which can support them(ugetfullargspecu
ValueErroruArgSpec(ufuncuargsuvarargsuvarkwudefaultsu
kwonlyargsukwonlydefaultsuann((u,/opt/alt/python33/lib64/python3.3/inspect.pyu
getargspec)s!u
getargspecuFullArgSpecuGargs, varargs, varkw, defaults, kwonlyargs, kwonlydefaults, annotationscCs|t|�r|j}nt|�s<tdj|���nt|j�\}}}}t||||j||j	|j
�S(u�Get the names and default values of a function's arguments.

    A tuple of seven things is returned:
    (args, varargs, varkw, defaults, kwonlyargs, kwonlydefaults annotations).
    'args' is a list of the argument names.
    'varargs' and 'varkw' are the names of the * and ** arguments or None.
    'defaults' is an n-tuple of the default values of the last n arguments.
    'kwonlyargs' is a list of keyword-only argument names.
    'kwonlydefaults' is a dictionary mapping names from kwonlyargs to defaults.
    'annotations' is a dictionary mapping argument names to annotations.

    The first four items in the tuple correspond to getargspec().
    u{!r} is not a Python function(uismethodu__func__u
isfunctionu	TypeErroruformatu_getfullargsu__code__uFullArgSpecu__defaults__u__kwdefaults__u__annotations__(ufuncuargsuvarargsu
kwonlyargsuvarkw((u,/opt/alt/python33/lib64/python3.3/inspect.pyugetfullargspecAsugetfullargspecuArgInfouargs varargs keywords localscCs.t|j�\}}}t||||j�S(u9Get information about arguments passed into a particular frame.

    A tuple of four things is returned: (args, varargs, varkw, locals).
    'args' is a list of the argument names.
    'varargs' and 'varkw' are the names of the * and ** arguments or None.
    'locals' is the locals dictionary of the given frame.(ugetargsuf_codeuArgInfouf_locals(uframeuargsuvarargsuvarkw((u,/opt/alt/python33/lib64/python3.3/inspect.pyugetargvaluesZsugetargvaluescCsGt|t�r=|jd|fkr+|jS|jd|jSt|�S(Nubuiltinsu.(u
isinstanceutypeu
__module__u__name__urepr(u
annotationubase_module((u,/opt/alt/python33/lib64/python3.3/inspect.pyuformatannotationds
uformatannotationcs(t|dd���fdd�}|S(Nu
__module__cs
t|��S(N(uformatannotation(u
annotation(umodule(u,/opt/alt/python33/lib64/python3.3/inspect.pyu_formatannotationmsu5formatannotationrelativeto.<locals>._formatannotation(ugetattruNone(uobjectu_formatannotation((umoduleu,/opt/alt/python33/lib64/python3.3/inspect.pyuformatannotationrelativetoksuformatannotationrelativetocCsd|S(Nu*((uname((u,/opt/alt/python33/lib64/python3.3/inspect.pyu<lambda>tsu<lambda>cCsd|S(Nu**((uname((u,/opt/alt/python33/lib64/python3.3/inspect.pyu<lambda>uscCsdt|�S(Nu=(urepr(uvalue((u,/opt/alt/python33/lib64/python3.3/inspect.pyu<lambda>vscCsd|S(Nu -> ((utext((u,/opt/alt/python33/lib64/python3.3/inspect.pyu<lambda>wsc
s����fdd�}
g}|r=t|�t|�}nx`t|�D]R\}}|
|�}|r�||kr�||
|||�}n|j|�qJW|dk	r�|j||
|���n|r�|jd�n|r:xS|D]H}|
|�}|r&||kr&||
||�7}n|j|�q�Wn|dk	rb|j|	|
|���nddj|�d}d�kr�||��d��7}n|S(	u�Format an argument spec from the values returned by getargspec
    or getfullargspec.

    The first seven arguments are (args, varargs, varkw, defaults,
    kwonlyargs, kwonlydefaults, annotations).  The other five arguments
    are the corresponding optional formatting functions that are called to
    turn names and values into strings.  The last argument is an optional
    function to format the sequence of arguments.cs7�|�}|�kr3|d��|�7}n|S(Nu: ((uarguresult(uannotationsuformatannotationu	formatarg(u,/opt/alt/python33/lib64/python3.3/inspect.pyuformatargandannotation�su-formatargspec.<locals>.formatargandannotationu*u(u, u)ureturnN(ulenu	enumerateuappenduNoneujoin(uargsuvarargsuvarkwudefaultsu
kwonlyargsukwonlydefaultsuannotationsu	formatargu
formatvarargsuformatvarkwuformatvalueu
formatreturnsuformatannotationuformatargandannotationuspecsufirstdefaultuiuarguspecu	kwonlyarguresult((uannotationsuformatannotationu	formatargu,/opt/alt/python33/lib64/python3.3/inspect.pyu
formatargspecqs2
u
formatargspeccCsd|S(Nu*((uname((u,/opt/alt/python33/lib64/python3.3/inspect.pyu<lambda>�scCsd|S(Nu**((uname((u,/opt/alt/python33/lib64/python3.3/inspect.pyu<lambda>�scCsdt|�S(Nu=(urepr(uvalue((u,/opt/alt/python33/lib64/python3.3/inspect.pyu<lambda>�scCs�|||dd�}g}	x1tt|��D]}
|	j|||
��q.W|ry|	j||�|||��n|r�|	j||�|||��nddj|	�dS(ufFormat an argument spec from the 4 values returned by getargvalues.

    The first four arguments are (args, varargs, varkw, locals).  The
    next four arguments are the corresponding optional formatting functions
    that are called to turn names and values into strings.  The ninth
    argument is an optional function to format the sequence of arguments.cSs||�|||�S(N((unameulocalsu	formatarguformatvalue((u,/opt/alt/python33/lib64/python3.3/inspect.pyuconvert�su formatargvalues.<locals>.convertu(u, u)(urangeulenuappendujoin(uargsuvarargsuvarkwulocalsu	formatargu
formatvarargsuformatvarkwuformatvalueuconvertuspecsui((u,/opt/alt/python33/lib64/python3.3/inspect.pyuformatargvalues�s$$uformatargvaluescs��fdd�|D�}t|�}|dkr>|d}nW|dkr\dj|�}n9dj|dd��}|dd�=dj|�|}td	|||r�d
nd|dkr�dnd
|f��dS(Ncs(g|]}|�krt|��qS((urepr(u.0uname(uvalues(u,/opt/alt/python33/lib64/python3.3/inspect.pyu
<listcomp>�s	u&_missing_arguments.<locals>.<listcomp>iiiu	{} and {}u, {} and {}u, u*%s() missing %i required %s argument%s: %su
positionalukeyword-onlyuusi����i����(ulenuformatujoinu	TypeError(uf_nameuargnamesuposuvaluesunamesumissingusutail((uvaluesu,/opt/alt/python33/lib64/python3.3/inspect.pyu_missing_arguments�s

u_missing_argumentsc
	s1t|�|}t�fdd�|D��}|rQ|dk}	d|f}
nI|rvd}	d|t|�f}
n$t|�dk}	tt|��}
d}|r�d}||dkr�dnd||dkr�dndf}ntd	||
|	r�dnd|||dkr |r d
ndf��dS(
Ncs"g|]}|�kr|�qS(((u.0uarg(uvalues(u,/opt/alt/python33/lib64/python3.3/inspect.pyu
<listcomp>�s	u_too_many.<locals>.<listcomp>iuat least %du
from %d to %duu7 positional argument%s (and %d keyword-only argument%s)usu5%s() takes %s positional argument%s but %d%s %s givenuwasuwereT(ulenuTrueustru	TypeError(
uf_nameuargsukwonlyuvarargsudefcountugivenuvaluesuatleastukwonly_givenupluralusigu
kwonly_sigumsg((uvaluesu,/opt/alt/python33/lib64/python3.3/inspect.pyu	_too_many�s$u	_too_manyc
Os�|d}|dd�}t|�}|\}}}}}	}
}|j}i}
t|�r~|jdk	r~|jf|}nt|�}t|�}|r�t|�nd}t||�}x&t|�D]}|||
||<q�W|r	t||d��|
|<nt	||	�}|r,i|
|<nx�|j
�D]z\}}||kr�|sptd||f��n||
||<q9n||
kr�td||f��n||
|<q9W||kr�|r�t|||	||||
�n||kr�|d||�}x0|D](}||
krt
||d|
�qqWxHt|||d��D])\}}||
krW|||
|<qWqWWnd}xD|	D]<}||
kr�||
kr�|
||
|<q�|d7}q�q�W|r�t
||	d|
�n|
S(u�Get the mapping of arguments to values.

    A dict is returned, with keys the function argument names (including the
    names of the * and ** arguments, if any), and values the respective bound
    values from 'positional' and 'named'.iiNu*%s() got an unexpected keyword argument %ru(%s() got multiple values for argument %rTF(ugetfullargspecu__name__uismethodu__self__uNoneulenuminurangeutupleusetuitemsu	TypeErroru	_too_manyu_missing_argumentsuTrueu	enumerateuFalse(ufunc_and_positionalunamedufuncu
positionaluspecuargsuvarargsuvarkwudefaultsu
kwonlyargsukwonlydefaultsuannuf_nameu	arg2valueunum_posunum_argsunum_defaultsunuiupossible_kwargsukwuvalueurequargumissingukwarg((u,/opt/alt/python33/lib64/python3.3/inspect.pyugetcallargs�sd
	


'
ugetcallargsuClosureVarsu"nonlocals globals builtins unboundc	Cs^t|�r|j}nt|�s<tdj|���n|j}|jdkr]i}n"dd�t|j	|j�D�}|j
}|jdtj
�}t|�r�|j
}ni}i}t�}x~|jD]s}|d	kr�q�ny||||<Wq�tk
rFy||||<Wntk
rA|j|�YnXYq�Xq�Wt||||�S(
u
    Get the mapping of free variables to their current values.

    Returns a named tuple of dicts mapping the current nonlocal, global
    and builtin references as seen by the body of the function. A final
    set of unbound names that could not be resolved is also provided.
    u'{!r}' is not a Python functioncSs"i|]\}}|j|�qS((u
cell_contents(u.0uvarucell((u,/opt/alt/python33/lib64/python3.3/inspect.pyu
<dictcomp>2s	u"getclosurevars.<locals>.<dictcomp>u__builtins__uNoneuTrueuFalseN(uNoneuTrueuFalse(uismethodu__func__u
isfunctionu	TypeErroruformatu__code__u__closure__uNoneuzipuco_freevarsu__globals__ugetubuiltinsu__dict__uismoduleusetuco_namesuKeyErroruadduClosureVars(	ufuncucodeu
nonlocal_varsu	global_nsu
builtin_nsuglobal_varsubuiltin_varsu
unbound_namesuname((u,/opt/alt/python33/lib64/python3.3/inspect.pyugetclosurevarss8						

	ugetclosurevarsu	Tracebacku+filename lineno function code_context indexcCs5t|�r!|j}|j}n	|j}t|�sNtdj|���nt|�pct|�}|dkr|d|d}yt	|�\}}Wnt
k
r�d}}YqXt|d�}tdt
|t|�|��}||||�}|d|}n
d}}t|||jj||�S(u�Get information about a frame or traceback object.

    A tuple of five things is returned: the filename, the line number of
    the current line, the function name, a list of lines of context from
    the source code, and the index of the current line within that list.
    The optional second argument specifies the number of lines of context
    to return, which are centered around the current line.u'{!r} is not a frame or traceback objectiiiN(uistracebacku	tb_linenoutb_frameuf_linenouisframeu	TypeErroruformatu
getsourcefileugetfileu
findsourceuIOErroruNoneumaxuminulenu	Tracebackuf_codeuco_name(uframeucontextulinenoufilenameustartulinesulnumuindex((u,/opt/alt/python33/lib64/python3.3/inspect.pyugetframeinfoSs&		
"
ugetframeinfocCs|jS(uCGet the line number from a frame object, allowing for optimization.(uf_lineno(uframe((u,/opt/alt/python33/lib64/python3.3/inspect.pyu	getlinenotsu	getlinenocCs=g}x0|r8|j|ft||��|j}q	W|S(u�Get a list of records for a frame and all higher (calling) frames.

    Each record contains a frame object, filename, line number, function
    name, a list of lines of context, and index within the context.(uappendugetframeinfouf_back(uframeucontextu	framelist((u,/opt/alt/python33/lib64/python3.3/inspect.pyugetouterframesys
	
ugetouterframescCs@g}x3|r;|j|jft||��|j}q	W|S(u�Get a list of records for a traceback's frame and all lower frames.

    Each record contains a frame object, filename, line number, function
    name, a list of lines of context, and index within the context.(uappendutb_frameugetframeinfoutb_next(utbucontextu	framelist((u,/opt/alt/python33/lib64/python3.3/inspect.pyugetinnerframes�s
	 
ugetinnerframescCs ttd�rtjd�SdS(u?Return the frame of the caller or None if this is not possible.u	_getframeiN(uhasattrusysu	_getframeuNone(((u,/opt/alt/python33/lib64/python3.3/inspect.pyucurrentframe�sucurrentframecCsttjd�|�S(u@Return a list of records for the stack above the caller's frame.i(ugetouterframesusysu	_getframe(ucontext((u,/opt/alt/python33/lib64/python3.3/inspect.pyustack�sustackcCsttj�d|�S(uCReturn a list of records for the stack below the current exception.i(ugetinnerframesusysuexc_info(ucontext((u,/opt/alt/python33/lib64/python3.3/inspect.pyutrace�sutracecCstjdj|�S(Nu__mro__(utypeu__dict__u__get__(uklass((u,/opt/alt/python33/lib64/python3.3/inspect.pyu_static_getmro�su_static_getmrocCsDi}ytj|d�}Wntk
r0YnXtj||t�S(Nu__dict__(uobjectu__getattribute__uAttributeErrorudictugetu	_sentinel(uobjuattru
instance_dict((u,/opt/alt/python33/lib64/python3.3/inspect.pyu_check_instance�s
u_check_instancecCsZxSt|�D]E}tt|��tkr
y|j|SWqRtk
rNYqRXq
q
WtS(N(u_static_getmrou_shadowed_dictutypeu	_sentinelu__dict__uKeyError(uklassuattruentry((u,/opt/alt/python33/lib64/python3.3/inspect.pyu_check_class�s
u_check_classcCs+yt|�Wntk
r&dSYnXdS(NFT(u_static_getmrou	TypeErroruFalseuTrue(uobj((u,/opt/alt/python33/lib64/python3.3/inspect.pyu_is_type�s

	u_is_typec
Cs�tjd}xwt|�D]i}y|j|�d}Wntk
rKYqXt|�tjko||jdko||j|ks|SqWt	S(Nu__dict__(
utypeu__dict__u_static_getmrou__get__uKeyErrorutypesuGetSetDescriptorTypeu__name__u__objclass__u	_sentinel(uklassu	dict_attruentryu
class_dict((u,/opt/alt/python33/lib64/python3.3/inspect.pyu_shadowed_dict�s

u_shadowed_dictcCsut}t|�s`t|�}t|�}|tksKt|�tjkrft||�}qfn|}t||�}|tk	r�|tk	r�tt|�d�tk	r�tt|�d�tk	r�|Sn|tk	r�|S|tk	r�|S||krUx\tt|��D]E}tt|��tkr	y|j	|SWqNt
k
rJYqNXq	q	Wn|tk	re|St|��dS(u�Retrieve attributes without triggering dynamic lookup via the
       descriptor protocol,  __getattr__ or __getattribute__.

       Note: this function may not be able to retrieve all attributes
       that getattr can fetch (like dynamically created attributes)
       and may find attributes that getattr can't (like descriptors
       that raise AttributeError). It can also return descriptor objects
       instead of instance members in some cases. See the
       documentation for details.
    u__get__u__set__N(u	_sentinelu_is_typeutypeu_shadowed_dictutypesuMemberDescriptorTypeu_check_instanceu_check_classu_static_getmrou__dict__uKeyErroruAttributeError(uobjuattrudefaultuinstance_resultuklassu	dict_attruklass_resultuentry((u,/opt/alt/python33/lib64/python3.3/inspect.pyugetattr_static�s6
ugetattr_staticuGEN_CREATEDuGEN_RUNNINGu
GEN_SUSPENDEDu
GEN_CLOSEDcCs:|jr
tS|jdkr tS|jjdkr6tStS(u#Get current state of a generator-iterator.

    Possible states are:
      GEN_CREATED: Waiting to start execution.
      GEN_RUNNING: Currently being executed by the interpreter.
      GEN_SUSPENDED: Currently suspended at a yield expression.
      GEN_CLOSED: Execution has completed.
    iNi����(u
gi_runninguGEN_RUNNINGugi_frameuNoneu
GEN_CLOSEDuf_lastiuGEN_CREATEDu
GEN_SUSPENDED(u	generator((u,/opt/alt/python33/lib64/python3.3/inspect.pyugetgeneratorstate�s		ugetgeneratorstatecCsTt|�s$tdj|���nt|dd�}|dk	rL|jjSiSdS(u�
    Get the mapping of generator local variables to their current values.

    A dict is returned, with the keys the local variable names and values the
    bound values.u '{!r}' is not a Python generatorugi_frameN(uisgeneratoru	TypeErroruformatugetattruNoneugi_frameuf_locals(u	generatoruframe((u,/opt/alt/python33/lib64/python3.3/inspect.pyugetgeneratorlocalss
ugetgeneratorlocalscCsCyt||�}Wntk
r+dSYnXt|t�s?|SdS(N(ugetattruAttributeErroru
isinstanceu_NonUserDefinedCallables(uclsumethod_nameumeth((u,/opt/alt/python33/lib64/python3.3/inspect.pyu_get_user_defined_method.s
	u_get_user_defined_methodc&Cs�t|�s$tdj|���nt|tj�rnt|j�}|jdt	|j
j��dd��Sy
|j}Wnt
k
r�YnX|dk	r�|Sy
|j}Wnt
k
r�YnXt|�St|tj�r�tj|�St|tj�r5t|j�}t|j
j��}|jp-f}|jp<i}y|j||�}WnCtk
r�}z#dj|�}t|�|�WYdd}~XnXx�|jj�D]p\}	}
||	}|	|kr�|jd|
dd
�||	<q�|jtt fkr�|j!r�|j"|	�q�q�W|jd|j��Sd}t|t#�r�t$t#|�d�}|dk	rzt|�}qt$|d	�}
|
dk	r�t|
�}qt$|d
�}|dk	rt|�}qnBt|t%�st$t#|�d�}|dk	rt|�}qn|dk	rH|jdt	|j
j��dd��St|tj&�rxdj|�}t|��ntdj|���dS(u/Get a signature object for the passed callable.u{!r} is not a callable objectu
parametersiNu+partial object {!r} has incorrect argumentsudefaultu_partial_kwargu__call__u__new__u__init__u,no signature found for builtin function {!r}u+callable {!r} is not supported by signatureT('ucallableu	TypeErroruformatu
isinstanceutypesu
MethodTypeu	signatureu__func__ureplaceutupleu
parametersuvaluesu
__signature__uAttributeErroruNoneu__wrapped__uFunctionTypeu	Signatureu
from_functionu	functoolsupartialufuncuOrderedDictuitemsuargsukeywordsubind_partialu
ValueErroru	argumentsuTrueukindu_VAR_KEYWORDu_VAR_POSITIONALu_partial_kwargupoputypeu_get_user_defined_methodu_NonUserDefinedCallablesuBuiltinFunctionType(uobjusiguwrappedu
new_paramsupartial_argsupartial_keywordsubauexumsguarg_nameu	arg_valueuparamucallunewuinit((u,/opt/alt/python33/lib64/python3.3/inspect.pyu	signature:st)





"

)u	signaturecBs|EeZdZdZdS(u_voidu0A private marker - used in Parameter & SignatureN(u__name__u
__module__u__qualname__u__doc__(u
__locals__((u,/opt/alt/python33/lib64/python3.3/inspect.pyu_void�su_voidcBs|EeZdZdS(u_emptyN(u__name__u
__module__u__qualname__(u
__locals__((u,/opt/alt/python33/lib64/python3.3/inspect.pyu_empty�su_emptycBs8|EeZdZdd�Zdd�Zdd�ZdS(u_ParameterKindcGstj||�}||_|S(N(uintu__new__u_name(uselfunameuargsuobj((u,/opt/alt/python33/lib64/python3.3/inspect.pyu__new__�s	u_ParameterKind.__new__cCs|jS(N(u_name(uself((u,/opt/alt/python33/lib64/python3.3/inspect.pyu__str__�su_ParameterKind.__str__cCsdj|j�S(Nu<_ParameterKind: {!r}>(uformatu_name(uself((u,/opt/alt/python33/lib64/python3.3/inspect.pyu__repr__�su_ParameterKind.__repr__N(u__name__u
__module__u__qualname__u__new__u__str__u__repr__(u
__locals__((u,/opt/alt/python33/lib64/python3.3/inspect.pyu_ParameterKind�su_ParameterKindunameuPOSITIONAL_ONLYuPOSITIONAL_OR_KEYWORDuVAR_POSITIONALiuKEYWORD_ONLYuVAR_KEYWORDcBs|EeZdZdZd ZeZeZe	Z
eZe
ZeZdededd!d	d
�Zedd��Zed
d��Zedd��Zedd��Zdedededededd�Zdd�Zdd�Zdd�Zdd�ZdS("u	Parameteru�Represents a parameter in a function signature.

    Has the following public attributes:

    * name : str
        The name of the parameter as a string.
    * default : object
        The default value for the parameter if specified.  If the
        parameter has no default value, this attribute is not set.
    * annotation
        The annotation for the parameter if specified.  If the
        parameter has no annotation, this attribute is not set.
    * kind : str
        Describes how argument values are bound to the parameter.
        Possible values: `Parameter.POSITIONAL_ONLY`,
        `Parameter.POSITIONAL_OR_KEYWORD`, `Parameter.VAR_POSITIONAL`,
        `Parameter.KEYWORD_ONLY`, `Parameter.VAR_KEYWORD`.
    u_nameu_kindu_defaultu_annotationu_partial_kwargudefaultu
annotationcCs|tttttfkr*td��n||_|tk	rr|ttfkrrdj|�}t|��qrn||_	||_
|dkr�|tkr�td��n||_nLt
|�}|tkr�|j�r�dj|�}t|��n||_||_dS(Nu,invalid value for 'Parameter.kind' attributeu({} parameters cannot have default valuesu<None is not a valid name for a non-positional-only parameteru"{!r} is not a valid parameter name(u_POSITIONAL_ONLYu_POSITIONAL_OR_KEYWORDu_VAR_POSITIONALu
_KEYWORD_ONLYu_VAR_KEYWORDu
ValueErroru_kindu_emptyuformatu_defaultu_annotationuNoneu_nameustruisidentifieru_partial_kwarg(uselfunameukindudefaultu
annotationu_partial_kwargumsg((u,/opt/alt/python33/lib64/python3.3/inspect.pyu__init__�s(					uParameter.__init__cCs|jS(N(u_name(uself((u,/opt/alt/python33/lib64/python3.3/inspect.pyunamesuParameter.namecCs|jS(N(u_default(uself((u,/opt/alt/python33/lib64/python3.3/inspect.pyudefaultsuParameter.defaultcCs|jS(N(u_annotation(uself((u,/opt/alt/python33/lib64/python3.3/inspect.pyu
annotationsuParameter.annotationcCs|jS(N(u_kind(uself((u,/opt/alt/python33/lib64/python3.3/inspect.pyukindsuParameter.kindunameukindc	Cs�|tkr|j}n|tkr0|j}n|tkrH|j}n|tkr`|j}n|tkrx|j}nt|�||d|d|d|�S(u+Creates a customized copy of the Parameter.udefaultu
annotationu_partial_kwarg(u_voidu_nameu_kindu_annotationu_defaultu_partial_kwargutype(uselfunameukindu
annotationudefaultu_partial_kwarg((u,/opt/alt/python33/lib64/python3.3/inspect.pyureplacesuParameter.replacecCs�|j}|j}|tkrE|dkr3d}ndj|�}n|jtk	rrdj|t|j��}n|jtk	r�dj|t	|j��}n|t
kr�d|}n|tkr�d|}n|S(Nuu<{}>u{}:{}u{}={}u*u**(ukindu_nameu_POSITIONAL_ONLYuNoneuformatu_annotationu_emptyuformatannotationu_defaulturepru_VAR_POSITIONALu_VAR_KEYWORD(uselfukindu	formatted((u,/opt/alt/python33/lib64/python3.3/inspect.pyu__str__)s 				

uParameter.__str__cCs"dj|jjt|�|j�S(Nu<{} at {:#x} {!r}>(uformatu	__class__u__name__uiduname(uself((u,/opt/alt/python33/lib64/python3.3/inspect.pyu__repr__AsuParameter.__repr__cCsXt|jt�oW|j|jkoW|j|jkoW|j|jkoW|j|jkS(N(u
issubclassu	__class__u	Parameteru_nameu_kindu_defaultu_annotation(uselfuother((u,/opt/alt/python33/lib64/python3.3/inspect.pyu__eq__Es
uParameter.__eq__cCs|j|�S(N(u__eq__(uselfuother((u,/opt/alt/python33/lib64/python3.3/inspect.pyu__ne__LsuParameter.__ne__N(u_nameu_kindu_defaultu_annotationu_partial_kwargF(u__name__u
__module__u__qualname__u__doc__u	__slots__u_POSITIONAL_ONLYuPOSITIONAL_ONLYu_POSITIONAL_OR_KEYWORDuPOSITIONAL_OR_KEYWORDu_VAR_POSITIONALuVAR_POSITIONALu
_KEYWORD_ONLYuKEYWORD_ONLYu_VAR_KEYWORDuVAR_KEYWORDu_emptyuemptyuFalseu__init__upropertyunameudefaultu
annotationukindu_voidureplaceu__str__u__repr__u__eq__u__ne__(u
__locals__((u,/opt/alt/python33/lib64/python3.3/inspect.pyu	Parameter�s(u	ParametercBst|EeZdZdZdd�Zedd��Zedd��Zedd	��Zd
d�Z	dd
�Z
dS(uBoundArgumentsuResult of `Signature.bind` call.  Holds the mapping of arguments
    to the function's parameters.

    Has the following public attributes:

    * arguments : OrderedDict
        An ordered mutable mapping of parameters' names to arguments' values.
        Does not contain arguments' default values.
    * signature : Signature
        The Signature object that created this instance.
    * args : tuple
        Tuple of positional arguments values.
    * kwargs : dict
        Dict of keyword arguments values.
    cCs||_||_dS(N(u	argumentsu
_signature(uselfu	signatureu	arguments((u,/opt/alt/python33/lib64/python3.3/inspect.pyu__init__as	uBoundArguments.__init__cCs|jS(N(u
_signature(uself((u,/opt/alt/python33/lib64/python3.3/inspect.pyu	signatureesuBoundArguments.signaturec
Cs�g}x�|jjj�D]�\}}|jttfksC|jrGPny|j|}Wntk
rmPYqX|jt	kr�|j
|�q|j|�qWt|�S(N(
u
_signatureu
parametersuitemsukindu_VAR_KEYWORDu
_KEYWORD_ONLYu_partial_kwargu	argumentsuKeyErroru_VAR_POSITIONALuextenduappendutuple(uselfuargsu
param_nameuparamuarg((u,/opt/alt/python33/lib64/python3.3/inspect.pyuargsis	
uBoundArguments.argsc
Cs�i}d}x�|jjj�D]�\}}|sv|jttfksO|jrXd}qv||j	krvd}qqvn|s�qny|j	|}Wnt
k
r�YqX|jtkr�|j|�q|||<qW|S(NFT(uFalseu
_signatureu
parametersuitemsukindu_VAR_KEYWORDu
_KEYWORD_ONLYu_partial_kwarguTrueu	argumentsuKeyErroruupdate(uselfukwargsukwargs_startedu
param_nameuparamuarg((u,/opt/alt/python33/lib64/python3.3/inspect.pyukwargs�s(			
uBoundArguments.kwargscCs4t|jt�o3|j|jko3|j|jkS(N(u
issubclassu	__class__uBoundArgumentsu	signatureu	arguments(uselfuother((u,/opt/alt/python33/lib64/python3.3/inspect.pyu__eq__�suBoundArguments.__eq__cCs|j|�S(N(u__eq__(uselfuother((u,/opt/alt/python33/lib64/python3.3/inspect.pyu__ne__�suBoundArguments.__ne__N(u__name__u
__module__u__qualname__u__doc__u__init__upropertyu	signatureuargsukwargsu__eq__u__ne__(u
__locals__((u,/opt/alt/python33/lib64/python3.3/inspect.pyuBoundArgumentsPsuBoundArgumentscBs�|EeZdZdZdZeZeZe	Z
de	dd ddd�Z
edd	��Zed
d��Zedd
��Zdededd�Zdd�Zdd�Zdd!dd�Zdd�Zdd�Zdd�ZdS("u	SignatureuA Signature object represents the overall signature of a function.
    It stores a Parameter object for each parameter accepted by the
    function, as well as information specific to the function itself.

    A Signature object has the following public attributes and methods:

    * parameters : OrderedDict
        An ordered mapping of parameters' names to the corresponding
        Parameter objects (keyword-only arguments are in the same order
        as listed in `code.co_varnames`).
    * return_annotation : object
        The annotation for the return type of the function if specified.
        If the function has no annotation for its return type, this
        attribute is not set.
    * bind(*args, **kwargs) -> BoundArguments
        Creates a mapping from positional and keyword arguments to
        parameters.
    * bind_partial(*args, **kwargs) -> BoundArguments
        Creates a partial mapping from positional and keyword arguments
        to parameters (simulating 'functools.partial' behavior.)
    u_return_annotationu_parametersureturn_annotationu__validate_parameters__cCs4|dkrt�}n�|r�t�}t}x�t|�D]�\}}|j}||kr�d}	|	j||j�}	t|	��n|}|j}
|
dkr�t|�}
|j	d|
�}n|
|kr�dj|
�}	t|	��n|||
<q:Wntdd�|D��}t
j|�|_||_
dS(u�Constructs Signature from the given list of Parameter
        objects and 'return_annotation'.  All arguments are optional.
        u#wrong parameter order: {} before {}unameuduplicate parameter name: {!r}css|]}|j|fVqdS(N(uname(u.0uparam((u,/opt/alt/python33/lib64/python3.3/inspect.pyu	<genexpr>�su%Signature.__init__.<locals>.<genexpr>N(uNoneuOrderedDictu_POSITIONAL_ONLYu	enumerateukinduformatu
ValueErrorunameustrureplaceutypesuMappingProxyTypeu_parametersu_return_annotation(uselfu
parametersureturn_annotationu__validate_parameters__uparamsutop_kinduidxuparamukindumsguname((u,/opt/alt/python33/lib64/python3.3/inspect.pyu__init__�s0			
uSignature.__init__cCs�t|tj�s*tdj|���n|j}|j}|j}|j}t	|d|��}|j
}||||�}|j}	|j}
|j
}|
r�t|
�}nd}g}
||}xI|d|�D]7}|	j|t�}|
j||d|dt��q�Wx_t||d��D]G\}}|	j|t�}|
j||d|dtd|
|��q*W|jd@r�|||}|	j|t�}|
j||d|dt��nxl|D]d}t}|dk	r�|j|t�}n|	j|t�}|
j||d|dtd|��q�W|jd@r�||}|jd@rd|d	7}n||}|	j|t�}|
j||d|dt��n||
d
|	jdt�dd
�S(u2Constructs Signature for the given python functionu{!r} is not a Python functionNiu
annotationukindudefaultiiiureturn_annotationureturnu__validate_parameters__F(u
isinstanceutypesuFunctionTypeu	TypeErroruformatu_parameter_clsu__code__uco_argcountuco_varnamesutupleuco_kwonlyargcountu__annotations__u__defaults__u__kwdefaults__ulenugetu_emptyuappendu_POSITIONAL_OR_KEYWORDu	enumerateuco_flagsu_VAR_POSITIONALuNoneu
_KEYWORD_ONLYu_VAR_KEYWORDuFalse(uclsufuncu	Parameteru	func_codeu	pos_countu	arg_namesu
positionalukeyword_only_countukeyword_onlyuannotationsudefaultsu
kwdefaultsupos_default_countu
parametersunon_default_countunameu
annotationuoffsetudefaultuindex((u,/opt/alt/python33/lib64/python3.3/inspect.pyu
from_function�sd								
#








	uSignature.from_functioncCs|jS(N(u_parameters(uself((u,/opt/alt/python33/lib64/python3.3/inspect.pyu
parameters:suSignature.parameterscCs|jS(N(u_return_annotation(uself((u,/opt/alt/python33/lib64/python3.3/inspect.pyureturn_annotation>suSignature.return_annotationu
parameterscCsL|tkr|jj�}n|tkr6|j}nt|�|d|�S(u�Creates a customized copy of the Signature.
        Pass 'parameters' and/or 'return_annotation' arguments
        to override them in the new copy.
        ureturn_annotation(u_voidu
parametersuvaluesu_return_annotationutype(uselfu
parametersureturn_annotation((u,/opt/alt/python33/lib64/python3.3/inspect.pyureplaceBsuSignature.replacecCs2tt|�t�sF|j|jksFt|j�t|j�krJdSdd�t|jj��D�}x�t|jj	��D]�\}\}}|j
tkr�y|j|}Wntk
r�dSYq*X||kr*dSq�y||}Wntk
rdSYq�X||ks&||j|kr�dSq�WdS(NcSsi|]\}}||�qS(((u.0uidxuparam((u,/opt/alt/python33/lib64/python3.3/inspect.pyu
<dictcomp>Ws	u$Signature.__eq__.<locals>.<dictcomp>FT(u
issubclassutypeu	Signatureureturn_annotationulenu
parametersuFalseu	enumerateukeysuitemsukindu
_KEYWORD_ONLYuKeyErroruTrue(uselfuotheruother_positionsuidxu
param_nameuparamuother_paramu	other_idx((u,/opt/alt/python33/lib64/python3.3/inspect.pyu__eq__Qs,	(
	
	uSignature.__eq__cCs|j|�S(N(u__eq__(uselfuother((u,/opt/alt/python33/lib64/python3.3/inspect.pyu__ne__osuSignature.__ne__upartialcCs�t�}t|jj��}f}t|�}|r~xE|jj�D]1\}}	|	jrF||krF|	j||<qFqFWnx�yt|�}
Wntk
r�yt|�}	Wntk
r�PYn�X|	j	t
kr�Pn�|	j|kr2|	j	tkr%d}|j
d|	j�}t|�d�n|	f}Pnh|	j	tksP|	jtk	r]|	f}Pn=|rp|	f}Pn*d}|j
d|	j�}t|�d�Yq�Xyt|�}	Wn!tk
r�td�d�Yq�X|	j	ttfkr�td��n|	j	t
kr3|
g}|j|�t|�||	j<Pn|	j|kr`tdj
d|	j���n|
||	j<q�d}
x�tj||�D]�}	|	j	tkr�tdj
d|	j���n|	j	tkr�|	}
q�n|	j}y|j|�}
WnUtk
rJ|rF|	j	t
krF|	jtkrFtdj
d|��d�nYq�X|
||<q�W|r�|
dk	r{|||
j<q�td��n|j||�S(u$Private method.  Don't use directly.uA{arg!r} parameter is positional only, but was passed as a keyworduargu'{arg!r} parameter lacking default valueutoo many positional argumentsu$multiple values for argument {arg!r}utoo many keyword argumentsN(uOrderedDictuiteru
parametersuvaluesuitemsu_partial_kwargudefaultunextu
StopIterationukindu_VAR_POSITIONALunameu_POSITIONAL_ONLYuformatu	TypeErroruNoneu_VAR_KEYWORDu_emptyu
_KEYWORD_ONLYuextendutupleu	itertoolsuchainupopuKeyErroru_bound_arguments_cls(uselfuargsukwargsupartialu	argumentsu
parametersu
parameters_exuarg_valsu
param_nameuparamuarg_valumsguvaluesukwargs_param((u,/opt/alt/python33/lib64/python3.3/inspect.pyu_bindrs�	

			
	
	
uSignature._bindcOs|j||�S(u�Get a BoundArguments object, that maps the passed `args`
        and `kwargs` to the function's signature.  Raises `TypeError`
        if the passed arguments can not be bound.
        (u_bind(u_Signature__bind_selfuargsukwargs((u,/opt/alt/python33/lib64/python3.3/inspect.pyubind�suSignature.bindcOs|j||dd�S(u�Get a BoundArguments object, that partially maps the
        passed `args` and `kwargs` to the function's signature.
        Raises `TypeError` if the passed arguments can not be bound.
        upartialT(u_binduTrue(u_Signature__bind_selfuargsukwargs((u,/opt/alt/python33/lib64/python3.3/inspect.pyubind_partial�suSignature.bind_partialc	Cs�g}d}x�t|jj��D]k\}}t|�}|j}|tkrXd}n(|tkr�|r�|j	d�d}n|j	|�q"Wdj
dj|��}|jt
k	r�t|j�}|dj
|�7}n|S(Nu*u({})u, u -> {}TF(uTrueu	enumerateu
parametersuvaluesustrukindu_VAR_POSITIONALuFalseu
_KEYWORD_ONLYuappenduformatujoinureturn_annotationu_emptyuformatannotation(	uselfuresulturender_kw_only_separatoruidxuparamu	formattedukindurendereduanno((u,/opt/alt/python33/lib64/python3.3/inspect.pyu__str__s "		
	uSignature.__str__N(u_return_annotationu_parametersTF(u__name__u
__module__u__qualname__u__doc__u	__slots__u	Parameteru_parameter_clsuBoundArgumentsu_bound_arguments_clsu_emptyuemptyuTrueuNoneu__init__uclassmethodu
from_functionupropertyu
parametersureturn_annotationu_voidureplaceu__eq__u__ne__uFalseu_bindubindubind_partialu__str__(u
__locals__((u,/opt/alt/python33/lib64/python3.3/inspect.pyu	Signature�s"	%I�u	Signature(uKa-Ping Yee <ping@lfw.org>u'Yury Selivanov <yselivanov@sprymix.com>(ii(ii(ii i@iF(�u__doc__u
__author__uimpuimportlib.machineryu	importlibu	itertoolsu	linecacheuosureusysutokenizeutypesuwarningsu	functoolsubuiltinsuoperatoru
attrgetterucollectionsu
namedtupleuOrderedDictudisuCOMPILER_FLAG_NAMESu_flag_namesuImportErroruCO_OPTIMIZEDuCO_NEWLOCALSu
CO_VARARGSuCO_VARKEYWORDSu	CO_NESTEDuCO_GENERATORu	CO_NOFREEuglobalsumod_dictuitemsukuvuTPFLAGS_IS_ABSTRACTuismoduleuisclassuismethoduismethoddescriptoruisdatadescriptoruhasattruismemberdescriptoruisgetsetdescriptoru
isfunctionuisgeneratorfunctionuisgeneratoruistracebackuisframeuiscodeu	isbuiltinu	isroutineu
isabstractuNoneu
getmembersu	Attributeuclassify_class_attrsugetmrou
indentsizeugetdocucleandocugetfileu
ModuleInfou
getmoduleinfou
getmodulenameu
getsourcefileu
getabsfileu
modulesbyfileu_filesbymodnameu	getmoduleu
findsourceugetcommentsu	Exceptionu
EndOfBlockuBlockFinderugetblockugetsourcelinesu	getsourceuwalktreeuFalseugetclasstreeu	Argumentsugetargsu_getfullargsuArgSpecu
getargspecuFullArgSpecugetfullargspecuArgInfougetargvaluesuformatannotationuformatannotationrelativetoustru
formatargspecuformatargvaluesu_missing_argumentsu	_too_manyugetcallargsuClosureVarsugetclosurevarsu	Tracebackugetframeinfou	getlinenougetouterframesugetinnerframesucurrentframeustackutraceuobjectu	_sentinelu_static_getmrou_check_instanceu_check_classu_is_typeu_shadowed_dictugetattr_staticuGEN_CREATEDuGEN_RUNNINGu
GEN_SUSPENDEDu
GEN_CLOSEDugetgeneratorstateugetgeneratorlocalsutypeu__call__u_WrapperDescriptoruallu_MethodWrapperuBuiltinFunctionTypeu_NonUserDefinedCallablesu_get_user_defined_methodu	signatureu_voidu_emptyuintu_ParameterKindu_POSITIONAL_ONLYu_POSITIONAL_OR_KEYWORDu_VAR_POSITIONALu
_KEYWORD_ONLYu_VAR_KEYWORDu	ParameteruBoundArgumentsu	Signature(((u,/opt/alt/python33/lib64/python3.3/inspect.pyu<module>s
		

	
	F	.C-'



	
						)		>5!			0r
�]