[#BloombergLP-ball-ObserverFormatterImp-2constructor]
= xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/ball.adoc[ball]::xref:BloombergLP/ball/ObserverFormatterImp.adoc[ObserverFormatterImp]::ObserverFormatterImp
:relfileprefix: ../../../
:mrdocs:

Create a `ObserverFormatterImp` instance that formats log records using the specified `format` and `timezoneDefault`&period; It is strongly advised to specify UTC for timezoneDefault&period; Optionally specify an `allocator` (e&period;g&period;, the address of a `bslma&colon;&colon;Allocator` object) to supply memory&semi; otherwise, the default allocator is used&period; The behavior is undefined unless `format` is a valid format string (either one that starts with a scheme or a &quot;text&quot; scheme format)&period; Note that not giving a valid default format string by the observer will result in no logging output if no valid format is set afterwards, so it is a serious error&period;

== Synopsis

Declared in `&lt;ball&lowbar;observerformatterimp&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
explicit
ObserverFormatterImp(
    std::string&lowbar;view const& format,
    xref:BloombergLP/ball/ObserverFormatterImp.adoc[TimezoneEnum] timezoneDefault,
    xref:BloombergLP/ball/ObserverFormatterImp/allocator_type.adoc[allocator&lowbar;type] const& allocator = allocator&lowbar;type());
----


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