- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 10 for GzipRequest (0.04 sec)
-
docs/ru/docs/how-to/custom-request-and-route.md
/// Единственное, что делает по-другому функция, возвращённая `GzipRequest.get_route_handler`, — преобразует `Request` в `GzipRequest`. Благодаря этому наш `GzipRequest` позаботится о распаковке данных (при необходимости) до передачи их в наши *операции пути*. Дальше вся логика обработки остаётся прежней.
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Thu Dec 11 21:25:03 UTC 2025 - 7.2K bytes - Viewed (0) -
docs/es/docs/how-to/custom-request-and-route.md
/// La única cosa que la función devuelta por `GzipRequest.get_route_handler` hace diferente es convertir el `Request` en un `GzipRequest`. Haciendo esto, nuestro `GzipRequest` se encargará de descomprimir los datos (si es necesario) antes de pasarlos a nuestras *path operations*. Después de eso, toda la lógica de procesamiento es la misma.
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Tue Dec 16 16:33:45 UTC 2025 - 5K bytes - Viewed (0) -
docs/de/docs/how-to/custom-request-and-route.md
/// Das Einzige, was die von `GzipRequest.get_route_handler` zurückgegebene Funktion anders macht, ist die Konvertierung von `Request` in ein `GzipRequest`. Dabei kümmert sich unser `GzipRequest` um die Dekomprimierung der Daten (falls erforderlich), bevor diese an unsere *Pfadoperationen* weitergegeben werden.
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Wed Dec 10 13:54:34 UTC 2025 - 5.7K bytes - Viewed (0) -
docs/en/docs/how-to/custom-request-and-route.md
/// The only thing the function returned by `GzipRequest.get_route_handler` does differently is convert the `Request` to a `GzipRequest`. Doing this, our `GzipRequest` will take care of decompressing the data (if necessary) before passing it to our *path operations*. After that, all of the processing logic is the same.
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Wed Dec 10 08:55:32 UTC 2025 - 4.6K bytes - Viewed (0) -
docs_src/custom_request_and_route/tutorial001_an_py39.py
import gzip from typing import Annotated, Callable from fastapi import Body, FastAPI, Request, Response from fastapi.routing import APIRoute class GzipRequest(Request): async def body(self) -> bytes: if not hasattr(self, "_body"): body = await super().body() if "gzip" in self.headers.getlist("Content-Encoding"): body = gzip.decompress(body) self._body = bodyRegistered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Wed Dec 10 08:55:32 UTC 2025 - 988 bytes - Viewed (0) -
docs/pt/docs/how-to/custom-request-and-route.md
/// A única coisa que a função retornada por `GzipRequest.get_route_handler` faz de diferente é converter o `Request` para um `GzipRequest`. Fazendo isso, nosso `GzipRequest` irá cuidar de descomprimir os dados (se necessário) antes de passá-los para nossas *operações de rota*. Depois disso, toda a lógica de processamento é a mesma.
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Tue Dec 16 20:32:40 UTC 2025 - 5.1K bytes - Viewed (0) -
docs_src/custom_request_and_route/tutorial001_py310.py
import gzip from collections.abc import Callable from fastapi import Body, FastAPI, Request, Response from fastapi.routing import APIRoute class GzipRequest(Request): async def body(self) -> bytes: if not hasattr(self, "_body"): body = await super().body() if "gzip" in self.headers.getlist("Content-Encoding"): body = gzip.decompress(body) self._body = bodyRegistered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Wed Dec 10 08:55:32 UTC 2025 - 976 bytes - Viewed (0) -
docs_src/custom_request_and_route/tutorial001_py39.py
import gzip from typing import Callable from fastapi import Body, FastAPI, Request, Response from fastapi.routing import APIRoute class GzipRequest(Request): async def body(self) -> bytes: if not hasattr(self, "_body"): body = await super().body() if "gzip" in self.headers.getlist("Content-Encoding"): body = gzip.decompress(body) self._body = body return self._bodyRegistered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Wed Dec 10 08:55:32 UTC 2025 - 967 bytes - Viewed (0) -
docs_src/custom_request_and_route/tutorial001_an_py310.py
import gzip from collections.abc import Callable from typing import Annotated from fastapi import Body, FastAPI, Request, Response from fastapi.routing import APIRoute class GzipRequest(Request): async def body(self) -> bytes: if not hasattr(self, "_body"): body = await super().body() if "gzip" in self.headers.getlist("Content-Encoding"): body = gzip.decompress(body)Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Wed Dec 10 08:55:32 UTC 2025 - 1015 bytes - Viewed (0) -
tests/test_tutorial/test_custom_request_and_route/test_tutorial001.py
assert response.json() == {"sum": n} def test_request_class(client: TestClient): response = client.get("/check-class")
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Wed Dec 17 20:41:43 UTC 2025 - 1.3K bytes - Viewed (0)