for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
/**
* Copyright © 2016-present Spryker Systems GmbH. All rights reserved.
* Use of this software requires acceptance of the Evaluation License Agreement. See LICENSE file.
*/
namespace SprykerEco\Zed\Payone\Dependency\Service;
use Spryker\Service\UtilEncoding\UtilEncodingServiceInterface;
class PayoneToUtilEncodingServiceBridge implements PayoneToUtilEncodingServiceInterface
{
* @var \Spryker\Service\UtilEncoding\UtilEncodingServiceInterface
protected UtilEncodingServiceInterface $utilEncodingService;
* @param \Spryker\Service\UtilEncoding\UtilEncodingServiceInterface $utilEncodingService
public function __construct($utilEncodingService)
$this->utilEncodingService = $utilEncodingService;
}
* @param string $jsonValue
* @param bool $assoc Deprecated: `false` is deprecated, always use `true` for array return.
* @param int|null $depth
* @param int|null $options
*
* @return object|array<mixed>|null
public function decodeJson(string $jsonValue, bool $assoc = false, ?int $depth = null, ?int $options = null)
if ($assoc === false) {
trigger_error('Param #2 `$assoc` must be `true` as return of type `object` is not accepted.', E_USER_DEPRECATED);
/** @phpstan-var array<mixed>|null */
return $this->utilEncodingService->decodeJson($jsonValue, $assoc, $depth, $options);