/** * Checks whether the message level is below the appender's threshold. * * If there is no threshold set, then the return value is always <i>true</i>. * * @param LoggerLevel $level * @return boolean Returns true if level is greater or equal than * threshold, or if the threshold is not set. Otherwise returns false. */ public function isAsSevereAsThreshold($level) { if ($this->threshold === null) { return true; } return $level->isGreaterOrEqual($this->getThreshold()); }
/** * Check whether this Logger is enabled for a given Level passed as parameter. * * @param LoggerLevel $level * @return boolean */ public function isEnabledFor($level) { return (bool) $level->isGreaterOrEqual($this->getEffectiveLevel()); }
/** * Check whether this Logger is enabled for a given Level passed as parameter. * * @param LoggerLevel level * @return boolean */ public function isEnabledFor(LoggerLevel $level) { return $level->isGreaterOrEqual($this->getEffectiveLevel()); }
/** * Check whether the message level is below the appender's threshold. * * * If there is no threshold set, then the return value is always <i>true</i>. * @param LoggerLevel $priority * @return boolean true if priority is greater or equal than threshold */ function isAsSevereAsThreshold($priority) { if ($this->threshold === null) { return true; } return $priority->isGreaterOrEqual($this->getThreshold()); }