_type = self::XMLRPC_TYPE_DOUBLE; $precision = (int)ini_get('precision'); $formatString = '%1.' . $precision . 'f'; $this->_value = sprintf($formatString, (float)$value); } /** * Return the value of this object, convert the XML-RPC native double value into a PHP float * * @return float */ public function getValue() { return (float)$this->_value; } }