Home
last modified time | relevance | path

Searched refs:mime_type (Results 1 – 25 of 46) sorted by relevance

12

/external/chromium-trace/catapult/third_party/apiclient/googleapiclient/
Dmimeparse.py35 def parse_mime_type(mime_type): argument
45 parts = mime_type.split(';')
82 def fitness_and_quality_parsed(mime_type, parsed_ranges): argument
94 parse_media_range(mime_type)
116 def quality_parsed(mime_type, parsed_ranges): argument
126 return fitness_and_quality_parsed(mime_type, parsed_ranges)[1]
129 def quality(mime_type, ranges): argument
142 return quality_parsed(mime_type, parsed_ranges)
163 for mime_type in supported:
164 weighted_matches.append((fitness_and_quality_parsed(mime_type,
[all …]
/external/chromium-trace/catapult/third_party/Paste/paste/util/
Dmimeparse.py24 def parse_mime_type(mime_type): argument
33 type = mime_type.split(';')
72 def fitness_and_quality_parsed(mime_type, parsed_ranges): argument
81 target_type, target_subtype, target_params = parse_media_range(mime_type)
101 def quality_parsed(mime_type, parsed_ranges): argument
109 return fitness_and_quality_parsed(mime_type, parsed_ranges)[1]
111 def quality(mime_type, ranges): argument
120 return quality_parsed(mime_type, parsed_ranges)
137 (fitness_and_quality_parsed(mime_type, parsed_header), -n)
138 for n, mime_type in enumerate(supported)])
/external/libbrillo/brillo/http/
Dhttp_utils.cc66 const std::string& mime_type, in PostTextAndBlock() argument
71 url, data.data(), data.size(), mime_type, headers, transport, error); in PostTextAndBlock()
76 const std::string& mime_type, in PostText() argument
84 mime_type, in PostText()
96 const std::string& mime_type, in SendRequestAndBlock() argument
103 CHECK(!mime_type.empty()) << "MIME type must be specified if request body " in SendRequestAndBlock()
105 request.SetContentType(mime_type); in SendRequestAndBlock()
125 const std::string& mime_type, in SendRequest() argument
133 CHECK(!mime_type.empty()) << "MIME type must be specified if request body " in SendRequest()
135 request.SetContentType(mime_type); in SendRequest()
[all …]
Dhttp_transport_fake.cc123 const std::string& mime_type) { in AddSimpleReplyHandler() argument
124 auto handler = [status_code, reply_text, mime_type]( in AddSimpleReplyHandler()
126 response->ReplyText(status_code, reply_text, mime_type); in AddSimpleReplyHandler()
225 std::string mime_type = brillo::mime::RemoveParameters( in GetFormField() local
227 if (mime_type == brillo::mime::application::kWwwFormUrlEncoded && in GetFormField()
241 const std::string& mime_type) { in Reply() argument
247 {response_header::kContentType, mime_type}}); in Reply()
252 const std::string& mime_type) { in ReplyText() argument
253 Reply(status_code, text.data(), text.size(), mime_type); in ReplyText()
260 std::string mime_type = in ReplyJson() local
[all …]
Dhttp_transport_fake.h58 const std::string& mime_type);
204 const std::string& mime_type);
208 const std::string& mime_type);
221 const std::string& mime_type) { in Reply() argument
224 Reply(status_code, data.data(), data.size() * sizeof(T), mime_type); in Reply()
230 void Reply(int status_code, const T& data, const std::string& mime_type) { in Reply() argument
233 Reply(status_code, &data, sizeof(T), mime_type); in Reply()
Dhttp_utils.h61 const std::string& mime_type,
84 const std::string& mime_type,
100 const std::string& mime_type,
160 const std::string& mime_type,
171 const std::string& mime_type,
186 const std::string& mime_type,
198 const std::string& mime_type,
209 const std::string& mime_type,
/external/chromium-trace/catapult/third_party/gsutil/third_party/boto/boto/services/
Dmessage.py36 mime_type = mimetypes.guess_type(t[1])[0]
37 if mime_type is None:
38 mime_type = 'application/octet-stream'
39 self['Content-Type'] = mime_type
/external/chromium-trace/catapult/third_party/gsutil/third_party/apitools/apitools/base/py/
Dutil.py142 def AcceptableMimeType(accept_patterns, mime_type): argument
157 if '/' not in mime_type:
159 'Invalid MIME type: "%s"' % mime_type)
166 def MimeTypeMatches(pattern, mime_type): argument
172 in zip(pattern.split('/'), mime_type.split('/')))
174 return any(MimeTypeMatches(pattern, mime_type)
Dtransfer.py534 def __init__(self, stream, mime_type, total_size=None, http=None, argument
543 self.__mime_type = mime_type
558 def FromFile(cls, filename, mime_type=None, auto_transfer=True, **kwds): argument
563 if not mime_type:
564 mime_type, _ = mimetypes.guess_type(path)
565 if mime_type is None:
569 return cls(open(path, 'rb'), mime_type, total_size=size,
573 def FromStream(cls, stream, mime_type, total_size=None, auto_transfer=True, argument
576 if mime_type is None:
579 return cls(stream, mime_type, total_size=total_size,
[all …]
Dutil_test.py136 for accept, mime_type in valid_pairs:
137 self.assertTrue(util.AcceptableMimeType([accept], mime_type))
144 for accept, mime_type in invalid_pairs:
145 self.assertFalse(util.AcceptableMimeType([accept], mime_type))
/external/chromium-trace/catapult/tracing/tracing_build/
Dtrace2html.py60 def __init__(self, trace_data_string, mime_type): argument
63 self._mime_type = mime_type
98 mime_type = 'application/json'
100 mime_type = 'text/plain'
101 scripts.append(ViewerDataScript(trace_data, mime_type))
/external/owasp/sanitizer/tools/
Dcut_release.py113 mime_type = mime_type_from_path(dest_path)
114 if mime_type is None or mime_type.startswith("text/"):
177 mime_type = mime_type_from_path(new_file_path) variable
178 if mime_type is not None:
179 print "svn propset svn:mime-type '%s' '%s'" % (mime_type, new_file_path)
Dupdate_tree_in_svn.py83 mime_type = MIME_TYPES_BY_EXTENSION.get(dst[dot+1:])
84 if mime_type is not None:
85 key = ('svn:mime-type', mime_type)
/external/libweave/examples/provider/
Devent_http_server.cc54 const std::string& mime_type) override { in SendReply() argument
58 evhtp_header_val_add(req_->headers_out, mime_type.c_str(), 1); in SendReply()
172 const std::string& mime_type) {} in ProcessReply() argument
Devent_http_server.h48 const std::string& mime_type);
/external/ImageMagick/Magick++/lib/
DCoderInfo.cpp76 _mimeType=std::string(magickInfo->mime_type != (char *) NULL ? in CoderInfo()
77 magickInfo->mime_type : ""); in CoderInfo()
/external/ImageMagick/coders/
Djp2.c548 entry->mime_type=ConstantString("image/jp2"); in RegisterJP2Image()
560 entry->mime_type=ConstantString("image/jp2"); in RegisterJP2Image()
572 entry->mime_type=ConstantString("image/jp2"); in RegisterJP2Image()
584 entry->mime_type=ConstantString("image/jp2"); in RegisterJP2Image()
596 entry->mime_type=ConstantString("image/jp2"); in RegisterJP2Image()
608 entry->mime_type=ConstantString("image/jp2"); in RegisterJP2Image()
/external/libweave/include/weave/provider/
Dhttp_server.h120 const std::string& mime_type) = 0;
/external/ImageMagick/MagickCore/
Dmagick.h64 *mime_type, member
Dmagick.c790 return(magick_info->mime_type); in GetMagickMimeType()
978 if (p->mime_type != (char *) NULL) in DestroyMagickNode()
979 p->mime_type=DestroyString(p->mime_type); in DestroyMagickNode()
/external/autotest/frontend/afe/feeds/
Dfeed.py34 response = HttpResponse(mimetype=feedgen.mime_type)
/external/flac/include/FLAC/
Dmetadata.h237 …Metadata **picture, FLAC__StreamMetadata_Picture_Type type, const char *mime_type, const FLAC__byt…
2108 …tadata_object_picture_set_mime_type(FLAC__StreamMetadata *object, char *mime_type, FLAC__bool copy…
Dformat.h773 char *mime_type; member
/external/chromium-trace/catapult/third_party/WebOb/docs/pycon2011/
Dresponse_table.rst32 … z z mime_type content_type str wo parameters
/external/flac/libFLAC/
Dstream_encoder_framing.c181 len = strlen(metadata->data.picture.mime_type); in FLAC__add_metadata_block()
184 …if(!FLAC__bitwriter_write_byte_block(bw, (const FLAC__byte*)metadata->data.picture.mime_type, len)) in FLAC__add_metadata_block()

12