;
Êâ"Ic               @   s   d  Z  d „  Z d „  Z d S(   u3   Convert a NT pathname to a file URL and vice versa.c             C   sJ  d d l  } d d l } |  j d d ƒ }  d |  k oT |  d d … d k o |  d d … }  n |  j d ƒ } | j j d	 j | ƒ ƒ S|  j d ƒ } t | ƒ d k p | d d
 | j k o d |  } t	 | ƒ ‚ n | d d
 j
 ƒ  } | d j d ƒ } | d } x3 | D]+ } | o | d	 | j j | ƒ } qqW| S(   u{   OS-specific conversion from a relative URL of the 'file' scheme
    to a file system path; not recommended for general use.i    Nu   :u   |i   u   ////i   u   /u   \iÿÿÿÿu	   Bad URL: i   (   u   stringu   urllib.parseu   replaceu   splitu   parseu   unquoteu   joinu   lenu   ascii_lettersu   IOErroru   upper(   u   urlu   stringu   urllibu
   componentsu   compu   erroru   driveu   path(    (    u'   /mit/python/lib/python3.0/nturl2path.pyu   url2pathname   s&    +

 "c             C   s1  d d l  } d |  k oN |  d d … d k o d |  }  n |  j d ƒ } | j j d j | ƒ ƒ S|  j d ƒ } t | ƒ d k p t | d ƒ d k o d	 |  } t | ƒ ‚ n | j j | d j ƒ  ƒ } | d j d ƒ } d
 | d } x3 | D]+ } | o | d | j j | ƒ } qþ qþ W| S(   u{   OS-specific conversion from a file system path to a relative URL
    of the 'file' scheme; not recommended for general use.i    Nu   :i   u   \\u   \u   /i   u
   Bad path: u   ///u   |(   u   urllib.parseu   splitu   parseu   quoteu   joinu   lenu   IOErroru   upper(   u   pu   urllibu
   componentsu   compu   erroru   driveu   path(    (    u'   /mit/python/lib/python3.0/nturl2path.pyu   pathname2url#   s$    *
 "N(   u   __doc__u   url2pathnameu   pathname2url(    (    (    u'   /mit/python/lib/python3.0/nturl2path.pyu   <module>   s   	 