Home / Class/ MySuperContextManager Class — fastapi Architecture

MySuperContextManager Class — fastapi Architecture

Architecture documentation for the MySuperContextManager class in tutorial010_py39.py from the fastapi codebase.

Entity Profile

Dependency Diagram

graph TD
  1db49c27_fae3_2c3b_3769_0fdab2cf02f3["MySuperContextManager"]
  6cfacb3b_8c48_2f4e_4b08_ce243e5897ec["tutorial010_py39.py"]
  1db49c27_fae3_2c3b_3769_0fdab2cf02f3 -->|defined in| 6cfacb3b_8c48_2f4e_4b08_ce243e5897ec
  7a9ce891_5307_2d32_c4b5_9150037532bb["__init__()"]
  1db49c27_fae3_2c3b_3769_0fdab2cf02f3 -->|method| 7a9ce891_5307_2d32_c4b5_9150037532bb
  60065755_ca73_c0b7_7cb8_d5bd3851b896["__enter__()"]
  1db49c27_fae3_2c3b_3769_0fdab2cf02f3 -->|method| 60065755_ca73_c0b7_7cb8_d5bd3851b896
  41476656_4a28_d08a_0f7a_6501a332eee0["__exit__()"]
  1db49c27_fae3_2c3b_3769_0fdab2cf02f3 -->|method| 41476656_4a28_d08a_0f7a_6501a332eee0

Relationship Graph

Source Code

docs_src/dependencies/tutorial010_py39.py lines 1–9

class MySuperContextManager:
    def __init__(self):
        self.db = DBSession()

    def __enter__(self):
        return self.db

    def __exit__(self, exc_type, exc_value, traceback):
        self.db.close()

Domain

Frequently Asked Questions

What is the MySuperContextManager class?
MySuperContextManager is a class in the fastapi codebase, defined in docs_src/dependencies/tutorial010_py39.py.
Where is MySuperContextManager defined?
MySuperContextManager is defined in docs_src/dependencies/tutorial010_py39.py at line 1.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free