- Sort Score
- Result 10 results
- Languages All
Results 1 - 5 of 5 for get_route_handler (0.1 sec)
-
docs/de/docs/how-to/custom-request-and-route.md
### Eine benutzerdefinierte `GzipRoute`-Klasse erstellen Als Nächstes erstellen wir eine benutzerdefinierte Unterklasse von `fastapi.routing.APIRoute`, welche `GzipRequest` nutzt. Dieses Mal wird die Methode `APIRoute.get_route_handler()` überschrieben. Diese Methode gibt eine Funktion zurück. Und diese Funktion empfängt einen Request und gibt eine Response zurück.
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sun Oct 06 20:36:54 UTC 2024 - 5.2K bytes - Viewed (0) -
docs/pt/docs/how-to/custom-request-and-route.md
``` ### Criar uma classe `GzipRoute` personalizada Em seguida, criamos uma subclasse personalizada de `fastapi.routing.APIRoute` que fará uso do `GzipRequest`. Dessa vez, ele irá sobrescrever o método `APIRoute.get_route_handler()`. Esse método retorna uma função. E essa função é o que irá receber uma requisição e retornar uma resposta. Aqui nós usamos para criar um `GzipRequest` a partir da requisição original. ```Python hl_lines="18-26"
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Tue Oct 22 17:33:00 UTC 2024 - 4.9K bytes - Viewed (0) -
docs/em/docs/how-to/custom-request-and-route.md
```Python hl_lines="8-15" {!../../docs_src/custom_request_and_route/tutorial001.py!} ``` ### ✍ 🛃 `GzipRoute` 🎓 ⏭, 👥 ✍ 🛃 🏿 `fastapi.routing.APIRoute` 👈 🔜 ⚒ ⚙️ `GzipRequest`. 👉 🕰, ⚫️ 🔜 📁 👩🔬 `APIRoute.get_route_handler()`. 👉 👩🔬 📨 🔢. & 👈 🔢 ⚫️❔ 🔜 📨 📨 & 📨 📨. 📥 👥 ⚙️ ⚫️ ✍ `GzipRequest` ⚪️➡️ ⏮️ 📨. ```Python hl_lines="18-26" {!../../docs_src/custom_request_and_route/tutorial001.py!} ```
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sun Oct 06 20:36:54 UTC 2024 - 3.6K bytes - Viewed (0) -
docs/en/docs/how-to/custom-request-and-route.md
### Create a custom `GzipRoute` class Next, we create a custom subclass of `fastapi.routing.APIRoute` that will make use of the `GzipRequest`. This time, it will overwrite the method `APIRoute.get_route_handler()`. This method returns a function. And that function is what will receive a request and return a response. Here we use it to create a `GzipRequest` from the original request.
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sun Oct 27 22:39:38 UTC 2024 - 4.3K bytes - Viewed (0) -
fastapi/routing.py
flat_dependant=self._flat_dependant, name=self.unique_id, embed_body_fields=self._embed_body_fields, ) self.app = request_response(self.get_route_handler()) def get_route_handler(self) -> Callable[[Request], Coroutine[Any, Any, Response]]: return get_request_handler( dependant=self.dependant, body_field=self.body_field,
Registered: Sun Nov 03 07:19:11 UTC 2024 - Last Modified: Sat Oct 12 09:44:57 UTC 2024 - 172.1K bytes - Viewed (0)