HEX
Server: LiteSpeed
System: Linux php-prod-1.spaceapp.ru 5.15.0-160-generic #170-Ubuntu SMP Wed Oct 1 10:06:56 UTC 2025 x86_64
User: sport3497 (1034)
PHP: 8.1.33
Disabled: NONE
Upload Files
File: //usr/local/CyberCP/public/snappymail/snappymail/v/2.38.2/app/libraries/MailSo/Log/Inherit.php
<?php

/*
 * This file is part of MailSo.
 *
 * (c) 2014 Usenko Timur
 *
 * For the full copyright and license information, please view the LICENSE
 * file that was distributed with this source code.
 */

namespace MailSo\Log;

/**
 * @category MailSo
 * @package Log
 */
trait Inherit
{
	protected ?Logger $oLogger = null;

	public function Logger(): ?Logger
	{
		return $this->oLogger;
	}

	public function SetLogger(?Logger $oLogger): void
	{
		$this->oLogger = $oLogger;
	}

	public function logWrite(string $sDesc, int $iType = \LOG_INFO, string $sName = '', bool $bDiplayCrLf = false): bool
	{
		return $this->oLogger && $this->oLogger->Write($sDesc, $iType, $sName, $bDiplayCrLf);
	}

	public function logException(\Throwable $oException, int $iType = \LOG_NOTICE, string $sName = ''): void
	{
		$this->oLogger && $this->oLogger->WriteException($oException, $iType, $sName);
	}

	public function logMask(
		#[\SensitiveParameter]
		string $sWord
	): void
	{
		$this->oLogger && $this->oLogger->AddSecret($sWord);
	}

/*
	public function logWriteDump($mValue, int $iType = \LOG_INFO, string $sName = '') : bool
	public function logWriteExceptionShort(\Throwable $oException, int $iType = \LOG_NOTICE, string $sName = '') : void
*/
}