lifecycle_guard_platform_interface 1.0.1
lifecycle_guard_platform_interface: ^1.0.1 copied to clipboard
Platform interface for lifecycle_guard - defines the contract for background execution.
🧩 lifecycle_guard_platform_interface #
The common interface contract for mission-critical background execution.
This package defines the glue that holds lifecycle_guard together across all platforms.
🚀 Purpose #
This is a Platform Interface package as defined by the Federated Plugins architecture.
It defines the LifecycleGuardPlatform abstract class that all platform-specific implementations (like lifecycle_guard_android and lifecycle_guard_ios) must implement.
Why separate the interface? #
- Strong Typing: Ensures all platforms follow the exact same API.
- Extensibility: Community members can add support for Windows, Linux, or Web just by implementing this interface.
- Stability: Changes to the main app-facing package don't break the native implementations.
🛠️ For Contributors #
If you want to add support for a new platform:
- Create a new package (e.g.,
lifecycle_guard_windows). - Depend on this package.
- Extend
LifecycleGuardPlatform. - Register your implementation.
📄 License #
BSD 3-Clause License — see LICENSE for details.
Built with ❤️ by Crealify