Home
last modified time | relevance | path

Searched refs:guess_type (Results 1 – 18 of 18) sorted by relevance

/third_party/python/Lib/test/
Dtest_mimetypes.py39 eq(self.db.guess_type("foo.html"), ("text/html", None))
40 eq(self.db.guess_type("foo.HTML"), ("text/html", None))
41 eq(self.db.guess_type("foo.tgz"), ("application/x-tar", "gzip"))
42 eq(self.db.guess_type("foo.tar.gz"), ("application/x-tar", "gzip"))
43 eq(self.db.guess_type("foo.tar.Z"), ("application/x-tar", "compress"))
44 eq(self.db.guess_type("foo.tar.bz2"), ("application/x-tar", "bzip2"))
45 eq(self.db.guess_type("foo.tar.xz"), ("application/x-tar", "xz"))
49 guess_type = self.db.guess_type
50 eq(guess_type("data:invalidDataWithoutComma"), (None, None))
51 eq(guess_type("data:,thisIsTextPlain"), ("text/plain", None))
[all …]
/third_party/boost/libs/math/example/
Droot_finding_multiprecision_example.cpp56 typedef long double guess_type; in cbrt_2deriv() typedef
59 guess_type pow_guess = std::pow(static_cast<guess_type>(x), static_cast<guess_type>(1) / 3); in cbrt_2deriv()
65 frexp(static_cast<guess_type>(x), &exponent); // Get exponent of z (ignore mantissa). in cbrt_2deriv()
66 …T guess = ldexp(static_cast<guess_type>(1.), exponent / 3); // Rough guess is to divide the expone… in cbrt_2deriv()
67 …T min = ldexp(static_cast<guess_type>(1.) / 2, exponent / 3); // Minimum possible value is half ou… in cbrt_2deriv()
68 …T max = ldexp(static_cast<guess_type>(2.), exponent / 3); // Maximum possible value is twice our g… in cbrt_2deriv()
Droot_finding_n_example.cpp98 typedef double guess_type; // double may restrict (exponent) range for a multiprecision T? in nth_2deriv() typedef
101 …frexp(static_cast<guess_type>(x), &exponent); // Get exponent of z (ignore mantiss… in nth_2deriv()
102 …T guess = ldexp(static_cast<guess_type>(1.), exponent / N); // Rough guess is to divide the expo… in nth_2deriv()
103 …T min = ldexp(static_cast<guess_type>(1.) / 2, exponent / N); // Minimum possible value is half ou… in nth_2deriv()
104 …T max = ldexp(static_cast<guess_type>(2.), exponent / N); // Maximum possible value is twice o… in nth_2deriv()
Droot_n_finding_algorithms.cpp199 typedef double guess_type; in nth_root_noderiv() typedef
202 frexp(static_cast<guess_type>(x), &exponent); // Get exponent of z (ignore mantissa). in nth_root_noderiv()
203 …T guess = static_cast<T>(ldexp(static_cast<guess_type>(1.), exponent / N)); // Rough guess is to d… in nth_root_noderiv()
254 typedef double guess_type; in nth_root_1deriv() typedef
257 frexp(static_cast<guess_type>(x), &exponent); // Get exponent of z (ignore mantissa). in nth_root_1deriv()
258 …T guess = static_cast<T>(ldexp(static_cast<guess_type>(1.), exponent / N)); // Rough guess is to d… in nth_root_1deriv()
259 …T min = static_cast<T>(ldexp(static_cast<guess_type>(1.) / 2, exponent / N)); // Minimum possible … in nth_root_1deriv()
260 …T max = static_cast<T>(ldexp(static_cast<guess_type>(2.), exponent / N)); // Maximum possible valu… in nth_root_1deriv()
306 typedef double guess_type; in nth_root_2deriv() typedef
309 frexp(static_cast<guess_type>(x), &exponent); // Get exponent of z (ignore mantissa). in nth_root_2deriv()
[all …]
/third_party/python/Lib/
Dmimetypes.py103 def guess_type(self, url, strict=True): member in MimeTypes
289 def guess_type(url, strict=True): function
309 return _db.guess_type(url, strict)
637 guess, encoding = guess_type(gtype, strict)
/third_party/python/Doc/library/
Dmimetypes.rst29 .. function:: guess_type(url, strict=True)
64 type *type* by :func:`guess_type`.
66 The optional *strict* argument has the same meaning as with the :func:`guess_type` function.
75 :func:`guess_type`. If no extension can be guessed for *type*, ``None`` is
78 The optional *strict* argument has the same meaning as with the :func:`guess_type` function.
235 .. method:: MimeTypes.guess_type(url, strict=True)
237 Similar to the :func:`guess_type` function, using the tables stored as part of
Dhttp.server.rst380 type is guessed by calling the :meth:`guess_type` method, which in turn
/third_party/python/Tools/scripts/
Dserve.py18 type = mimetypes.guess_type(fn)[0]
/third_party/python/Doc/includes/
Demail-dir.py56 ctype, encoding = mimetypes.guess_type(path)
/third_party/boost/boost/multiprecision/detail/functions/
Dtrig.hpp523 typedef typename boost::multiprecision::detail::canonical<long double, T>::type guess_type; in eval_asin() typedef
525 typedef fp_type guess_type; in eval_asin() typedef
528 guess_type dd; in eval_asin()
531 result = (guess_type)(std::asin(dd)); in eval_asin()
/third_party/python/Lib/http/
Dserver.py702 ctype = self.guess_type(path)
862 def guess_type(self, path): member in SimpleHTTPRequestHandler
882 guess, _ = mimetypes.guess_type(path)
/third_party/googletest/googletest/scripts/
Dupload.py550 return mimetypes.guess_type(filename)[0] or 'application/octet-stream'
730 mimetype = mimetypes.guess_type(filename)[0]
/third_party/python/Lib/urllib/
Drequest.py1508 mtype = mimetypes.guess_type(filename)[0]
1574 mtype = mimetypes.guess_type(req.full_url)[0]
2020 mtype = mimetypes.guess_type(url)[0]
2087 mtype = mimetypes.guess_type("ftp:" + url)[0]
/third_party/python/Misc/NEWS.d/
D3.9.0a3.rst510 Proxy the `SimpleHTTPRequestHandler.guess_type` to `mimetypes.guess_type` so
D3.9.0a1.rst1339 :meth:`mimetypes.guess_type` due to improper handling of filenames as urls.
D3.8.0a1.rst2771 :meth:`mimetypes.MimeTypes.guess_type` now accepts :term:`path-like object`
/third_party/boost/libs/math/doc/roots/
Droot_finding_examples.qbk321 In these examples, `double` is used via `typedef double guess_type`.]
370 Even `show_cube_root(2.F);` will produce warnings because `typedef double guess_type` defines the t…
/third_party/python/Misc/
DHISTORY23723 found types. guess_type() and guess_extension() now accept an
28674 - mimetypes.py: guess_type() understands 'data' URLs.