Symfony\Component\Form\FormBuilder::all PHP Method

all() public method

public all ( )
    public function all()
    {
        $this->resolveChildren();

        return $this->children;
    }

Usage Example

Example #1
0
 private function checkFormBuilderDeps(\Symfony\Component\Form\FormBuilder $builder, array &$elements, array &$requirments)
 {
     if ($builder->getCompound()) {
         $type = $builder->getType();
         if ($type instanceof \Symfony\Component\Form\Extension\DataCollector\Proxy\ResolvedTypeDataCollectorProxy) {
             $type = $type->getInnerType();
         }
         if (!$type instanceof \Symfony\Component\Form\Extension\Core\Type\ChoiceType) {
             foreach ($builder->all() as $child) {
                 $this->checkFormBuilderDeps($child, $elements, $requirments);
             }
         }
     }
     $options = $builder->getOptions();
     if (isset($options['sf_form_dynamic'])) {
         foreach ($options['sf_form_dynamic'] as $and) {
             foreach ($and as $_name => $values) {
                 $requirments[$_name] = true;
             }
         }
         $elements[$builder->getName()] = $options['sf_form_dynamic'];
     }
 }