Give feedback about what's going on.
@return self Chainable.
344260
protected function displayInformations()
    {
        $this->climate()->underline()->out(
            'Initializing translations parser script...'
        );

        $this->climate()->green()->out(
            'CSV file output: <white>'.$this->filePath().'</white>'
        );

        $this->climate()->green()->out(
            'CSV file names: <white>'.$this->domain().'.{locale}.csv</white>'
        );

        $this->climate()->green()->out(
            'Looping through <white>'.$this->maxRecursiveLevel().'</white> level of folders'
        );

        $this->climate()->green()->out(
            'File type parsed: <white>mustache</white>'
        );

        return $this;
    }
401491
public function doServe()
    {
        if ($this->isServeable()) {
            $this->status = self::STATUS_SERVED;

            $this->save();
        }

        return $this;
    }
598752
public function asQuestion()
    {
        $instance = $this->questionClassInstance()
            ->setMaxAttempts($this->maxAttempt);

        // Set question instance hidden if defined by the field.
        if ($this->hidden) {
            $instance->setHidden(true);
        }

        // Set validation callback if field is required.
        if ($this->isRequire()) {
            $this->setValidation(function ($answer) {
                if ($answer == ''
                    && $this->dataType() !== 'boolean') {
                    throw new \Exception('Field is required.');
                }
            });
        }

        // Set question instance validator callback.
        $instance->setValidator(function ($answer) {

            // Iterate over all field validation callbacks.
            foreach ($this->validation as $callback) {
                if (!is_callable($callback)) {
                    continue;
                }

                $callback($answer);
            }

            return $answer;
        });

        // Set question normalizer based on the field normalizer. If a default
        // normalizer is being set from the question class then setting the
        // normalizer will trump it's execution, as only one normalizer can be
        // set per question instance.
        if (isset($this->normalizer)
            && is_callable($this->normalizer)) {
            $instance->setNormalizer($this->normalizer);
        }

        return $instance;
    }
652917
public function refresh()
    {
        $behaviors = $this->owner->behaviors();
        $settings = $behaviors[$this->getName()];
        foreach ($settings as $attribute=>$value) {
            if (in_array($attribute, array('class'))) {
                continue;
            }
            $this->$attribute = $value;
        }
        return $this;
    }
1344885
public function replyAction()
    {
        $questionInteract = $this->get('qcm_core.question.interact');

        if (!$questionInteract->isStarted()) {
            $this->get('session')->getFlashBag()->add('danger', 'qcm_public.questionnaire.not_started');

            return $this->redirect($this->generateUrl('qcm_public_homepage'));
        }

        $question = $questionInteract->getQuestion();
        $formType = $this->get('qcm_core.form.type.reply');
        $form = $this->createForm($formType, $questionInteract->getUserConfiguration());

        return $this->render('QcmPublicBundle:Question:reply.html.twig', array(
            'question' => $question,
            'form' => $form->createView()
        ));
    }
4341
public function toMessage()
    {
        $m = new Message();
        foreach ($this->queueStatus as $action) {
            $m->push($action['action']);
            $m->push($action['queue']);
            $m->push($action['busy']);
            $m->push($action['available']);
        }

        return $m;
    }
224671
private function getOpenedFeedbackClient()
    {
        if (!isset($this->feedbackClient)) {
            $this->feedbackClient = $this->getOpenedClient(new ServiceFeedbackClient());
        }

        return $this->feedbackClient;
    }
974735
public function getFeedback(): array
    {
        $feedback = [];
        $suites = $this->isSingle ? $this->suites : $this->suites[0]->suites;
        foreach ($suites as $suite) {
            foreach ($suite->cases as $case) {
                if ($case->failures) {
                    $feedback[] = 'F';
                } elseif ($case->errors) {
                    $feedback[] = 'E';
                } elseif ($case->skipped) {
                    $feedback[] = 'S';
                } else {
                    $feedback[] = '.';
                }
            }
        }

        return $feedback;
    }
515186
public function reset()
    {
        // reset structure
        parent::reset();

        // reset errors
        $this->clearErrors();

        // reset behaviors
        $this->clearBehaviors();

        // init delegates
        $this->initDelegates();

        return $this;
    }
533823
public function onCreate()
    {
        $this->grid->attributes([
            'url'    => handles('antares::notifications/store'),
            'method' => 'POST',
        ]);
        $layout = ($this->fluent->type == 'sms') ? 'antares/notifications::admin.index.form_sms' : 'antares/notifications::admin.index.form';
        $this->grid->layout($layout, $this->layoutAttributes);
        return $this;
    }
608440
protected function definition_preview() {
        foreach ($this->structure->get_items() as $feedbackitem) {
            $itemobj = feedback_get_item_class($feedbackitem->typ);
            $itemobj->complete_form_element($feedbackitem, $this);
        }
    }
285868
public function doCancel()
    {
        if ($this->isCancelable()) {
            $this->status = self::STATUS_CANCELED;

            $this->save();
        }

        return $this;
    }
795489
public function randomize() : self
    {
        $order = range(0, $this->numRows() - 1);

        shuffle($order);

        array_multisort($order, $this->samples, $this->labels);

        return $this;
    }
39849
public function assertResponseOk()
    {
        $actual = $this->response->getStatusCode();

        PHPUnit::assertTrue($this->response->isOk(), "Expected status code 200, got {$actual}.");

        return $this;
    }
985881
protected function conclude()
    {
        $cli = $this->climate();

        if (count($this->messages)) {
            $cli->out(implode(' ', $this->messages));
            $this->messages = [];
        } else {
            $cli->info('Done!');
        }

        return $this;
    }
994875
public function reset()
    {
        $this->_passed = null;
        $this->_expectations = [];
        $this->_log = new Log([
            'block' => $this,
            'backtrace' => $this->_backtrace
        ]);
        return $this;
    }
973034
public function loadFeedback()
    {
        $serviceName = NotificationServices::APPLE_PUSH_NOTIFICATIONS_SERVICE;

        try {
            $this->logger->info(sprintf("Querying the feedback service '%s'", $serviceName));

            $connection = $this->initFeedbackConnection($serviceName);

            $this
                ->responseHandler
                ->addResponse(
                    $connection->sendRequest()
                );

        } catch (RuntimeException $e) {
            $this->logger->error(
                sprintf("Runtime error while acquiring feedback: %s", $e->getMessage())
            );

        } catch (\Exception $e) {
            $this->logger->error(
                sprintf("Error occurs while acquiring feedback: %s", $e->getMessage())
            );
        }

        return $this;
    }