Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -33,14 +33,14 @@

class DoctrineUuidV4MessageRepository implements MessageRepository
{
private TableSchema $tableSchema;
private UuidEncoder $uuidEncoder;
protected TableSchema $tableSchema;
protected UuidEncoder $uuidEncoder;

public function __construct(
private Connection $connection,
private string $tableName,
private MessageSerializer $serializer,
private int $jsonEncodeOptions = 0,
protected Connection $connection,
protected string $tableName,
protected MessageSerializer $serializer,
protected int $jsonEncodeOptions = 0,
?TableSchema $tableSchema = null,
?UuidEncoder $uuidEncoder = null,
) {
Expand Down Expand Up @@ -161,7 +161,7 @@ private function createQueryBuilder(): QueryBuilder
/**
* @psalm-return Generator<Message>
*/
private function yieldMessagesFromPayloads(Traversable $payloads): Generator
protected function yieldMessagesFromPayloads(Traversable $payloads): Generator
{
foreach ($payloads as $payload) {
yield $message = $this->serializer->unserializePayload(json_decode($payload['payload'], true));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,14 +23,14 @@

class IlluminateUuidV4MessageRepository implements MessageRepository
{
private TableSchema $tableSchema;
private UuidEncoder $uuidEncoder;
protected TableSchema $tableSchema;
protected UuidEncoder $uuidEncoder;

public function __construct(
private ConnectionInterface $connection,
private string $tableName,
private MessageSerializer $serializer,
private int $jsonEncodeOptions = 0,
protected ConnectionInterface $connection,
protected string $tableName,
protected MessageSerializer $serializer,
protected int $jsonEncodeOptions = 0,
?TableSchema $tableSchema = null,
?UuidEncoder $uuidEncoder = null,
) {
Expand Down Expand Up @@ -106,7 +106,7 @@ public function retrieveAllAfterVersion(AggregateRootId $id, int $aggregateRootV
/**
* @psalm-return Generator<Message>
*/
private function yieldMessagesForResult(Collection $result): Generator
protected function yieldMessagesForResult(Collection $result): Generator
{
foreach ($result as $row) {
$message = $this->serializer->unserializePayload(json_decode($row->payload, true));
Expand Down