public function getQrCodeContent($messageOrParams, $extension = null, $size = null, $padding = null)
    {
        if ($messageOrParams instanceof Params) {
            $extension          = $messageOrParams->fromRoute('extension', $this->options->getExtension());
            $size               = $messageOrParams->fromRoute('size', $this->options->getSize());
            $padding            = $messageOrParams->fromRoute('padding', $this->options->getPadding());
            $messageOrParams    = $messageOrParams->fromRoute('message');
        } else {
            $extension  = isset($extension) ? $extension : $this->options->getExtension();
            $size       = isset($size) ? $size : $this->options->getSize();
            $padding    = isset($padding) ? $padding : $this->options->getPadding();
        }

        $qrCode = new QrCode($messageOrParams);
        $qrCode->setImageType($extension);
        $qrCode->setSize($size);
        $qrCode->setPadding($padding);
        return $qrCode->get();
    }
public function getQrCodeContent($messageOrParams, $extension = null, $size = null, $padding = null)
    {
        if ($messageOrParams instanceof Params) {
            $extension          = $messageOrParams->fromRoute('extension', $this->options->getExtension());
            $size               = $messageOrParams->fromRoute('size', $this->options->getSize());
            $padding            = $messageOrParams->fromRoute('padding', $this->options->getPadding());
            $messageOrParams    = $messageOrParams->fromRoute('message');
        } else {
            $extension  = isset($extension) ? $extension : $this->options->getExtension();
            $size       = isset($size) ? $size : $this->options->getSize();
            $padding    = isset($padding) ? $padding : $this->options->getPadding();
        }

        $qrCode = new QrCode($messageOrParams);
        $qrCode->setImageType($extension);
        $qrCode->setSize($size);
        $qrCode->setPadding($padding);
        return $qrCode->get();
    }
public function getQrCodeContent ( $ messageOrParams , $ extension = null , $ size = null , $ padding = null ) { if ( $ messageOrParams instanceof Params ) { $ extension = $ messageOrParams -> fromRoute ( 'extension' , $ this -> options -> getExtension ( ) ) ; $ size = $ messageOrParams -> fromRoute ( 'size' , $ this -> options -> getSize ( ) ) ; $ padding = $ messageOrParams -> fromRoute ( 'padding' , $ this -> options -> getPadding ( ) ) ; $ messageOrParams = $ messageOrParams -> fromRoute ( 'message' ) ; } else { $ extension = isset ( $ extension ) ? $ extension : $ this -> options -> getExtension ( ) ; $ size = isset ( $ size ) ? $ size : $ this -> options -> getSize ( ) ; $ padding = isset ( $ padding ) ? $ padding : $ this -> options -> getPadding ( ) ; } $ qrCode = new QrCode ( $ messageOrParams ) ; $ qrCode -> setImageType ( $ extension ) ; $ qrCode -> setSize ( $ size ) ; $ qrCode -> setPadding ( $ padding ) ; return $ qrCode -> get ( ) ; }
Returns a QrCode content to be rendered or saved
If the first argument is a Params object, all the information will be tried to be fetched for it,
ignoring any other argument
@param string|Params $messageOrParams
@param string $extension
@param int $size
@param int $padding
@return mixed
Returns a QrCode content to be rendered or saved If the first argument is a Params object all the information will be tried to be fetched for it ignoring any other argument