From 4ce65d59ca91871cfd126497158200a818720bce Mon Sep 17 00:00:00 2001 From: Daniel Baumann <daniel.baumann@progress-linux.org> Date: Sat, 13 Apr 2024 13:30:08 +0200 Subject: Adding upstream version 0.13.1. Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org> --- vendor/ipl/scheduler/src/Contract/Task.php | 39 ++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) create mode 100644 vendor/ipl/scheduler/src/Contract/Task.php (limited to 'vendor/ipl/scheduler/src/Contract/Task.php') diff --git a/vendor/ipl/scheduler/src/Contract/Task.php b/vendor/ipl/scheduler/src/Contract/Task.php new file mode 100644 index 0000000..db09ddc --- /dev/null +++ b/vendor/ipl/scheduler/src/Contract/Task.php @@ -0,0 +1,39 @@ +<?php + +namespace ipl\Scheduler\Contract; + +use Ramsey\Uuid\UuidInterface; +use React\Promise\ExtendedPromiseInterface; + +interface Task +{ + /** + * Get the name of this task + * + * @return string + */ + public function getName(): string; + + /** + * Get unique identifier of this task + * + * @return UuidInterface + */ + public function getUuid(): UuidInterface; + + /** + * Get the description of this task + * + * @return ?string + */ + public function getDescription(): ?string; + + /** + * Run this tasks operations + * + * This commits the actions in a non-blocking fashion to the event loop and yields a deferred promise + * + * @return ExtendedPromiseInterface + */ + public function run(): ExtendedPromiseInterface; +} -- cgit v1.2.3