bundles/BlockManagerDebugBundle/DataCollector/BlockManagerDataCollector.php
public function collectRule(Rule $rule): void
    {
        $this->data['rule'] = [
            'id' => $rule->getId(),
        ];

        foreach ($rule->getTargets() as $target) {
            $this->data['rule']['targets'][] = [
                'type' => $target->getTargetType()::getType(),
                'value' => $this->formatVar($target->getValue()),
            ];
        }

        foreach ($rule->getConditions() as $condition) {
            $this->data['rule']['conditions'][] = [
                'type' => $condition->getConditionType()::getType(),
                'value' => $this->formatVar($condition->getValue()),
            ];
        }
    }
public function collectRule(Rule $rule): void
    {
        $this->data['rule'] = [
            'id' => $rule->getId(),
        ];

        foreach ($rule->getTargets() as $target) {
            $this->data['rule']['targets'][] = [
                'type' => $target->getTargetType()::getType(),
                'value' => $this->formatVar($target->getValue()),
            ];
        }

        foreach ($rule->getConditions() as $condition) {
            $this->data['rule']['conditions'][] = [
                'type' => $condition->getConditionType()::getType(),
                'value' => $this->formatVar($condition->getValue()),
            ];
        }
    }
public function collectRule ( Rule $ rule ) : void { $ this -> data [ 'rule' ] = [ 'id' => $ rule -> getId ( ) , ] ; foreach ( $ rule -> getTargets ( ) as $ target ) { $ this -> data [ 'rule' ] [ 'targets' ] [ ] = [ 'type' => $ target -> getTargetType ( ) :: getType ( ) , 'value' => $ this -> formatVar ( $ target -> getValue ( ) ) , ] ; } foreach ( $ rule -> getConditions ( ) as $ condition ) { $ this -> data [ 'rule' ] [ 'conditions' ] [ ] = [ 'type' => $ condition -> getConditionType ( ) :: getType ( ) , 'value' => $ this -> formatVar ( $ condition -> getValue ( ) ) , ] ; } }
Collects the rule data.
Collects the rule data .