Ejemplo n.º 1
0
 /**
  * Check all rules in collection
  *
  * @param Subject $subject
  *
  * @return ResultCollection
  */
 public function check(Subject $subject) : ResultCollection
 {
     $resultCollection = new ResultCollection();
     foreach ($this->collection as $rule) {
         $resultCollection->merge($rule->check($subject));
     }
     return $resultCollection;
 }