<?php

declare(strict_types=1);

namespace App\Framework\Logging;

use App\Framework\Logging\ValueObjects\LogContext;

/**
 * Basis-Interface für alle Logger
 *
 * Definiert die atomaren Log-Methoden, die von allen Loggern unterstützt werden müssen.
 * Sowohl der Haupt-Logger als auch Channel-Logger implementieren diese Methoden.
 */
interface Logger
{
    /**
     * Log DEBUG level message
     */
    public function debug(string $message, ?LogContext $context = null): void;

    /**
     * Log INFO level message
     */
    public function info(string $message, ?LogContext $context = null): void;

    /**
     * Log NOTICE level message
     */
    public function notice(string $message, ?LogContext $context = null): void;

    /**
     * Log WARNING level message
     */
    public function warning(string $message, ?LogContext $context = null): void;

    /**
     * Log ERROR level message
     */
    public function error(string $message, ?LogContext $context = null): void;

    /**
     * Log CRITICAL level message
     */
    public function critical(string $message, ?LogContext $context = null): void;

    /**
     * Log ALERT level message
     */
    public function alert(string $message, ?LogContext $context = null): void;

    /**
     * Log EMERGENCY level message
     */
    public function emergency(string $message, ?LogContext $context = null): void;

    /**
     * Log with arbitrary level
     */
    public function log(LogLevel $level, string $message, ?LogContext $context = null): void;
}
