src/LearnositySdk/Utils/Json.php
private static function getHighPrecisionFloatMap($value)
    {
        if (!is_array($value)) {
            return static::getFloatMap($value);
        }

        $floatMap = [];
        foreach ($value as $entry) {
            $floatMap = array_merge(static::getHighPrecisionFloatMap($entry), $floatMap);
        }
        return $floatMap;
    }
private static function getHighPrecisionFloatMap($value)
    {
        if (!is_array($value)) {
            return static::getFloatMap($value);
        }

        $floatMap = [];
        foreach ($value as $entry) {
            $floatMap = array_merge(static::getHighPrecisionFloatMap($entry), $floatMap);
        }
        return $floatMap;
    }
private static function getHighPrecisionFloatMap ( $ value ) { if ( ! is_array ( $ value ) ) { return static :: getFloatMap ( $ value ) ; } $ floatMap = [ ] ; foreach ( $ value as $ entry ) { $ floatMap = array_merge ( static :: getHighPrecisionFloatMap ( $ entry ) , $ floatMap ) ; } return $ floatMap ; }
This function builds up a map of float values in scientific notation and the equivalent float
notations. json_encode encodes float values in scientific notation, but we want to make sure
they are in float notation

@param $value the $json to be encoded
@return array mapping scientific values to float values
This function builds up a map of float values in scientific notation and the equivalent float notations . json_encode encodes float values in scientific notation but we want to make sure they are in float notation