o
    ýeñ  ã                   @   s|   d Z ddlZddlZddlmZ ddlmZ ejd dkZejd dkZ	e	r+ddl
ZnddlZe e¡Zdd„ Zd	d
„ ZdS )zO
This module provides some python2 and python3's compatible functions for BTS.
é    N)ÚBceClientError)ÚPYTHON_VERSION_ERRORé   é   c                 C   ó4   t rt | ¡S trtj | ¡S ttƒ}t |¡ |‚)zV
    _encode

    :param s: s
    :type s: string

    :return:
    :rtype string
    )	ÚPY2ÚurllibÚquoteÚPY3Úparser   r   Ú_loggerÚdebug©ÚsÚex© r   úJD:\Projects\ConvertPro\env\Lib\site-packages\baidubce/services/bts/util.pyÚ_encode   ó   


r   c                 C   r   )zV
    _decode

    :param s: s
    :type s: string

    :return:
    :rtype string
    )	r   r   Úunquoter
   r   r   r   r   r   r   r   r   r   Ú_decode3   r   r   )Ú__doc__ÚsysÚloggingZbaidubce.exceptionr   Zbaidubce.services.btsr   Úversion_infor   r
   Úurllib.parser   Ú	getLoggerÚ__name__r   r   r   r   r   r   r   Ú<module>   s   


