public function check($alias = null)
    {
        if (null === $alias) {
            $statuses = new Statuses;
            $statuses->setHealthy(true);

            foreach ($this->checkCollection as $check) {
                $status = $check->execute();
                $statuses->getCollection()->add($status);

                if (!$status->getHealthy()) {
                    $statuses->setHealthy(false);
                }
            }

            return $statuses;
        } else {
            $check = $this->checkCollection->filter(function($element) use($alias) {
                return $element->getAlias() === $alias;
            })->first();

            if (!$check) {
                throw new InvalidAliasException('Check alias does not exist.');
            }

            $status = $check->execute();

            return $status;
        }
    }