@param $message

@return StopwatchEvent
186103
public function startProfiling($message)
    {
        $this->calls[$this->counter] = array(
            'message' => $message,
            'duration' => null,
            'memory_start' => memory_get_usage(true),
            'memory_end' => null,
            'memory_use' => null,
            'error' => null,
            'error_message' => null,
        );

        return $this->stopwatch->start($message);
    }
83414
public function fire($event, $subject = null, $message = null)
    {
        $this->stop = false;

        try {
            foreach ([$event . ':before', $event, $event . ':after'] as $eventName) {
                if ($this->stop) {
                    break;
                }

                $subject = $this->call($eventName, $subject, $message);
            }

            return $subject;
        } catch (\Exception $e) {
            if (!isset($this->events[$event . ':exception'])) {
                throw $e;
            }

            return $this->call($event . ':exception', $e, $e->getMessage());
        }
    }
253954
public static function cantCheckWithBetActive($message = null)
    {
        $defaultMessage = 'Cannot check when there has been a bet made';
        $message = null === $message ? $defaultMessage : $message;

        return new static($message);
    }
931011
public function warning($message)
    {
        $args = func_get_args();
        array_shift($args);
        return $this->log(Log::Warning, $message, $args);
    }
713110
public function setMessage($message)
    {
        if (is_object($message)) {
            $message = (new ConvertObject($message))
                ->toArray();
        }
        $this->message = $message;
        return $this;
    }
397030
public function delete(QueueMessage $message)
    {
        $queue = $message->getQueueName() ?: $this->queue;

        $this->client->useTube($queue)->delete(new Job($message->getId(), ''));

        return $this;
    }
814945
private function start($message, $hook = true) {
		if (!isset($this->status))
			$this->status = new \SplStack;

		if($hook)
			$this->applyHooks ('Pre', $message);
		
		$this->status->push([
			microtime(true),
			$message,
		]);

		if ($this->verbose >= 1)
			echo PHP_EOL, str_repeat("\t", $this->status->count() - 1), $message, '... ';


		return $this;
	}
828472
public function stop($status = 0, $message = null) {
		if ($message) {
			($status == 0) ? $this->out($message) : $this->error($message);
		}
		exit($status);
	}
164545
public function notify($message)
    {
        try {
            $command = $this->createCommand($message);
            $this->socket->send($command);

            $result = false;
            $limit = microtime(true) + $this->timeout;

            while (microtime(true) < $limit && false === $result = $this->socket->recv(\ZMQ::MODE_NOBLOCK)) {
                usleep(1000);
            }

            if (false === $result) {
                $this->logger->error(sprintf('Unable to notify the task manager with message "%s" within timeout of %d seconds', $message, $this->timeout));
                throw new RuntimeException('Unable to retrieve information.');
            }

            $data = @json_decode($result, true);
            if (JSON_ERROR_NONE !== json_last_error()) {
                throw new RuntimeException('Invalid task manager response : invalid JSON.');
            }
            if (!isset($data['reply']) || !isset($data['request']) || $command !== $data['request']) {
                throw new RuntimeException('Invalid task manager response : missing fields.');
            }

            return $data['reply'];
        } catch (\ZMQSocketException $e) {
            $this->logger->error(sprintf('Unable to notify the task manager with message "%s" within timeout of %d seconds', $message, $this->timeout), ['exception' => $e]);
            throw new RuntimeException('Unable to retrieve information.', $e->getCode(), $e);
        }
    }
163434
public function addMessage($message) {
        $this->message = trim(trim($this->message).NL.$message);
        return $this;
    }
1199025
public function getNotifierForMessage(Message $message): Notifier
    {
        foreach ($this->notifiers as $notifier) {
            if ($notifier->handles($message)) {
                return $notifier;
            }
        }
        throw new NotifierNotFoundException();
    }
195948
public function addMessage(string $message)
  {
    if ( false === ($step=$this->currentStep()) ){
      throw new \Exception('No current step');
    }
    
    $step->addMessage($message);
    return $this;
  }
62449
public function logNotice($message)
    {
        if (func_num_args() > 1) {
            $message = $this->_prepareLogMessage(func_get_args());
        }

        return $this->_log(Zend_Log::NOTICE, $message);
    }
950340
public function setMessage($message)
    {
        if ( ! is_null($message)) $message = (string) $message;

        $this->setAttribute('message', $message);

        return $this;
    }
910026
public function setStatusMessage($message)
    {
        $message = (string) trim($message);

        if ($message === '') {
            $this->statusMessage = $this->getStatusMessage();
        } else {
            $this->statusMessage = $message;
        }

        return $this;
    }
1075593
public static function startTimer($name, $message = null) {
		if (!Reveal::is('DebugKit.running')) {
			return;
		}

		App::uses('DebugTimer', 'DebugKit.Lib');
		DebugTimer::start($name, $message);
	}
336548
public function endsWith($sub, $message = null)
    {
        $this->setRule(__FUNCTION__, function($val, $args)
                       {
                           $sub = $args[0];
                           return (strlen($val) === 0 || substr($val, -strlen($sub)) === $sub);
                       }, $message, array($sub));
        return $this;
    }