Code Duplication    Length = 24-26 lines in 2 locations

src/Client/Http/Feed/EventStreamFeedLink.php 1 location

@@ 5-28 (lines=24) @@
2
3
namespace RayRutjes\GetEventStore\Client\Http\Feed;
4
5
final class EventStreamFeedLink extends AbstractFeedLink
6
{
7
    const LINK_SELF = 'self';
8
    const LINK_FIRST = 'first';
9
    const LINK_LAST = 'last';
10
    const LINK_PREVIOUS = 'previous';
11
    const LINK_NEXT = 'next';
12
    const LINK_METADATA = 'metadata';
13
14
    /**
15
     * @return array
16
     */
17
    protected function getValidRelations(): array
18
    {
19
        return [
20
            self::LINK_SELF,
21
            self::LINK_FIRST,
22
            self::LINK_LAST,
23
            self::LINK_PREVIOUS,
24
            self::LINK_NEXT,
25
            self::LINK_METADATA,
26
        ];
27
    }
28
}
29

src/Client/Http/Feed/EventStreamViaPersistentSubscriptionFeedLink.php 1 location

@@ 5-30 (lines=26) @@
2
3
namespace RayRutjes\GetEventStore\Client\Http\Feed;
4
5
final class EventStreamViaPersistentSubscriptionFeedLink extends AbstractFeedLink
6
{
7
    const LINK_SELF = 'self';
8
    const LINK_FIRST = 'first';
9
    const LINK_LAST = 'last';
10
    const LINK_PREVIOUS = 'previous';
11
    const LINK_NEXT = 'next';
12
    const LINK_ACK_ALL = 'ackAll';
13
    const LINK_NACK_ALL = 'nackAll';
14
15
    /**
16
     * @return array
17
     */
18
    protected function getValidRelations(): array
19
    {
20
        return [
21
            self::LINK_SELF,
22
            self::LINK_FIRST,
23
            self::LINK_LAST,
24
            self::LINK_PREVIOUS,
25
            self::LINK_NEXT,
26
            self::LINK_ACK_ALL,
27
            self::LINK_NACK_ALL,
28
        ];
29
    }
30
}
31