Code Coverage
 
Lines
Branches
Paths
Functions and Methods
Classes and Traits
Total
n/a
0 / 0
n/a
0 / 0
n/a
0 / 0
n/a
0 / 0
CRAP
n/a
0 / 0
1<?php
2
3declare(strict_types=1);
4
5namespace Drupal\display_builder;
6
7/**
8 * Provides an interface defining a display builder instance entity type.
9 */
10interface PublishableInterface {
11
12  /**
13   * Check display has required context, meaning it can save value.
14   *
15   * @return bool
16   *   True if required, False otherwise.
17   */
18  public function isPublishable(): bool;
19
20  /**
21   * Check display has required context, meaning it can save value.
22   *
23   * @param string $key
24   *   The context key to look for.
25   * @param \Drupal\Core\Plugin\Context\ContextInterface[] $contexts
26   *   (Optional) contexts if already accessible, keyed by context name.
27   *
28   * @return bool
29   *   True if required, False otherwise.
30   */
31  public function hasSaveContextsRequirement(string $key, array $contexts = []): bool;
32
33  /**
34   * If display builder has been saved.
35   *
36   * @return bool
37   *   Has save data.
38   */
39  public function isPublished(): bool;
40
41  /**
42   * The save value is the current value of display builder.
43   *
44   * @return bool
45   *   The save is the current or not.
46   */
47  public function isPublishedPresent(): bool;
48
49  /**
50   * Restore to the last saved state.
51   */
52  public function restore(): void;
53
54}

Paths

Below are the source code lines that represent each code path as identified by Xdebug. Please note a path is not necessarily coterminous with a line, a line may contain multiple paths and therefore show up more than once. Please also be aware that some paths may include implicit rather than explicit branches, e.g. an if statement always has an else as part of its logical flow even if you didn't write one.