/**
  * @param OptionsResolverInterface $resolver
  */
 public function setDefaultOptions(OptionsResolverInterface $resolver)
 {
     $resolver->setRequired(['type']);
     $resolver->addAllowedTypes(['type' => ['string']]);
     $resolver->setAllowedValues(['type' => Participant::getAllTypes()]);
     $resolver->setDefaults(['data_class' => Participant::class]);
 }
 /**
  * @param OptionsResolverInterface $optionsResolver
  * @param BlockInterface           $block
  */
 protected function setDefaultSettings(OptionsResolverInterface $optionsResolver, BlockInterface $block)
 {
     // defaults for all blocks
     $optionsResolver->setDefaults(array('use_cache' => true, 'extra_cache_keys' => array(), 'attr' => array(), 'template' => false, 'ttl' => (int) $block->getTtl()));
     $optionsResolver->addAllowedTypes(array('use_cache' => array('bool'), 'extra_cache_keys' => array('array'), 'attr' => array('array'), 'ttl' => array('int'), 'template' => array('string', 'bool')));
     // add type and class settings for block
     $class = ClassUtils::getClass($block);
     $settingsByType = isset($this->settingsByType[$block->getType()]) ? $this->settingsByType[$block->getType()] : array();
     $settingsByClass = isset($this->settingsByClass[$class]) ? $this->settingsByClass[$class] : array();
     $optionsResolver->setDefaults(array_merge($settingsByType, $settingsByClass));
 }
 /**
  * {@inheritDoc}
  */
 public function setDefaultOptions(OptionsResolverInterface $resolver)
 {
     $resolver->setDefaults(array('disabled_settings' => array()));
     $resolver->addAllowedTypes(array('disabled_settings' => 'array'));
 }
 /**
  * {@inheritdoc}
  */
 public function setDefaultOptions(OptionsResolverInterface $resolver)
 {
     $resolver->setDefaults(array('enable' => $this->container->getParameter('bootstrapp.ckeditor.enable'), 'base_path' => $this->container->getParameter('bootstrapp.ckeditor.base_path'), 'config_name' => $this->container->getParameter('bootstrapp.ckeditor.default_config'), 'config' => array(), 'plugins' => array()));
     $resolver->addAllowedTypes(array('enable' => 'bool', 'config_name' => array('string', 'null'), 'base_path' => array('string'), 'config' => 'array', 'plugins' => 'array'));
 }
    /**
     * {@inheritdoc}
     */
    public function setDefaultSettings(OptionsResolverInterface $resolver)
    {
        $resolver->setDefaults(array(
            'template'       => $this->template,
            'divisible_by'    => 0,
            'divisible_class' => '',
            'child_class'     => '',
        ));

        $resolver->addAllowedTypes(array(
            'divisible_by'    => array('integer'),
            'divisible_class' => array('string'),
            'child_class'     => array('string'),
        ));
    }