- Sort Score
- Num 10 results
- Language All
Results 1 - 10 of 122 for decorate (0.06 seconds)
-
docs/en/docs/tutorial/handling-errors.md
And it also includes a default exception handler for it. To override it, import the `RequestValidationError` and use it with `@app.exception_handler(RequestValidationError)` to decorate the exception handler. The exception handler will receive a `Request` and the exception. {* ../../docs_src/handling_errors/tutorial004_py310.py hl[2,14:19] *}
Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Thu Mar 05 18:13:19 GMT 2026 - 8.9K bytes - Click Count (0) -
android/guava/src/com/google/common/util/concurrent/MoreExecutors.java
* right before each task is run. The renaming is best effort, if a {@link SecurityManager} * prevents the renaming then it will be skipped but the tasks will still execute. * * @param executor The executor to decorate * @param nameSupplier The source of names for each task */ @J2ktIncompatible @GwtIncompatible // concurrency static Executor renamingDecorator(Executor executor, Supplier<String> nameSupplier) {Created: Fri Apr 03 12:43:13 GMT 2026 - Last Modified: Wed Jan 28 22:39:02 GMT 2026 - 45.6K bytes - Click Count (0) -
docs/en/docs/tutorial/dependencies/dependencies-with-yield.md
* [`@contextlib.asynccontextmanager`](https://docs.python.org/3/library/contextlib.html#contextlib.asynccontextmanager) using them to decorate a function with a single `yield`. That's what **FastAPI** uses internally for dependencies with `yield`. But you don't have to use the decorators for FastAPI dependencies (and you shouldn't).
Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Thu Mar 05 18:13:19 GMT 2026 - 12.6K bytes - Click Count (0) -
okhttp/src/commonJvmAndroid/kotlin/okhttp3/internal/connection/FastFallbackExchangeFinder.kt
/** * Results are posted here as they occur. The find job is done when either one plan completes * successfully or all plans fail. */ private val connectResults = taskRunner.backend.decorate(LinkedBlockingDeque<ConnectResult>()) override fun find(): RealConnection { var firstException: IOException? = null try { while (tcpConnectsInFlight.isNotEmpty() || routePlanner.hasNext()) {
Created: Fri Apr 03 11:42:14 GMT 2026 - Last Modified: Tue Jan 27 09:00:39 GMT 2026 - 5.8K bytes - Click Count (0) -
docs/tr/docs/tutorial/handling-errors.md
Ve bunun için varsayılan bir exception handler da içerir. Override etmek için `RequestValidationError`’ı import edin ve exception handler’ı `@app.exception_handler(RequestValidationError)` ile decorate edin. Exception handler, bir `Request` ve exception’ı alır. {* ../../docs_src/handling_errors/tutorial004_py310.py hl[2,14:19] *} Artık `/items/foo`’ya giderseniz, şu varsayılan JSON hatası yerine:
Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Fri Mar 20 07:53:17 GMT 2026 - 9.7K bytes - Click Count (0) -
docs/tr/docs/tutorial/dependencies/dependencies-with-yield.md
* [`@contextlib.asynccontextmanager`](https://docs.python.org/3/library/contextlib.html#contextlib.asynccontextmanager) Bunları, tek bir `yield` içeren bir fonksiyonu decorate etmek için kullanabilirsiniz. FastAPI, `yield` kullanan dependency'ler için içeride bunu yapar. Ancak FastAPI dependency'leri için bu decorator'ları kullanmak zorunda değilsiniz (hatta kullanmamalısınız).
Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Fri Mar 20 07:53:17 GMT 2026 - 13.4K bytes - Click Count (0) -
fastapi/routing.py
def decorator(func: DecoratedCallable) -> DecoratedCallable: self.add_route( path, func, methods=methods, name=name, include_in_schema=include_in_schema, ) return func return decorator def add_api_route( self,Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Sun Mar 15 11:44:39 GMT 2026 - 193K bytes - Click Count (0) -
fastapi/applications.py
``` """ def decorator(func: DecoratedCallable) -> DecoratedCallable: self.add_api_websocket_route( path, func, name=name, dependencies=dependencies, ) return func return decorator def include_router( self,Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Wed Apr 01 16:16:24 GMT 2026 - 178.6K bytes - Click Count (0) -
docs/fr/docs/tutorial/first-steps.md
/// info | `@decorator` Info Cette syntaxe `@something` en Python est appelée un « décorateur ». Vous la mettez au-dessus d’une fonction. Comme un joli chapeau décoratif (j’imagine que c’est de là que vient le terme 🤷🏻♂). Un « décorateur » prend la fonction en dessous et fait quelque chose avec.
Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Thu Mar 19 18:37:13 GMT 2026 - 15.1K bytes - Click Count (0) -
docs/fr/docs/tutorial/dependencies/dependencies-in-path-operation-decorators.md
Dans ces cas, au lieu de déclarer un paramètre de *fonction de chemin d'accès* avec `Depends`, vous pouvez ajouter une `list` de `dependencies` au *décorateur de chemin d'accès*. ## Ajouter `dependencies` au *décorateur de chemin d'accès* { #add-dependencies-to-the-path-operation-decorator } Le *décorateur de chemin d'accès* accepte un argument optionnel `dependencies`. Il doit s'agir d'une `list` de `Depends()` :Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Thu Mar 19 18:37:13 GMT 2026 - 3.5K bytes - Click Count (0)