- Sort Score
- Result 10 results
- Languages All
Results 1 - 4 of 4 for __ (0.13 sec)
-
docs/en/docs/advanced/advanced-dependencies.md
{!> ../../../docs_src/dependencies/tutorial011.py!} ``` In this case, this `__call__` is what **FastAPI** will use to check for additional parameters and sub-dependencies, and this is what will be called to pass a value to the parameter in your *path operation function* later. ## Parameterize the instance And now, we can use `__init__` to declare the parameters of the instance that we can use to "parameterize" the dependency:
Plain Text - Registered: Sun May 05 07:19:11 GMT 2024 - Last Modified: Tue Oct 17 05:59:11 GMT 2023 - 3.9K bytes - Viewed (0) -
docs/de/docs/advanced/advanced-dependencies.md
``` In diesem Fall ist dieses `__call__` das, was **FastAPI** verwendet, um nach zusätzlichen Parametern und Unterabhängigkeiten zu suchen, und das ist es auch, was später aufgerufen wird, um einen Wert an den Parameter in Ihrer *Pfadoperation-Funktion* zu übergeben. ## Die Instanz parametrisieren
Plain Text - Registered: Sun May 05 07:19:11 GMT 2024 - Last Modified: Sat Mar 30 20:18:49 GMT 2024 - 4.3K bytes - Viewed (0) -
docs/zh/docs/advanced/advanced-dependencies.md
这里说的不是类本身(类本就是可调用项),而是类实例。 为此,需要声明 `__call__` 方法: ```Python hl_lines="10" {!../../../docs_src/dependencies/tutorial011.py!} ``` 本例中,**FastAPI** 使用 `__call__` 检查附加参数及子依赖项,稍后,还要调用它向*路径操作函数*传递值。 ## 参数化实例 接下来,使用 `__init__` 声明用于**参数化**依赖项的实例参数: ```Python hl_lines="7" {!../../../docs_src/dependencies/tutorial011.py!} ``` 本例中,**FastAPI** 不使用 `__init__`,我们要直接在代码中使用。 ## 创建实例 使用以下代码创建类实例:
Plain Text - Registered: Sun May 05 07:19:11 GMT 2024 - Last Modified: Sun Jan 28 18:26:57 GMT 2024 - 2K bytes - Viewed (0) -
docs/em/docs/advanced/advanced-dependencies.md
🐍 📤 🌌 ⚒ 👐 🎓 "🇧🇲". 🚫 🎓 ⚫️ (❔ ⏪ 🇧🇲), ✋️ 👐 👈 🎓. 👈, 👥 📣 👩🔬 `__call__`: ```Python hl_lines="10" {!../../../docs_src/dependencies/tutorial011.py!} ``` 👉 💼, 👉 `__call__` ⚫️❔ **FastAPI** 🔜 ⚙️ ✅ 🌖 🔢 & 🎧-🔗, & 👉 ⚫️❔ 🔜 🤙 🚶♀️ 💲 🔢 👆 *➡ 🛠️ 🔢* ⏪. ## 🔗 👐 & 🔜, 👥 💪 ⚙️ `__init__` 📣 🔢 👐 👈 👥 💪 ⚙️ "🔗" 🔗: ```Python hl_lines="7"
Plain Text - Registered: Sun May 05 07:19:11 GMT 2024 - Last Modified: Sat Apr 01 09:26:04 GMT 2023 - 2K bytes - Viewed (0)