Add a 'PUT' route to be handled by the application.

@param callable|string|HttpPipeline|array $stages $stages
19363
public function put(string $pattern, $stages): void
    {
        $pipeline = new HttpPipeline(RequestMethodInterface::METHOD_PUT, $this->prefix.$pattern, $this->routerStages);
        $pipeline->pipe($stages);
        $this->pipelineCollection->add($pipeline);
    }
767283
public void setStages(java.util.Collection<StageDeclaration> stages) {
        if (stages == null) {
            this.stages = null;
            return;
        }

        this.stages = new java.util.ArrayList<StageDeclaration>(stages);
    }
681369
public function get(string $pattern, $stages): void
    {
        $pipeline = new HttpPipeline(RequestMethodInterface::METHOD_GET, $this->prefix.$pattern, $this->routerStages);
        $pipeline->pipe($stages);
        $this->pipelineCollection->add($pipeline);
    }
308256
public function endInstall(StageInterface $stage)
    {
        $message = sprintf('Install <fg=green>%s</> finished in <fg=green>%ss</>', $stage->getName(), $this->timer->end($stage));
        $this->writeln($message);
    }
366054
public function processStages(array $stages, $payload)
    {
        // Take the stage to handle
        $currentStage = \array_shift($stages);

        // If is a string get the instance in the container
        if (\is_string($currentStage) && $this->container->has($currentStage)) {
            $currentStage = $this->container->get($currentStage);
        }

        // If the current stage is a RequestHandler use it and return the Response
        if ($currentStage instanceof RequestHandlerInterface) {
            return $currentStage->handle($payload);
        }

        // Process the current stage, and proceed to the stack
        if (false !== \current($stages) && \is_callable($currentStage)) {
            return $this->processStages($stages, $currentStage($payload));
        }

        // If there's not next stage in the stack, return the result for this one
        if (\is_callable($currentStage)) {
            return $currentStage($payload);
        }

        throw new UnprocessableStageException($currentStage, 'The stage can\'t be handled');
    }
699635
public function setStage($stage)
    {
        $connectionKey = $this->getCurrentConnectionKey();
        if ($stage === $connectionKey->stage) {
            return;
        }

        $connectionKey->stage = $stage;
        $this->getConnections()->map(function (ConnectionInterface $connection) use ($connectionKey) {
            if ($connection->isCurrent() || $connection->getConnectionKey()->is($connectionKey)) {
                $connection->setConnectionKey($connectionKey);
            }

            return $connection;
        });

        // If we do have a stage, cleanup previous events
        if ($stage) {
            $this->bootstrapper->bootstrapUserCode();
        }
    }
1140329
public function addRoute(array $methods, array $versions, $uri, $action)
    {
        $this->createRouteCollections($versions);

        $route = new Route($methods, $uri, $action);
        $route->where($action['where']);

        foreach ($versions as $version) {
            $this->routes[$version]->add($route);
        }

        return $route;
    }
893272
public function put($path, $parameters = null, $version = null, $etag = null)
        {
            return $this->api('PUT', $path, $parameters, $version, $etag);
        }
699771
public function afterStage($stage, $tasks, Application $application = null)
    {
        $this->addTaskToStage($tasks, $stage, $application, 'after');

        return $this;
    }
131221
public function applyChange(
        MenuInterface $menu,
        $stage
    ) {
        $menu->setSubnodes(
            $this->applyFiltersToMenuNodes(
                $menu->getSubnodes(),
                $menu->getCode(),
                $stage
            )
        );

        return $this;
    }
443672
public function put($uri, $handler, $middlewares = array())
    {
        return $this->add($this->route('PUT', $uri, $handler, $middlewares));
    }
783462
private function assertThereIsAtMostOneConnectorPerStage($stageName, $stageConnectors)
    {
        if (count($stageConnectors) > 1) {
            $connectorClasses = [];
            foreach ($stageConnectors as $connector) {
                $connectorClasses[] = $connector->getStepFqcn();
            }
            $connectors = implode(',', $connectorClasses);

            throw new PipelineBuildingException(
                "Multiple stage connectors found for stage '$stageName'. Please remove one of: $connectors."
            );
        }
    }
726004
private function applyMenuChangers(
        MenuInterface $menu,
        $stage
    ) {
        foreach ($this->menuChangers as $menuChanger) {
            $menuChanger
                ->applyChange(
                    $menu,
                    $stage
                );
        }

        return $this;
    }
143138
public function applyChange(
        MenuInterface $menu,
        $stage
    ) {
        $this->applyModifiersToMenuNodes(
            $menu->getSubnodes(),
            $menu->getCode(),
            $stage
        );

        return $this;
    }
507881
public function put($path, $params = []){
        $json = json_encode($params);
        
        return $this->_call('PUT', $path, $json);
    }
976709
public function beforeStage($stage, $tasks, Application $application = null)
    {
        $this->addTaskToStage($tasks, $stage, $application, 'before');

        return $this;
    }
205298
private function addElementByStage(
        $element,
        $stage
    ) {
        if (!isset($this->elementsStoredByStage[$stage])) {
            $this->elementsStoredByStage[$stage] = [];
        }

        $elementId = spl_object_hash($element);
        $this->elementsStoredByStage[$stage][$elementId] = $element;

        return $this;
    }