interface CheckpointListInterface
Same name in other branches
- 10 core/lib/Drupal/Core/Config/Checkpoint/CheckpointListInterface.php \Drupal\Core\Config\Checkpoint\CheckpointListInterface
Maintains a list of checkpoints.
@internal This API is experimental.
@phpstan-extends \IteratorAggregate<string, \Drupal\Core\Config\Checkpoint\Checkpoint>
Hierarchy
- interface \Drupal\Core\Config\Checkpoint\CheckpointListInterface extends \Drupal\Core\Config\Checkpoint\IteratorAggregate \Drupal\Core\Config\Checkpoint\Countable
Expanded class hierarchy of CheckpointListInterface
All classes that implement CheckpointListInterface
See also
\Drupal\Core\Config\Checkpoint\Checkpoint
File
-
core/
lib/ Drupal/ Core/ Config/ Checkpoint/ CheckpointListInterface.php, line 17
Namespace
Drupal\Core\Config\CheckpointView source
interface CheckpointListInterface extends \IteratorAggregate, \Countable {
/**
* Gets the active checkpoint.
*
* @return \Drupal\Core\Config\Checkpoint\Checkpoint|null
* The active checkpoint or NULL if there are no checkpoints.
*/
public function getActiveCheckpoint() : ?Checkpoint;
/**
* Gets a checkpoint.
*
* @param string $id
* The checkpoint ID.
*
* @return \Drupal\Core\Config\Checkpoint\Checkpoint
* The checkpoint.
*
* @throws \Drupal\Core\Config\Checkpoint\UnknownCheckpointException
* Thrown when the provided checkpoint does not exist.
*/
public function get(string $id) : Checkpoint;
/**
* Gets a checkpoint's parents.
*
* @param string $id
* The checkpoint ID.
*
* @return iterable<string, \Drupal\Core\Config\Checkpoint\Checkpoint>
*/
public function getParents(string $id) : iterable;
/**
* Adds a new checkpoint.
*
* @param string $id
* The ID of the checkpoint add.
* @param string|\Stringable $label
* The checkpoint label.
*
* @return \Drupal\Core\Config\Checkpoint\Checkpoint
* The new checkpoint, which is now at the end of the checkpoint sequence.
*
* @throws \Drupal\Core\Config\Checkpoint\CheckpointExistsException
* Thrown when the ID already exists.
*/
public function add(string $id, string|\Stringable $label) : Checkpoint;
/**
* Deletes a checkpoint.
*
* @param string $id
* The ID of the checkpoint to delete up to: only checkpoints after this one
* will remain.
*
* @return $this
*
* @throws \Drupal\Core\Config\Checkpoint\UnknownCheckpointException
* Thrown when provided checkpoint ID does not exist.
*/
public function delete(string $id) : static;
/**
* Deletes all checkpoints.
*
* @return $this
*/
public function deleteAll() : static;
}
Members
Title Sort descending | Modifiers | Object type | Summary | Overrides |
---|---|---|---|---|
CheckpointListInterface::add | public | function | Adds a new checkpoint. | 1 |
CheckpointListInterface::delete | public | function | Deletes a checkpoint. | 1 |
CheckpointListInterface::deleteAll | public | function | Deletes all checkpoints. | 1 |
CheckpointListInterface::get | public | function | Gets a checkpoint. | 1 |
CheckpointListInterface::getActiveCheckpoint | public | function | Gets the active checkpoint. | 1 |
CheckpointListInterface::getParents | public | function | Gets a checkpoint's parents. | 1 |
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.