ó 6šâWc@s0dZdZdefd„ƒYZdefd„ƒYZdefd„ƒYZdd5d „ƒYZd d6d „ƒYZd efd „ƒYZdefd„ƒYZ defd„ƒYZ de fd„ƒYZ de fd„ƒYZ de fd„ƒYZ de fd„ƒYZdefd„ƒYZdefd„ƒYZdefd„ƒYZd efd!„ƒYZd"efd#„ƒYZd$efd%„ƒYZd&efd'„ƒYZd(efd)„ƒYZd*efd+„ƒYZd,efd-„ƒYZd.efd/„ƒYZd0efd1„ƒYZd2efd3„ƒYZd4S(7sM Defines classes that represent declarations found in C++ header files. s1.0t DeclarationcBs2eZdZd„Zd„Zd„Zd„ZRS(s‰Base class for all declarations. @ivar name: The name of the declaration. @ivar namespace: The namespace of the declaration. cCs1||_||_d|_t|_t|_dS(sà @type name: string @param name: The name of this declaration @type namespace: string @param namespace: the full namespace where this declaration resides. tiÿÿÿÿN(Riÿÿÿÿ(tnamet namespacetlocationtFalset incompletetTruet is_unique(tselfRR((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyt__init__s     cCs=|jp d}|r2|jdƒ r2|d7}n||jS(s‘ Returns the full qualified name: "boost::inner::Test" @rtype: string @return: The full name of the declaration. Rs::(RtendswithR(R R((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pytFullName's cCsd|jƒt|ƒfS(Ns(R tid(R ((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyt__repr__3scCsd|jƒS(NsDeclaration of %s(R (R ((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyt__str__7s(t__name__t __module__t__doc__R R RR(((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyRs   tClasscBs\eZdZd„Zd„Zed„Zd„Zd„Zd„Z d„Z e e ƒZ RS(s Represents a C++ class or struct. Iteration through it yields its members. @type abstract: bool @ivar abstract: if the class has any abstract methods. @type bases: tuple @ivar bases: tuple with L{Base} instances, representing the most direct inheritance. @type hierarchy: list @ivar hierarchy: a list of tuples of L{Base} instances, representing the entire hierarchy tree of this object. The first tuple is the parent classes, and the other ones go up in the hierarchy. cCsMtj|||ƒ||_i|_||_d|_d|_i|_dS(N(((RR t_Class__memberst_Class__member_namestabstracttbasest hierarchytoperator(R RRtmembersR((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR Os     cCs t|jƒS(s-iterates through the class' members. (titerR(R ((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyt__iter__YscCsXg}xK|D]C}t|tƒr |r@|jtjkr@q n|j|ƒq q W|S(sPReturns a list of the constructors for this class. @rtype: list (t isinstancet Constructort visibilitytScopetpublictappend(R t publics_onlyt constructorstmember((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyt Constructors_s cCs+x$|jƒD]}|jƒr tSq WtS(sWReturns true if this class has a public copy constructor. @rtype: bool (R&tIsCopyRR(R tcons((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pytHasCopyConstructorls cCs+x$|jƒD]}|jƒr tSq WtS(sZReturns true if this class has a public default constructor. @rtype: bool (R&t IsDefaultRR(R R(((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pytHasDefaultConstructorvs cCsœ|j|jkrMt|_x8|D]$}|j|jkr"t|_q"q"Wn t|_d|j|j<|jj|ƒt|tƒr˜||j |js   R/cBs eZdZd„Zd„ZRS(sûThe declaration of a class/struct inside another class/struct. @type class: string @ivar class: fullname of the class where this class is contained. @type visibility: L{Scope} @ivar visibility: the visibility of this class. cCs/tj||d||ƒ||_||_dS(N(RR tNonetclass_R(R RR8tvisibRR((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR ¡s cCsd|j|jfS(sSThe full name of this class, like ns::outer::inner. @rtype: string s%s::%s(R8R(R ((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR §s(RRRR R (((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR/—s R cBs eZdZdZdZdZRS(s¼Used to represent the visibility of various members inside a class. @cvar public: public visibility @cvar private: private visibility @cvar protected: protected visibility R!tprivatet protected(RRRR!R:R;(((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR ±stBasecBseZdZejd„ZRS(s™Represents a base class of another class. @ivar _name: the full name of the base class. @ivar _visibility: the visibility of the derivation. cCs||_||_dS(N(RR(R RR((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR Ås (RRRR R!R (((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR<¿stFunctioncBsYeZdZdd„Zd„Zed„Zd„Ze eƒZ d„Z e e ƒZ RS(s¶The declaration of a function. @ivar _result: instance of L{Type} or None. @ivar _parameters: list of L{Type} instances. @ivar _throws: exception specifiers or None cCs2tj|||ƒ||_||_||_dS(N(RR tresultt parameterstthrows(R RRR>tparamsR@((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR Ôs  cCsD|jdkrdSddjg|jD]}|jƒ^q&ƒSdS(NRs throw(%s)s, (R@R7tjoinR (R tx((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyt ExceptionsÞscCs||jr| rd|jƒS|jjƒ}djg|jD]}|jƒ^q=ƒ}d|||jƒ|jƒfSdS(s¹Returns a declaration of a pointer to this function. @param force: If True, returns a complete pointer declaration regardless if this function is unique or not. s&%ss, s(%s (*)(%s)%s)&%sN(RR R>RBR?RD(R tforceR>RCRA((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pytPointerDeclarationås +cCs:d}x-|jD]"}|jdkr|d7}qqW|S(Nii(R?tdefaultR7(R tmintarg((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pytMinArgsòs cCs t|jƒS(N(tlenR?(R ((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pytMaxArgsüsN( RRRR7R RDRRFRJtpropertytminArgsRLtmaxArgs(((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR=Ís    tOperatorcBseZdZd„ZRS(sThe declaration of a custom operator. Its name is the same as the operator name in C++, ie, the name of the declaration "operator+(..)" is "+". cCs:|jp d}|jdƒs+|d7}n|d|jS(NRs::R(RR R(R R((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR s (RRRR (((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyRPsR0cBs/eZdZdd„Zd„Zed„ZRS(sÔThe declaration of a method. @ivar _visibility: the visibility of this method. @ivar _virtual: if this method is declared as virtual. @ivar _abstract: if this method is virtual but has no default implementation. @ivar _static: if this method is static. @ivar _class: the full name of the class where this method was declared. @ivar _const: if this method is declared as const. @ivar _throws: list of exception specificiers or None c CsVtj||d||| ƒ||_||_||_||_||_| |_dS(N( R=R R7RtvirtualRtstaticR8tconst( R RR8R>RAR9RQRRRRSR@((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR "s     cCs|jd|jS(Ns::(R8R(R ((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR ,scCs¶|jrtj||ƒS|jr7| r7d|jƒS|jjƒ}djg|jD]}|jƒ^qVƒ}d}|jr‰d}nd||j |||j ƒ|jƒfSdS(sÁReturns a declaration of a pointer to this member function. @param force: If True, returns a complete pointer declaration regardless if this function is unique or not. s&%ss, RRSs(%s (%s::*)(%s) %s%s)&%sN( RRR=RFRR R>RBR?RSR8RD(R RER>RCRARS((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyRF0s +  N(RRRR7R R RRF(((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR0s  RcBs5eZdZd„Zd„Zd„Zed„ZRS(sA class' constructor. c Cs,tj|||d||ttttƒ dS(N(R0R R7R(R RR8RAR9((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR KscCs%t|jƒdko$|jtjkS(sCReturns True if this constructor is a default constructor. i(RKR?RR R!(R ((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR*OscCsyt|jƒdkrtS|jd}|jdj|jk}t|tƒ}|jtj k}|ox|ox|j ox|S(s@Returns True if this constructor is a copy constructor. ii( RKR?RRR8Rt ReferenceTypeRR R!RS(R tparamtclass_as_paramtparam_referencet is_public((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR'Us cCsdS(NR((R RE((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyRFas(RRRR R*R'RRF(((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyRGs    R1cBs,eZdZd„Zd„Zed„ZRS(sThe destructor of a class.c Cs,tj|||dg||tttƒ dS(N(R0R R7R(R RR8R9RQ((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR kscCs|jd|jS(Ns::~(R8R(R ((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR nscCsdS(NR((R RE((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyRFrs(RRRR R RRF(((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR1hs  R,cBseZdZd„ZRS(sA custom operator in a class.cCs|jd|jS(Ns ::operator (R8R(R ((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR }s(RRRR (((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR,zsR3cBseZdZd„ZRS(s0An operator in the form "operator OtherClass()".cCs|jd|jjƒS(Ns ::operator (R8R>R (R ((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR ˆs(RRRR (((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR3…stTypecBs2eZdZeddd„Zd„Zd„ZRS(s˜Represents the type of a variable or parameter. @ivar _const: if the type is constant. @ivar _default: if this type has a default value associated with it. @ivar _volatile: if this type was declared with the keyword volatile. @ivar _restricted: if this type was declared with the keyword restricted. @ivar _suffix: Suffix to get the full type name. '*' for pointers, for example. RcCsDtj||dƒ||_||_t|_t|_||_dS(N( RR R7RSRGRtvolatilet restrictedtsuffix(R RRSRGR\((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR šs     cCs+|jrd}nd}d||jdS(Nsconst Rs(RSR(R RS((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR¤s  cCs*|jrd}nd}||j|jS(Nsconst R(RSRR\(R RS((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR ¬s  N(RRRRR7R RR (((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyRYs t ArrayTypecBseZdZd„ZRS(s˜Represents an array. @ivar min: the lower bound of the array, usually 0. Can be None. @ivar max: the upper bound of the array. Can be None. cCs)tj|||ƒ||_||_dS(smin and max can be None.N(RYR RHtmax(R RRSRHR_((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR ½s (RRRR (((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR^·sRTcBs#eZdZededd„ZRS(sA reference type.RcCs0tj||||ƒ|r,|d|_ndS(Nt&(RYR R\(R RRSRGt expandRefR\((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR ËsN(RRRRR7RR (((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyRTÈst PointerTypecBs#eZdZededd„ZRS(sA pointer type.RcCs0tj||||ƒ|r,|d|_ndS(Nt*(RYR R\(R RRSRGt expandPointerR\((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR ×sN(RRRRR7R (((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyRbÔstFundamentalTypecBseZdZedd„ZRS(s2One of the fundamental types, like int, void, etc.cCstj||||ƒdS(N(RYR (R RRSRG((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR ãsN(RRRRR7R (((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyReàst FunctionTypecBs eZdZd„Zd„ZRS(s¿A pointer to a function. @ivar _result: the return value @ivar _parameters: a list of Types, indicating the parameters of the function. @ivar _name: the name of the function. cCs8tj|dtƒ||_||_|jƒ|_dS(NR(RYR RR>R?R R(R R>R?((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR òs  cCsPd|jjƒ}g|jD]}|jƒ^q}|ddj|ƒ7}|S(Ns%s (*)s(%s)s, (R>R R?RB(R tfullRCRA((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR ùs"(RRRR R (((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyRfës t MethodTypecBs eZdZd„Zd„ZRS(swA pointer to a member function of a class. @ivar _class: The fullname of the class that the method belongs to. cCs ||_tj|||ƒdS(N(R8RfR (R R>R?R8((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR s cCsYd|jjƒ|jf}g|jD]}|jƒ^q&}|ddj|ƒ7}|S(Ns %s (%s::*)s(%s)s, (R>R R8R?RB(R RgRCRA((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR s"(RRRR R (((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyRhs tVariablecBseZdZd„ZRS(sgRepresents a global variable. @type _type: L{Type} @ivar _type: The type of the variable. cCs tj|||ƒ||_dS(N(RR ttype(R RjRR((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR s(RRRR (((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyRisR2cBs eZdZd„Zd„ZRS(s%Represents a class variable. @type _visibility: L{Scope} @ivar _visibility: The visibility of this variable within the class. @type _static: bool @ivar _static: Indicates if the variable is static. @ivar _class: Full name of the class that this variable belongs to. cCs5tj|||dƒ||_||_||_dS(N(RiR R7RRRR8(R RjRR8R9RR((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR 2s  cCs|jd|jS(Ns::(R8R(R ((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR 9s(RRRR R (((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR2&s  t EnumerationcBs eZdZd„Zd„ZRS(srRepresents an enum. @type _values: dict of str => int @ivar _values: holds the values for this enum. cCs tj|||ƒi|_dS(N(RR tvalues(R RR((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR GscCs9||jkst‚|j}|r1|d7}n||S(s7Returns the full name for a value in the enum. s::(RltAssertionErrorR(R RR((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyt ValueFullNameLs   (RRRR Rn(((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyRk@s R4cBs)eZdZd„Zd„Zd„ZRS(s³Represents an enum inside a class. @ivar _class: The full name of the class where this enum belongs. @ivar _visibility: The visibility of this enum inside his class. cCs)tj||dƒ||_||_dS(N(RkR R7R8R(R RR8R9((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR `s cCsd|j|jfS(Ns%s::%s(R8R(R ((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR fscCs&||jkst‚d|j|fS(Ns%s::%s(RlRmR8(R R((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyRnjs(RRRR R Rn(((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR4Ys  tTypedefcBseZdZd„ZRS(s·A Typedef declaration. @type _type: L{Type} @ivar _type: The type of the typedef. @type _visibility: L{Scope} @ivar _visibility: The visibility of this typedef. cCs,tj|||ƒ||_tj|_dS(N(RR RjR R!R(R RjRR((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR |s (RRRR (((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyRorstUnknowncBseZdZd„ZRS(s:A declaration that Pyste does not know how to handle. cCstj||dƒdS(N(RR R7(R R((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyR Œs(RRRR (((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyRpˆsN(((RtversiontobjectRRR/R R<R=RPR0RR1R,R3RYR^RTRbReRfRhRiR2RkR4RoRp(((s6/usr/lib/python2.7/dist-packages/Pyste/declarations.pyt s4+Y91!  '