<?php
declare(strict_types=1);
namespace PpPhp\Core\Platform\Console\Commands;
use PpPhp\Core\Platform\Console\AbstractCommand;
final class StreamReplayTopicCommand extends AbstractCommand
{
    public function name(): string { return 'stream:replay:topic'; }
    public function description(): string { return 'PPphp Stream Replay Topic'; }
    public function handle(array $arguments = []): int
    {
        $this->title('PPphp Stream Replay Topic');
        $runtime = \PpPhp\Core\Platform\Event\Streaming\Replay\StreamPersistenceRuntime::instance(\PpPhp\Core\Platform\Console\ConsolePath::basePath()); $result = $runtime->replay(\PpPhp\Core\Platform\Event\Streaming\Replay\StreamReplayRequest::create('replay.topic', 1, 10, 'console')); $this->line('Replayed: ' . $result->replayed());
        return 0;
    }
}
