<?php

namespace yiiunit\framework\log\mocks;

use yii\log\Target;

class TargetMock extends Target
{

    public $collectOverride;

    /**
     * @inheritDoc
     */
    public function export()
    {

    }

    public function collect($messages, $final)
    {
        if($this->collectOverride !== null) {
            call_user_func($this->collectOverride, $messages, $final);
            return;
        }
        parent::collect($messages, $final); // TODO: Change the autogenerated stub
    }
}
