[#BloombergLP-ball-Log_Formatter] = xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/ball.adoc[ball]::Log_Formatter :relfileprefix: ../../ :mrdocs: Aggregate of objects used by the `printf`‐style logging macros. == Synopsis Declared in `<ball_log.h>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- class Log_Formatter; ---- == Description This class provides an aggregate of several objects relevant to the logging of a message via the `printf`‐style macros: ` * record to be logged * category to which to log the record * severity at which to log the record * buffer in which the user log message is formatted ` As a side‐effect of creating an object of this class, the record is constructed, and the buffer is obtained. As a side‐effect of destroying the object, the record is formatted, using the buffer, and logged. This class should _not_ be used directly by client code. It is an implementation detail of the macros provided by this component. == Member Functions [cols="1,4"] |=== | Name| Description | xref:BloombergLP/ball/Log_Formatter/2constructor.adoc[`Log_Formatter`] [.small]#[constructor]# | Create a logging formatter for the given category, location, and severity. | xref:BloombergLP/ball/Log_Formatter/2destructor.adoc[`~Log_Formatter`] [.small]#[destructor]# | Destroy this logging formatter and log its held record. | xref:BloombergLP/ball/Log_Formatter/category.adoc[`category`] | Return the address of the non‐modifiable category held by this logging formatter. | xref:BloombergLP/ball/Log_Formatter/messageBuffer.adoc[`messageBuffer`] | Return the address of the modifiable buffer held by this logging formatter. The address remains valid until this logging formatter is destroyed. | xref:BloombergLP/ball/Log_Formatter/messageBufferLen.adoc[`messageBufferLen`] | Return the length (in bytes) of the buffer held by this logging formatter. | xref:BloombergLP/ball/Log_Formatter/record-0d.adoc[`record`] | `record` overloads | xref:BloombergLP/ball/Log_Formatter/severity.adoc[`severity`] | Return the severity held by this logging formatter. |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#