private function getDeserializationDefinition(string $serialized): array
    {
        if (\trim($serialized) === '') {
            throw new EventSerializationException('Malformed JSON serialized event: empty string');
        }

        $definition = \json_decode($serialized, true, 512, static::JSON_DECODE_OPTIONS);

        // @codeCoverageIgnoreStart
        if ($definition === null || \json_last_error() !== \JSON_ERROR_NONE) {
            throw new EventSerializationException(\sprintf(
                'Event deserialization failed due to error %s: %s',
                \json_last_error(),
                \lcfirst(\json_last_error_msg())
            ));
        }
        // @codeCoverageIgnoreEnd

        return $definition;
    }
private function getDeserializationDefinition(string $serialized): array
    {
        if (\trim($serialized) === '') {
            throw new EventSerializationException('Malformed JSON serialized event: empty string');
        }

        $definition = \json_decode($serialized, true, 512, static::JSON_DECODE_OPTIONS);

        // @codeCoverageIgnoreStart
        if ($definition === null || \json_last_error() !== \JSON_ERROR_NONE) {
            throw new EventSerializationException(\sprintf(
                'Event deserialization failed due to error %s: %s',
                \json_last_error(),
                \lcfirst(\json_last_error_msg())
            ));
        }
        // @codeCoverageIgnoreEnd

        return $definition;
    }
private function getDeserializationDefinition ( string $ serialized ) : array { if ( \ trim ( $ serialized ) === '' ) { throw new EventSerializationException ( 'Malformed JSON serialized event: empty string' ) ; } $ definition = \ json_decode ( $ serialized , true , 512 , static :: JSON_DECODE_OPTIONS ) ; // @codeCoverageIgnoreStart if ( $ definition === null || \ json_last_error ( ) !== \ JSON_ERROR_NONE ) { throw new EventSerializationException ( \ sprintf ( 'Event deserialization failed due to error %s: %s' , \ json_last_error ( ) , \ lcfirst ( \ json_last_error_msg ( ) ) ) ) ; } // @codeCoverageIgnoreEnd return $ definition ; }
Get deserialization definition.

@param string $serialized

@return array<string, mixed>
Get deserialization definition .