Code Duplication    Length = 12-12 lines in 2 locations

src/Tidal/WampWatch/RegistrationMonitor.php 1 location

@@ 53-64 (lines=12) @@
50
    /**
51
     * Initializes the subscription to the meta-events.
52
     */
53
    protected function initSetupCalls()
54
    {
55
        // @var \Tidal\WampWatch\Subscription\Collection
56
        $collection = $this->getMetaSubscriptionCollection();
57
58
        $collection->addSubscription(self::REGISTRATION_CREATE_TOPIC, $this->getSubscriptionHandler('create'));
59
        $collection->addSubscription(self::REGISTRATION_DELETE_TOPIC, $this->getSubscriptionHandler('delete'));
60
        $collection->addSubscription(self::REGISTRATION_REG_TOPIC, $this->getSubscriptionHandler('register'));
61
        $collection->addSubscription(self::REGISTRATION_UNREG_TOPIC, $this->getSubscriptionHandler('unregister'));
62
63
        $this->setInitialCall(self::REGISTRATION_LIST_TOPIC, $this->getSubscriptionIdRetrievalCallback());
64
    }
65
66
    protected function setList($list)
67
    {

src/Tidal/WampWatch/SubscriptionMonitor.php 1 location

@@ 84-95 (lines=12) @@
81
    /**
82
     * Initializes the subscription to the meta-events.
83
     */
84
    protected function initSetupCalls()
85
    {
86
        // @var \Tidal\WampWatch\Subscription\Collection
87
        $collection = $this->getMetaSubscriptionCollection();
88
89
        $collection->addSubscription(self::SUBSCRIPTION_CREATE_TOPIC, $this->getSubscriptionHandler('create'));
90
        $collection->addSubscription(self::SUBSCRIPTION_DELETE_TOPIC, $this->getSubscriptionHandler('delete'));
91
        $collection->addSubscription(self::SUBSCRIPTION_SUB_TOPIC, $this->getSubscriptionHandler('subscribe'));
92
        $collection->addSubscription(self::SUBSCRIPTION_UNSUB_TOPIC, $this->getSubscriptionHandler('unsubscribe'));
93
94
        $this->setInitialCall(self::SUBSCRIPTION_LIST_TOPIC, $this->getSubscriptionIdRetrievalCallback());
95
    }
96
97
    protected function retrieveSubscriptionIds()
98
    {