Bristol SU Support Package
AndSpecification.php
Go to the documentation of this file.
1 <?php
2 
3 
5 
6 
8 
13 {
14 
20  private $specifications;
21 
25  public function __construct(...$specifications)
26  {
27  $this->specifications = $specifications;
28  }
29 
35  public function isSatisfied() : bool
36  {
37  foreach ($this->specifications as $specification) {
38  if (!$specification->isSatisfied()) {
39  return false;
40  }
41  }
42 
43  return true;
44  }
45 
46 }