public function addForm(FormObject $form)
    {
        if (true === $this->hasForm($form->getClassName(), $form->getName())) {
            throw DuplicateEntryException::formWasAlreadyRegistered($form);
        }

        $form->getConfiguration()->setParents([$this]);

        $this->forms[$form->getClassName()][$form->getName()] = $form;
    }
public function addForm(FormObject $form)
    {
        if (true === $this->hasForm($form->getClassName(), $form->getName())) {
            throw DuplicateEntryException::formWasAlreadyRegistered($form);
        }

        $form->getConfiguration()->setParents([$this]);

        $this->forms[$form->getClassName()][$form->getName()] = $form;
    }
public function addForm ( FormObject $ form ) { if ( true === $ this -> hasForm ( $ form -> getClassName ( ) , $ form -> getName ( ) ) ) { throw DuplicateEntryException :: formWasAlreadyRegistered ( $ form ) ; } $ form -> getConfiguration ( ) -> setParents ( [ $ this ] ) ; $ this -> forms [ $ form -> getClassName ( ) ] [ $ form -> getName ( ) ] = $ form ; }
Adds a form to the forms list of this FormZ configuration. Note that this
function will also handle the parent service from the
`configuration_object` extension.

@param FormObject $form
@throws DuplicateEntryException
Adds a form to the forms list of this FormZ configuration . Note that this function will also handle the parent service from the configuration_object extension .