@param string $status

@return self
976578
public function withStatus(string $status): self
    {
        $this->status = JobEventStatusEnum::ensureValid($status);
        return $this;
    }
402159
public function setStatus($status)
    {
        $allowedValues = $this->getStatusAllowableValues();
        if (!in_array($status, $allowedValues, true)) {
            throw new \InvalidArgumentException(
                sprintf(
                    "Invalid value for 'status', must be one of '%s'",
                    implode("', '", $allowedValues)
                )
            );
        }
        $this->container['status'] = $status;

        return $this;
    }
270699
public function setStatus($status)
    {
        $validStatus = [
            100,
            101,
            102,
            200,
            201,
            202,
            203,
            204,
            205,
            206,
            207,
            208,
            300,
            301,
            302,
            303,
            304,
            305,
            306,
            307,
            400,
            401,
            402,
            403,
            404,
            405,
            406,
            407,
            408,
            409,
            410,
            411,
            412,
            413,
            414,
            415,
            416,
            417,
            418,
            422,
            423,
            424,
            425,
            426,
            428,
            429,
            431,
            500,
            501,
            502,
            503,
            504,
            505,
            506,
            507,
            508,
            511,
        ];

        if (false === in_array($status, $validStatus, false)) {
            throw new \InvalidArgumentException(sprintf(
                'Provided status does not match a valid HTTP Status Code.',
                $status
            ));
        }
        $this->status = (int) $status;
    }
270777
public function warning($str, $status = Response::STATUS_OK)
    {
        $this->addError(new Error($str, $status));
        return $this;
    }
21971
public function withStatus(string $status): self
    {
        $this->status = ScheduledActionStatusEnum::ensureValid($status);
        return $this;
    }
606794
public function setStatus(StatusInterface $status = null)
    {
        $this->status = null;
        $this->statusChanged = true;
        if ($status instanceof StatusInterface) {
            $this->status = EmbedStatus::createFromStatus($status);
        }
    }
1041025
public function withStatus(string $status)
    {
        Assert::oneOf($status, [
            Status::ANY,
            Status::ACTIVE,
            Status::OPEN,
            Status::CLOSED,
            Status::PENDING,
            Status::SPAM,
        ]);

        $filters = clone $this;
        $filters->status = $status;

        return $filters;
    }
313231
public function setStatus(\Sulu\Bundle\Sales\ShippingBundle\Entity\ShippingStatus $status)
    {
        $this->status = $status;
    
        return $this;
    }
501956
public function setStatus($status)
    {
        if ($status) {
            $map = $this->factory->getConnection()->getCurrentMapInfo();
            $this->widget->setAuthorTime($map->author, $map->goldTime);
            $this->widget->create($this->allPlayers);
        } else {
            $this->widget->destroy($this->allPlayers);
        }
    }
848689
public function setStatusCode(int $statusCode): self
    {
        if (!array_key_exists($statusCode, Response::$statusTexts)) {
            $this->internalServerError('Invalid status code in ' . __METHOD__, Response::$statusTexts);
        }

        $this->statusCode = $statusCode;

        return $this;
    }
1369694
public function setStatus($status)
    {
        $statusAttribute = $this->statusAttribute;
        return (is_string($statusAttribute) && !empty($statusAttribute)) ? $this->$statusAttribute = $status : null;
    }
1049336
public function setStatus($status)
    {
        if (!in_array($status, static::getAvailableStatuses(), true)) {
            throw new InvalidArgumentException(sprintf('Status not recognized ; Had "%s", expected one of "%s"', $status, implode('", "', static::getAvailableStatuses())));
        }

        $this->status = $status;

        return $this;
    }
1353925
public function setStatus($status, $calledFromOperation = false)
    {
        parent::setStatus($status);

        // Change the Operation as well only if this method has not been called by an Operation instance to avoid recursion.
        if (!$calledFromOperation && $this->getEqualsOperation() && count($this->getOperations())) {
            $this->getOperations()[0]->setStatus($this->status, true);
        }

        return $this;
    }
1342840
public function setStatus($status)
    {
        $title = $this->gameStorage->getTitle();
        $mode = $this->gameStorage->getGameModeCode();
        $script = $this->gameStorage->getGameInfos()->scriptName;

        foreach ($this->plugins as $pluginId => $plugin) {
            if (isset($this->widgetPositions[$pluginId])) {
                $options = $this->compatibleFetcher->getCompatibleData($this->widgetPositions[$pluginId], $title, $mode, $script);

                if (!is_null($options)) {
                    /** @var WidgetFactory $plugin */
                    $plugin->updateOptions($options['posX'], $options['posY'], AssociativeArray::getFromKey($options, 'options', []));
                }
            }
        }
    }
962348
public function statusExist($status)
    {
        $generator = $this->getStatuses();
        $list = iterator_to_array($generator);

        return in_array($status, $list);
    }
86173
public function autoplay($status = false)
    {
        if($status) {
            $this->attributes['autoplay'] = true;
        } else {
            unset($this->attributes['autoplay']);
        }

        return $this;
    }
1073168
public function resumeable($status = true)
    {
        $this->partialRequest = $this->resumeable = ( bool )$status;

        return $this;
    }