protected function serializeData($value)
    {
        $this->guardForUnsupportedValues($value);

        if ($this->isInstanceOf($value, 'SplFixedArray')) {
            return SplFixedArraySerializer::serialize($this, $value);
        }

        if (\is_object($value)) {
            return $this->serializeObject($value);
        }

        $type = (\gettype($value) && $value !== null) ? \gettype($value) : 'string';
        $func = $this->serializationMap[$type];

        return $this->$func($value);
    }
protected function serializeData($value)
    {
        $this->guardForUnsupportedValues($value);

        if ($this->isInstanceOf($value, 'SplFixedArray')) {
            return SplFixedArraySerializer::serialize($this, $value);
        }

        if (\is_object($value)) {
            return $this->serializeObject($value);
        }

        $type = (\gettype($value) && $value !== null) ? \gettype($value) : 'string';
        $func = $this->serializationMap[$type];

        return $this->$func($value);
    }
protected function serializeData ( $ value ) { $ this -> guardForUnsupportedValues ( $ value ) ; if ( $ this -> isInstanceOf ( $ value , 'SplFixedArray' ) ) { return SplFixedArraySerializer :: serialize ( $ this , $ value ) ; } if ( \ is_object ( $ value ) ) { return $ this -> serializeObject ( $ value ) ; } $ type = ( \ gettype ( $ value ) && $ value !== null ) ? \ gettype ( $ value ) : 'string' ; $ func = $ this -> serializationMap [ $ type ] ; return $ this -> $ func ( $ value ) ; }
Parse the data to be json encoded.

@param mixed $value

@return mixed

@throws SerializerException
Parse the data to be json encoded .