public function init($poc) { $this->poc = $poc; $this->pocDispatcher = $poc->getPocDispatcher(); $this->logger = $this->poc->getLogger(); $this->pocDispatcher->addListener(PocEventNames::BEFORE_OUTPUT_SENT_TO_CLIENT_AFTER_OUTPUT_STORED, array($this, 'beforeOutputSentToClinetAfterOutputStoredTime')); $this->pocDispatcher->addListener(PocEventNames::BEFORE_OUTPUT_SENT_TO_CLIENT_AFTER_OUTPUT_STORED, array($this, 'beforeOutputSentToClinetAfterOutputStoredOutput')); $this->pocDispatcher->addListener(PocEventNames::BEFORE_OUTPUT_SENT_TO_CLIENT_NO_CACHING_PROCESS_INVOLVED, array($this, 'beforeOutputSentToClientNoCachingProcessInvolvedTime')); $this->pocDispatcher->addListener(PocEventNames::BEFORE_OUTPUT_SENT_TO_CLIENT_NO_CACHING_PROCESS_INVOLVED, array($this, 'beforeOutputSentToClientNoCachingProcessInvolvedOutput')); $this->pocDispatcher->addListener(PocEventNames::BEFORE_OUTPUT_SENT_TO_CLIENT_FETCHED_FROM_CACHE, array($this, 'beforeOutputSentToClientFetchedFromCacheTime')); $this->pocDispatcher->addListener(PocEventNames::BEFORE_OUTPUT_SENT_TO_CLIENT_FETCHED_FROM_CACHE, array($this, 'beforeOutputSentToClientFetchedFromCacheOutput')); $this->pocDispatcher->addListener(PocEventNames::BEFORE_STORE_OUTPUT, array($this, 'beforeStoreOutputTime')); $this->pocDispatcher->addListener(PocEventNames::BEFORE_STORE_OUTPUT, array($this, 'beforeStoreOutputOutput')); $this->pocDispatcher->addListener(PocEventNames::OUTPUT_STORED, array($this, 'outputStoredTime')); $this->pocDispatcher->addListener(EtagEvents::ETAG_FOUND, array($this, 'etagFoundTime')); $this->pocDispatcher->addListener(EtagEvents::ETAG_NOT_FOUND, array($this, 'etagNotFoundTime')); // todo: If it is turned on, the php fly away with segmentation fault // when phpunit runs. /* * $this->pocDispatcher->addListener(PocEventNames::DIES, array($this, * 'diesTime')); */ }