yii\mongodb\file\Download::getResource PHP Method

getResource() public method

Returns persistent stream resource, which can be used to read file.
public getResource ( ) : resource
return resource file stream resource.
    public function getResource()
    {
        if ($this->_resource === null) {
            $this->_resource = $this->toResource();
        }
        return $this->_resource;
    }