mirror of
https://github.com/chillerlan/php-qrcode.git
synced 2026-08-25 00:07:52 +00:00
:octocat: yo scrunitizer
This commit is contained in:
@@ -41,6 +41,11 @@ abstract class QROutputAbstract implements QROutputInterface{
|
||||
*/
|
||||
protected $outputMode;
|
||||
|
||||
/**
|
||||
* @var string;
|
||||
*/
|
||||
protected $defaultMode;
|
||||
|
||||
/**
|
||||
* QROutputAbstract constructor.
|
||||
*
|
||||
@@ -77,4 +82,17 @@ abstract class QROutputAbstract implements QROutputInterface{
|
||||
return file_put_contents($this->options->cachefile, $data);
|
||||
}
|
||||
|
||||
/**
|
||||
* @return string
|
||||
*/
|
||||
public function dump(){
|
||||
$data = call_user_func([$this, $this->outputMode ?? $this->defaultMode]);
|
||||
|
||||
if($this->options->cachefile !== null){
|
||||
$this->saveToFile($data);
|
||||
}
|
||||
|
||||
return $data;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user