@tornado.web.asynchronous<EOL><INDENT>def get(self, path):<DEDENT>
logging.debug("<STR_LIT>", path)<EOL>self.connection_closed = False<EOL>self.set_header("<STR_LIT>", "<STR_LIT>")<EOL>if not utils.check_path(path):<EOL><INDENT>self.write("<STR_LIT>")<EOL>self.set_status(<NUM_LIT>)<EOL>self.finish()<EOL>return<EOL><DEDENT>if path is None or not os.path.isfile(path):<EOL><INDENT>self.write("<STR_LIT>" % path)<EOL>self.set_status(<NUM_LIT>)<EOL>self.finish()<EOL>return<EOL><DEDENT>length = int(<NUM_LIT:4> * <NUM_LIT> * <NUM_LIT>)<EOL>offset = int(<NUM_LIT:0>)<EOL>while True:<EOL><INDENT>data = utils.read_chunk(path, offset=offset, length=length, escape_data=False)<EOL>if self.connection_closed or '<STR_LIT:data>' not in data or len(data['<STR_LIT:data>']) < length:<EOL><INDENT>break<EOL><DEDENT>offset += length<EOL>self.write(data['<STR_LIT:data>'])<EOL>self.flush()<EOL><DEDENT>if '<STR_LIT:data>' in data:<EOL><INDENT>self.write(data['<STR_LIT:data>'])<EOL><DEDENT>self.finish()<EOL>
get method