Code Duplication    Length = 12-12 lines in 2 locations

src/Tidal/WampWatch/RegistrationMonitor.php 1 location

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

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
    {