[#BloombergLP-ball-LoggerManager-createLoggerManager-04]
= xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/ball.adoc[ball]::xref:BloombergLP/ball/LoggerManager.adoc[LoggerManager]::createLoggerManager
:relfileprefix: ../../../
:mrdocs:

Create a non&hyphen;singleton logger manager with the given observer&period;

== Synopsis

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

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
static
void
createLoggerManager(
    xref:BloombergLP/bslma/ManagedPtr-0fa.adoc[bslma::ManagedPtr&lt;LoggerManager&gt;]* manager,
    xref:BloombergLP/ball/Observer.adoc[Observer]* observer,
    xref:BloombergLP/ball/LoggerManagerConfiguration.adoc[LoggerManagerConfiguration] const& configuration,
    xref:BloombergLP/bslma/Allocator.adoc[bslma::Allocator]* basicAllocator = 0);
----

== Description

Create a logger manager that is _not_ the singleton logger manager having the specified `observer` that receives published log records and the specified `configuration` of defaults and attributes&semi; load the newly&hyphen;created logger manager into the specified `manager` managed pointer&period; Optionally specify a `basicAllocator` used to supply memory&period; If `basicAllocator` is 0, the currently installed default allocator is used&period; The behavior is undefined if `observer` is 0, goes out of scope, or is otherwise destroyed&period; Note that this method does _not_ create the singleton logger manager used by the macros of the BALL logging framework&period;

DEPRECATED&colon; Use the `createLoggerManager` method that does not take a _raw_ pointer to an `observer`, together with the `registerObserver` method (which takes a _shared_ pointer to an `observer`), instead&period;

== Parameters

[cols="1,4"]
|===
| Name| Description
| *manager*
| managed pointer that receives the new logger manager
| *observer*
| observer that receives published log records
| *configuration*
| defaults and attributes for the logger manager
| *basicAllocator*
| memory allocator&semi; null uses the default
|===


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