[FEATURE] Add Auto-Registration and Dependency Resolution to DI Container in Pancake #237
Labels
🧠 backlog
Items that are in the backlog for future work
♻️ code quality
Code quality-related tasks or issues
📝 documentation
Tasks related to writing or updating documentation
enhancement
New feature or request
gitauto
GitAuto label to trigger the app in a issue.
🕔 high effort
A task that can be completed in a few days
🧑💻 tech-debit
Technical debt that needs to be addressed
🧪 tests
Tasks related to testing
🛠 WIP
Work in progress
Description:
I would like to enhance the DI Container in the Pancake project to support auto-registration for services that are not explicitly registered in the container. This auto-registration feature should be enabled by default but configurable via a flag. Additionally, the container should be able to automatically resolve all dependencies, including constructor dependencies, for services that are auto-registered.
Related to #235
Below is an updated code example for the DIContainer class illustrating the requested functionality:
Updated DIContainer Example
New Features:
Auto-Registration of Services:
setAutoRegisterEnabled
method.Dependency Resolution:
Example of Auto-Registration:
Task Requirements:
Additional Requirements:
Acceptance Criteria:
The text was updated successfully, but these errors were encountered: