[#BloombergLP-bdljsn-JsonNumber-2constructor-01]
= xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bdljsn.adoc[bdljsn]::xref:BloombergLP/bdljsn/JsonNumber.adoc[JsonNumber]::JsonNumber
:relfileprefix: ../../../
:mrdocs:

Create a `JsonNumber` having the specified `value`&period;

== Synopsis

Declared in `&lt;bdljsn&lowbar;jsonnumber&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
explicit
JsonNumber(
    float value,
    xref:BloombergLP/bdljsn/JsonNumber/allocator_type.adoc[allocator&lowbar;type] const& allocator = allocator&lowbar;type());
----

== Description

Optionally specify an `allocator` (e&period;g&period;, the address of a `bslma&colon;&colon;Allocator` object) used to supply memory&period; The behavior is undefined if the `value` is infinite (`INF`) or not&hyphen;a&hyphen;number (`NaN`)&period;

== Parameters

[cols="1,4"]
|===
| Name| Description
| *value*
| numeric value to store
| *allocator*
| allocator used to supply memory
|===


[.small]#Created with https://www.mrdocs.com[MrDocs]#
