WP_CLI
11 months ago
abstracts
11 months ago
actions
1 year ago
data-stores
11 months ago
migration
1 year ago
schedules
1 year ago
schema
11 months ago
ActionScheduler_ActionClaim.php
1 year ago
ActionScheduler_ActionFactory.php
1 year ago
ActionScheduler_AdminView.php
1 year ago
ActionScheduler_AsyncRequest_QueueRunner.php
1 year ago
ActionScheduler_Compatibility.php
1 year ago
ActionScheduler_DataController.php
11 months ago
ActionScheduler_DateTime.php
1 year ago
ActionScheduler_Exception.php
3 years ago
ActionScheduler_FatalErrorMonitor.php
1 year ago
ActionScheduler_InvalidActionException.php
1 year ago
ActionScheduler_ListTable.php
1 year ago
ActionScheduler_LogEntry.php
1 year ago
ActionScheduler_NullLogEntry.php
1 year ago
ActionScheduler_OptionLock.php
1 year ago
ActionScheduler_QueueCleaner.php
1 year ago
ActionScheduler_QueueRunner.php
1 year ago
ActionScheduler_RecurringActionScheduler.php
11 months ago
ActionScheduler_SystemInformation.php
1 year ago
ActionScheduler_Versions.php
1 year ago
ActionScheduler_WPCommentCleaner.php
1 year ago
ActionScheduler_wcSystemStatus.php
11 months ago
ActionScheduler_ActionClaim.php
46 lines
| 1 | <?php |
| 2 | |
| 3 | /** |
| 4 | * Class ActionScheduler_ActionClaim |
| 5 | */ |
| 6 | class ActionScheduler_ActionClaim { |
| 7 | /** |
| 8 | * Claim ID. |
| 9 | * |
| 10 | * @var string |
| 11 | */ |
| 12 | private $id = ''; |
| 13 | |
| 14 | /** |
| 15 | * Claimed action IDs. |
| 16 | * |
| 17 | * @var int[] |
| 18 | */ |
| 19 | private $action_ids = array(); |
| 20 | |
| 21 | /** |
| 22 | * Construct. |
| 23 | * |
| 24 | * @param string $id Claim ID. |
| 25 | * @param int[] $action_ids Action IDs. |
| 26 | */ |
| 27 | public function __construct( $id, array $action_ids ) { |
| 28 | $this->id = $id; |
| 29 | $this->action_ids = $action_ids; |
| 30 | } |
| 31 | |
| 32 | /** |
| 33 | * Get claim ID. |
| 34 | */ |
| 35 | public function get_id() { |
| 36 | return $this->id; |
| 37 | } |
| 38 | |
| 39 | /** |
| 40 | * Get IDs of claimed actions. |
| 41 | */ |
| 42 | public function get_actions() { |
| 43 | return $this->action_ids; |
| 44 | } |
| 45 | } |
| 46 |