protected function encode($content)
    {
        $jsonString = parent::encode($content);

        if ($this->hasValidCallback()) {
            return \sprintf('%s(%s);', $this->getCallback(), $jsonString);
        }

        return $jsonString;
    }
protected function encode($content)
    {
        $jsonString = parent::encode($content);

        if ($this->hasValidCallback()) {
            return \sprintf('%s(%s);', $this->getCallback(), $jsonString);
        }

        return $jsonString;
    }
protected function encode ( $ content ) { $ jsonString = parent :: encode ( $ content ) ; if ( $ this -> hasValidCallback ( ) ) { return \ sprintf ( '%s(%s);' , $ this -> getCallback ( ) , $ jsonString ) ; } return $ jsonString ; }
Encode the content to its JSONP representation.

@param mixed $content

@return string
Encode the content to its JSONP representation .