@param bool $defaultsDisabled

@return self
961931
private function setDefaultsDisabled(bool $defaultsDisabled): self
    {
        $this->updatePropertyValue(
            DefaultsDisabledFieldInterface::PROP_DEFAULTS_DISABLED,
            $defaultsDisabled
        );

        return $this;
    }
1151824
public function disableViewCheck(bool $disable = true)
    {
        if ($disable) {
            array_delete($this->checkboxes, 'view');
        } elseif (!in_array('view', $this->checkboxes)) {
            array_push($this->checkboxes, 'view');
        }

        return $this;
    }
817395
public function filter()
    {
        if ($this->get('disabled')) {
            return $this;
        }

        $filter = $this->getFilter();

        if (is_callable($filter)) {
            $this->value = call_user_func($filter, $this->value);
        } else {
            $this->value = $filter->clean($this->value);
        }

        return $this;
    }
1287393
public function setDefaultValue($defaultValue): Parameter
    {
        $this->isOptional = true;
        $this->defaultValue = $defaultValue;

        return $this;
    }
503464
public function disableCreatingCheck(bool $disable = true)
    {
        $this->builder()->getFooter()->disableCreatingCheck($disable);

        return $this;
    }
1090903
public function setDbOnly($flag = true)
    {
        $flag = (bool)$flag;
        if ($this->dbOnly !== $flag) {
            $this->clear();
            $this->dbOnly = $flag;
        }
        return $this;
    }
1224295
public function enable($enable = true)
    {
        if (! is_bool($enable)) {
            throw new InvalidArgumentException("enable must be a boolean. [$enable] given.");
        }

        $this->enabled = $enable;

        return $this;
    }
711409
public function setDefaults(array $defaults)
    {
        foreach ($defaults as $option => $value) {
            $this->setDefault($option, $value);
        }

        return $this;
    }
662927
public function setDefaults(array $defaults): self
    {
        foreach ((array)$defaults as $key => $value) {
            if (isset($this->defaults[$key])) {
                $this->defaults[$key] = $value;
            } else {
                throw new Exception('Invalid route default', Exception::HTTP_INTERNAL_SERVER_ERROR);
            }
        }

        return $this;
    }
510922
public function setEnabled($enabled) {

        $ena = DataFilter::filterBoolean($enabled);

        $this->enabled = $ena;

        return $this;

    }
644899
protected function setDefault($default)
    {
        if ($this->isNullable() && $default === null) {
            $this->default = 'null';

            return $this;
        }

        if ($default === null) {
            $this->default = '';

            return $this;
        }

        switch ($this->getType()->getType()) {
            case 'string':
                $this->default = "'" . $default . "'";
                break;
            case 'bool':
                $this->default = var_export((bool) $default, true);
                break;
            default:
                $this->default = $default;
        }

        return $this;
    }
1211107
public function disableViewCheck(bool $disable = true)
    {
        $this->builder()->getFooter()->disableViewCheck($disable);

        return $this;
    }
215260
public function setEnabled(bool $enabled = true): bool
    {
        $was = $this->enabled;
        $this->enabled = $enabled;

        return $was;
    }
567585
public function enable()
    {
        if ($this->autoEnabled) {
            $this->autoEnabled = false;
            $this->discard();
        }

        $enabled = $this->box('doEnable', false);

        if ($enabled && self::$probe === $this && null !== $this->outputStream) {
            self::boxPostEnable();
        }

        return $enabled;
    }
261705
public function setStrictVariables(bool $isEnabled = true): self
    {
        if ($isEnabled) {
            $this->twigEnvironment->enableStrictVariables();
        } else {
            $this->twigEnvironment->disableStrictVariables();
        }

        return $this;
    }
812626
public function setSSL($isEnabled)
    {
        if (!is_bool($isEnabled)) {
            throw new InvalidArgumentException(
                sprintf('%s only accepts a boolean', __FUNCTION__)
            );
        }

        $this->ssl = (bool)$isEnabled;

        return $this;
    }
162578
public function setAttachmentDefaults($defaults)
    {
        if ($this->attachmentDefaults != ($defaults = (array) $defaults)) {
            $this->attachmentDefaults = $defaults;

            $this->setAttachments($this->attachments);
        }

        return $this;
    }