| 1: | <?php |
| 2: | |
| 3: | namespace LaravelUi5\Core\Ui5\Capabilities; |
| 4: | |
| 5: | /** |
| 6: | * Contract for UI5 Data Providers. |
| 7: | * |
| 8: | * A DataProvider encapsulates read-only, idempotent logic for delivering |
| 9: | * structured data to UI5 artifacts such as Cards, Resources, or Reports. |
| 10: | * |
| 11: | * Responsibilities: |
| 12: | * - Assemble domain-specific data in a backend-driven way. |
| 13: | * - Return results in a structured array suitable for JSON serialization. |
| 14: | * |
| 15: | * Notes: |
| 16: | * - DataProviders must not perform state-changing operations. |
| 17: | * - Dependencies (services, repositories) should be injected via constructor DI. |
| 18: | * - The return array should be normalized (arrays, scalars, nested objects), |
| 19: | * not raw models or resources. |
| 20: | */ |
| 21: | interface DataProviderInterface |
| 22: | { |
| 23: | } |
| 24: |