yii\mongodb\Cache::init PHP 메소드

init() 공개 메소드

This method will initialize the [[db]] property to make sure it refers to a valid MongoDB connection.
public init ( )
    public function init()
    {
        parent::init();
        $this->db = Instance::ensure($this->db, Connection::className());
    }