def list_share_single_file(cookie, tokens, uk, shareid):
def parse_share_page(content):<EOL><INDENT>tree = html.fromstring(content)<EOL>script_sel = CSS('<STR_LIT>')<EOL>scripts = script_sel(tree)<EOL>for script in scripts:<EOL><INDENT>if (script.text and (script.text.find('<STR_LIT>') > -<NUM_LIT:1> or<EOL>script.text.find('<STR_LIT>') > -<NUM_LIT:1>)):<EOL><INDENT>break<EOL><DEDENT><DEDENT>else:<EOL><INDENT>logger.warn('<STR_LIT>', url)<EOL>return None<EOL><DEDENT>start = script.text.find('<STR_LIT>')<EOL>end = script.text.find('<STR_LIT>')<EOL>if start == -<NUM_LIT:1> or end == -<NUM_LIT:1>:<EOL><INDENT>start = script.text.find('<STR_LIT>')<EOL>end = script.text.find('<STR_LIT>')<EOL>if start == -<NUM_LIT:1> or end == -<NUM_LIT:1>:<EOL><INDENT>return None<EOL><DEDENT>else:<EOL><INDENT>json_str = script.text[start+<NUM_LIT>:end]<EOL><DEDENT><DEDENT>else:<EOL><INDENT>json_str = script.text[start+<NUM_LIT>:end]<EOL><DEDENT>try:<EOL><INDENT>return json.loads(json.loads(json_str))<EOL><DEDENT>except ValueError:<EOL><INDENT>logger.warn(traceback.format_exc())<EOL>return None<EOL><DEDENT><DEDENT>url = '<STR_LIT>'.join([<EOL>const.PAN_URL, '<STR_LIT>',<EOL>'<STR_LIT>', shareid,<EOL>'<STR_LIT>', uk,<EOL>'<STR_LIT>',<EOL>])<EOL>req = net.urlopen(url, headers={<EOL>'<STR_LIT>': cookie.header_output(),<EOL>'<STR_LIT>': const.SHARE_REFERER,<EOL>})<EOL>if req:<EOL><INDENT>return parse_share_page(req.data.decode())<EOL><DEDENT>else:<EOL><INDENT>return None<EOL><DEDENT>
获取单独共享出来的文件.

    目前支持的链接格式有:
      * http://pan.baidu.com/wap/link?uk=202032639&shareid=420754&third=0
      * http://pan.baidu.com/share/link?uk=202032639&shareid=420754