Skip to content

Commit 6affe04

Browse files
committed
add RecordInterface
1 parent 08b8736 commit 6affe04

8 files changed

+21
-7
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
<?php
2+
3+
namespace Cosmastech\StatsDClientAdapter\Adapters\InMemory\Models\Contracts;
4+
5+
interface RecordInterface
6+
{
7+
}

src/Adapters/InMemory/Models/InMemoryCountRecord.php

+2-1
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,10 @@
22

33
namespace Cosmastech\StatsDClientAdapter\Adapters\InMemory\Models;
44

5+
use Cosmastech\StatsDClientAdapter\Adapters\InMemory\Models\Contracts\RecordInterface;
56
use DateTimeImmutable;
67

7-
class InMemoryCountRecord
8+
class InMemoryCountRecord implements RecordInterface
89
{
910
/**
1011
* @param string $stat

src/Adapters/InMemory/Models/InMemoryDistributionRecord.php

+2-1
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,10 @@
22

33
namespace Cosmastech\StatsDClientAdapter\Adapters\InMemory\Models;
44

5+
use Cosmastech\StatsDClientAdapter\Adapters\InMemory\Models\Contracts\RecordInterface;
56
use DateTimeImmutable;
67

7-
readonly class InMemoryDistributionRecord
8+
readonly class InMemoryDistributionRecord implements RecordInterface
89
{
910
/**
1011
* @param string $stat

src/Adapters/InMemory/Models/InMemoryGaugeRecord.php

+2-1
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,10 @@
22

33
namespace Cosmastech\StatsDClientAdapter\Adapters\InMemory\Models;
44

5+
use Cosmastech\StatsDClientAdapter\Adapters\InMemory\Models\Contracts\RecordInterface;
56
use DateTimeImmutable;
67

7-
readonly class InMemoryGaugeRecord
8+
readonly class InMemoryGaugeRecord implements RecordInterface
89
{
910
/**
1011
* @param string $stat

src/Adapters/InMemory/Models/InMemoryHistogramRecord.php

+2-1
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,10 @@
22

33
namespace Cosmastech\StatsDClientAdapter\Adapters\InMemory\Models;
44

5+
use Cosmastech\StatsDClientAdapter\Adapters\InMemory\Models\Contracts\RecordInterface;
56
use DateTimeImmutable;
67

7-
readonly class InMemoryHistogramRecord
8+
readonly class InMemoryHistogramRecord implements RecordInterface
89
{
910
/**
1011
* @param string $stat

src/Adapters/InMemory/Models/InMemorySetRecord.php

+2-1
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,10 @@
22

33
namespace Cosmastech\StatsDClientAdapter\Adapters\InMemory\Models;
44

5+
use Cosmastech\StatsDClientAdapter\Adapters\InMemory\Models\Contracts\RecordInterface;
56
use DateTimeImmutable;
67

7-
readonly class InMemorySetRecord
8+
readonly class InMemorySetRecord implements RecordInterface
89
{
910
/**
1011
* @param string $stat

src/Adapters/InMemory/Models/InMemoryStatsRecord.php

+2-1
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,12 @@
33
namespace Cosmastech\StatsDClientAdapter\Adapters\InMemory\Models;
44

55
use Cosmastech\StatsDClientAdapter\Adapters\InMemory\Models\Concerns\GetAndSetRecordsTrait;
6+
use Cosmastech\StatsDClientAdapter\Adapters\InMemory\Models\Contracts\RecordInterface;
67

78
/**
89
* Container class for storing all stats.
910
*/
10-
class InMemoryStatsRecord
11+
class InMemoryStatsRecord implements RecordInterface
1112
{
1213
use GetAndSetRecordsTrait;
1314

src/Adapters/InMemory/Models/InMemoryTimingRecord.php

+2-1
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,10 @@
22

33
namespace Cosmastech\StatsDClientAdapter\Adapters\InMemory\Models;
44

5+
use Cosmastech\StatsDClientAdapter\Adapters\InMemory\Models\Contracts\RecordInterface;
56
use DateTimeImmutable;
67

7-
readonly class InMemoryTimingRecord
8+
readonly class InMemoryTimingRecord implements RecordInterface
89
{
910
/**
1011
* @param string $stat

0 commit comments

Comments
 (0)