Django请求
2017-12-19 09:02:24 8 举报
Django Request UML类图
作者其他创作
大纲/内容
Note: Mutltipart 数据解析部分,迭代器使用的非常棒
django.http.multipartparser::ChunkIter
self.floself.chunk_size
__next__(self)__iter__(self)
django.core.files.uploadhandler::MemoryFileUploadHandler
django.http.multipartparser::LazyStream
self._producer
django.core.files.uploadedfile::UploadedFIle
参考:
django.http.request::HttpRequest
self.GET = QueryDict(mutable=True)self.POST = QueryDict(mutable=True)self.COOKIES = {}self.META = {}self.FILES = MultiValueDict()self.path = ''self.path_info = ''self.schemeself.bodyself._postself._filesself.upload_handlers
django.core.files.uploadhandler::FileUploadHandler
self.file_name = Noneself.content_type = Noneself.content_length = Noneself.charset = Noneself.content_type_extra = Noneself.request = requestself._post = QueryDict()self._files = MultiValueDict()
django.core.handlers.wsgi::WSGIRequest
self.GETself.POSTself.FILESself.REQUESTself.COOKIESself._stream
six.Iterator
next(self)
django.http.multipartparser::BoundaryIter
self._streamself._boundaryself._doneself._rollback
django.core.files.uploadhandler::TemporaryFileUploadHandler
self.file
django.core.handlers.wsgi::LimitedStream
self.streamself.remainingself.buffer = b''self.buf_size = 64 * 1024 * 1024
django.core.files.uploadedfile::SimpleUploadedFIle
RFC2388 Returning Value from Forms: multipart/form-data
django.core.files.base::File
GET 解析query string为QueryDict对象POST 解析表单数据为QueryDict对象FILES 解析多multipart表单为MultiValueDict对象REQUEST 将GET,POST两个QueryDict对象合并
django.http.multipartparser::InterBoundaryIter
self._streamself._boundary
django.core.files.uploadedfile::TemporaryUploadedFile
django.http.multipartparser::MultipartParser
self._meta = METAself._encodingself._content_lengthself._upload_handlers
django.core.files.uploadedfile::ImMemoryUploadedFile
0 条评论
下一页