[#BloombergLP-bslstl-Optional_DataImp-hasValue]
= xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bslstl.adoc[bslstl]::xref:BloombergLP/bslstl/Optional_DataImp.adoc[Optional&lowbar;DataImp]::hasValue
:relfileprefix: ../../../
:mrdocs:

Return `true` if this objects has a value, and `false` otherwise&period;

== Synopsis

Declared in `&lt;bslstl&lowbar;optional&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
bool
hasValue() const noexcept;
----

== Return Value

`true` if this object has a value, and `false` otherwise


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