php man page for splfloat

Query: splfloat

OS: php

Section: 3

Format: Original Unix Latex Style Formatted with HTML and a Horizontal Scroll Bar

SPLFLOAT(3)								 1							       SPLFLOAT(3)

The SplFloat class

INTRODUCTION
The SplFloat class is used to enforce strong typing of the float type.
CLASS SYNOPSIS
SplFloat SplFloatextends SplType Constants o const float$SplFloat::__default0 Inherited methods o SplType::__construct ([mixed $initial_value], [bool $strict])
PREDEFINED CONSTANTS
o SplFloat::__default -
EXAMPLES
Example #1 SplFloat usage example <?php $float = new SplFloat(3.154); $newFloat = new SplFloat(3); try { $float = 'Try to cast a string value for fun'; } catch (UnexpectedValueException $uve) { echo $uve->getMessage() . PHP_EOL; } echo $float . PHP_EOL; echo $newFloat . PHP_EOL; ?> The above example will output: Value not a float 3.154 3 PHP Documentation Group SPLFLOAT(3)
Related Man Pages
wxgraphicsmatrix(3erl) - linux
apc_inc(3) - php
swfdisplayitem(3) - php
is_float(3) - php
substr(3) - php
Similar Topics in the Unix Linux Community
UNIX.COM 2017 Year End Summary
Please Welcome Ravinder Singh to the Moderation Team
The Order of the Wizard's Hat - Lifetime Achievement Award 2019 - Congrats to Don Cragun
The Order of the Wizard's Hat - Lifetime Achievement Award 2019 - Congrats to Wolf Machowitsch
Please Welcome Nicki Paul to the Moderator Team!