Initial commit

This commit is contained in:
2021-01-18 16:09:51 +03:00
commit 7c6284efcb
19 changed files with 827 additions and 0 deletions

27
src/Message.php Normal file
View File

@ -0,0 +1,27 @@
<?php
declare(strict_types=1);
namespace Nsq;
/**
* @psalm-immutable
*/
final class Message
{
public int $timestamp;
public int $attempts;
public string $id;
public string $body;
public function __construct(int $timestamp, int $attempts, string $id, string $body)
{
$this->timestamp = $timestamp;
$this->attempts = $attempts;
$this->id = $id;
$this->body = $body;
}
}