<?xml version="1.0" standalone="yes"?>
<library-reference id="sinks"><title>Sinks</title><header name="boost/log/sinks/async_frontend.hpp">
<para><para>Andrey Semashev </para>

<para>14.07.2009</para>

The header contains implementation of asynchronous sink frontend. </para><namespace name="boost">
<namespace name="log">
<namespace name="sinks">
<class name="asynchronous_sink"><template>
      <template-type-parameter name="SinkBackendT"/>
      <template-type-parameter name="QueueingStrategyT"><default><classname alt="boost::log::sinks::unbounded_fifo_queue">unbounded_fifo_queue</classname></default></template-type-parameter>
    </template><inherit access="public">basic_sink_frontend</inherit><inherit access="public">unbounded_fifo_queue</inherit><purpose>Asynchronous logging sink frontend. </purpose><description><para>The frontend starts a separate thread on construction. All logging records are passed to the backend in this dedicated thread.</para><para>The user can prevent spawning the internal thread by specifying <computeroutput>start_thread</computeroutput> parameter with the value of <computeroutput>false</computeroutput> on construction. In this case log records will be buffered in the internal queue until the user calls <computeroutput>run</computeroutput>, <computeroutput>feed_records</computeroutput> or <computeroutput>flush</computeroutput> in his own thread. Log record queueing strategy is specified in the <computeroutput>QueueingStrategyT</computeroutput> template parameter. </para></description><class name="run_func"><purpose>Function object to run the log record feeding thread. </purpose><typedef name="result_type"><type>void</type></typedef>
<method-group name="public member functions">
<method name="operator()" cv="const"><type>result_type</type></method>
</method-group>
<constructor specifiers="explicit" cv="noexcept"><parameter name="self"><paramtype><classname>asynchronous_sink</classname> *</paramtype></parameter></constructor>
</class><class name="scoped_feeding_operation"><purpose>A scope guard that implements active operation management. </purpose><method-group name="public member functions">
</method-group>
<constructor specifiers="explicit"><parameter name="self"><paramtype><classname>asynchronous_sink</classname> &amp;</paramtype></parameter><purpose>Initializing constructor. </purpose></constructor>
<destructor><purpose>Destructor. </purpose></destructor>
<constructor cv="= delete"><parameter name=""><paramtype>scoped_feeding_operation const &amp;</paramtype></parameter></constructor>
<copy-assignment cv="= delete"><type>scoped_feeding_operation &amp;</type><parameter name=""><paramtype>scoped_feeding_operation const &amp;</paramtype></parameter></copy-assignment>
</class><class name="scoped_flag"><purpose>A scope guard that resets a flag on destructor. </purpose><method-group name="public member functions">
</method-group>
<constructor specifiers="explicit"><parameter name="mut"><paramtype>frontend_mutex_type &amp;</paramtype></parameter><parameter name="cond"><paramtype>condition_variable_any &amp;</paramtype></parameter><parameter name="f"><paramtype>boost::atomic&lt; bool &gt; &amp;</paramtype></parameter></constructor>
<destructor/>
<constructor cv="= delete"><parameter name=""><paramtype>scoped_flag const &amp;</paramtype></parameter></constructor>
<copy-assignment cv="= delete"><type>scoped_flag &amp;</type><parameter name=""><paramtype>scoped_flag const &amp;</paramtype></parameter></copy-assignment>
</class><typedef name="sink_backend_type"><purpose>Sink implementation type. </purpose><type>SinkBackendT</type></typedef>
<typedef name="locked_backend_ptr"><purpose>A pointer type that locks the backend until it's destroyed. </purpose><type>implementation_defined</type></typedef>
<method-group name="public member functions">
<method name="locked_backend"><type>locked_backend_ptr</type><description><para>Locking accessor to the attached backend </para></description></method>
<method name="consume" specifiers="virtual"><type>void</type><parameter name="rec"><paramtype>record_view const &amp;</paramtype></parameter><description><para>Enqueues the log record to the backend </para></description></method>
<method name="try_consume" specifiers="virtual"><type>bool</type><parameter name="rec"><paramtype>record_view const &amp;</paramtype></parameter><description><para>The method attempts to pass logging record to the backend </para></description></method>
<method name="run"><type>void</type><description><para>The method starts record feeding loop and effectively blocks until either of this happens:</para><para><itemizedlist>
<listitem><para>the thread is interrupted due to either standard thread interruption or a call to <computeroutput>stop</computeroutput> </para>
</listitem>
<listitem><para>an exception is thrown while processing a log record in the backend, and the exception is not terminated by the exception handler, if one is installed</para>
</listitem>
</itemizedlist>

</para></description><requires><para>The sink frontend must be constructed without spawning a dedicated thread </para>
</requires></method>
<method name="stop"><type>void</type><description><para>The method softly interrupts record feeding loop. This method must be called when <computeroutput>run</computeroutput>, <computeroutput>feed_records</computeroutput> or <computeroutput>flush</computeroutput> method execution has to be interrupted. Unlike regular thread interruption, calling <computeroutput>stop</computeroutput> will not interrupt the record processing in the middle. Instead, the sink frontend will attempt to finish its business with the record in progress and return afterwards. This method can be called either if the sink was created with an internal dedicated thread, or if the feeding loop was initiated by user.</para><para>If no record feeding operation is in progress, calling <computeroutput>stop</computeroutput> marks the sink frontend so that the next feeding operation stops immediately.</para><para><note><para>Returning from this method does not guarantee that there are no records left buffered in the sink frontend. It is possible that log records keep coming during and after this method is called. At some point of execution of this method log records stop being processed, and all records that come after this point are put into the queue. These records will be processed upon further calls to <computeroutput>run</computeroutput> or <computeroutput>feed_records</computeroutput>.</para>
</note>
<note><para>If the record feeding loop is being run in a user's thread (i.e. <computeroutput>start_thread</computeroutput> was specified as <computeroutput>false</computeroutput> on frontend construction), this method does not guarantee that upon return the thread has returned from the record feeding loop or that it won't enter it in the future. The method only ensures that the record feeding thread will eventually return from the feeding loop. It is user's responsibility to synchronize with the user's record feeding thread. </para>
</note>
</para></description></method>
<method name="feed_records"><type>void</type><description><para>The method feeds log records that may have been buffered to the backend and returns</para><para>
</para></description><requires><para>The sink frontend must be constructed without spawning a dedicated thread </para>
</requires></method>
<method name="flush" specifiers="virtual"><type>void</type><description><para>The method feeds all log records that may have been buffered to the backend and returns. Unlike <computeroutput>feed_records</computeroutput>, in case of ordering queueing the method also feeds records that were enqueued during the ordering window, attempting to drain the queue completely. </para></description></method>
</method-group>
<constructor specifiers="explicit"><parameter name="start_thread"><paramtype>bool</paramtype><default>true</default><description><para>If <computeroutput>true</computeroutput>, the frontend creates a thread to feed log records to the backend. Otherwise no thread is started and it is assumed that the user will call <computeroutput>run</computeroutput>, <computeroutput>feed_records</computeroutput> or <computeroutput>flush</computeroutput> himself. </para></description></parameter><description><para>Default constructor. Constructs the sink backend instance. Requires the backend to be default-constructible.</para><para>
</para></description></constructor>
<constructor specifiers="explicit"><parameter name="backend"><paramtype>shared_ptr&lt; sink_backend_type &gt; const &amp;</paramtype><description><para>Pointer to the backend instance. </para></description></parameter><parameter name="start_thread"><paramtype>bool</paramtype><default>true</default><description><para>If <computeroutput>true</computeroutput>, the frontend creates a thread to feed log records to the backend. Otherwise no thread is started and it is assumed that the user will call <computeroutput>run</computeroutput>, <computeroutput>feed_records</computeroutput> or <computeroutput>flush</computeroutput> himself.</para></description></parameter><description><para>Constructor attaches user-constructed backend instance</para><para>

</para></description><requires><para><emphasis>backend</emphasis> is not <computeroutput>NULL</computeroutput>. </para>
</requires></constructor>
<constructor specifiers="explicit"><template>
          <template-nontype-parameter name="Args"><type>typename...</type></template-nontype-parameter>
        </template><parameter name="args"><paramtype>Args &amp;&amp;...</paramtype></parameter><description><para>Constructor that passes arbitrary named parameters to the interprocess sink backend constructor. Refer to the backend documentation for the list of supported parameters.</para><para>The frontend uses the following named parameters:</para><para><itemizedlist>
<listitem><para>start_thread - If <computeroutput>true</computeroutput>, the frontend creates a thread to feed log records to the backend. Otherwise no thread is started and it is assumed that the user will call <computeroutput>run</computeroutput>, <computeroutput>feed_records</computeroutput> or <computeroutput>flush</computeroutput> himself. </para>
</listitem>
</itemizedlist>
</para></description></constructor>
<destructor><description><para>Destructor. Implicitly stops the dedicated feeding thread, if one is running. </para></description></destructor>
</class></namespace>
</namespace>
</namespace>
</header>
<header name="boost/log/sinks/attribute_mapping.hpp">
<para><para>Andrey Semashev </para>

<para>07.11.2008</para>

The header contains facilities that are used in different sinks to map attribute values used throughout the application to values used with the specific native logging API. These tools are mostly needed to map application severity levels on native levels, required by OS-specific sink backends. </para><namespace name="boost">
<namespace name="log">
<namespace name="sinks">
<class name="basic_custom_mapping"><template>
      <template-type-parameter name="MappedT"/>
      <template-type-parameter name="AttributeValueT"><default>int</default></template-type-parameter>
    </template><inherit access="public">boost::log::sinks::basic_mapping&lt; MappedT &gt;</inherit><purpose>Customizable mapping. </purpose><description><para>The class allows to setup a custom mapping between an attribute and native values. The mapping should be initialized similarly to the standard <computeroutput>map</computeroutput> container, by using indexing operator and assignment.</para><para><note><para>Unlike many other components of the library, exact type of the attribute value must be specified in the template parameter <computeroutput>AttributeValueT</computeroutput>. Type sequences are not supported. </para>
</note>
</para></description><typedef name="attribute_value_type"><purpose>Attribute contained value type. </purpose><type>AttributeValueT</type></typedef>
<typedef name="mapped_type"><purpose>Mapped value type. </purpose><type>base_type::mapped_type</type></typedef>
<method-group name="public member functions">
<method name="operator()" cv="const"><type>mapped_type</type><parameter name="rec"><paramtype>record_view const &amp;</paramtype><description><para>A log record to extract value from </para></description></parameter><description><para>Extraction operator. Extracts the attribute value and attempts to map it onto the native value.</para><para>

</para></description><returns><para>A mapped value, if mapping was successful, or the default value if mapping did not succeed. </para>
</returns></method>
<method name="operator[]"><type>implementation_defined</type><parameter name="key"><paramtype>attribute_value_type const &amp;</paramtype><description><para>Attribute value to be mapped </para></description></parameter><description><para>Insertion operator</para><para>

</para></description><returns><para>An object of unspecified type that allows to insert a new mapping through assignment. The <emphasis>key</emphasis> argument becomes the key attribute value, and the assigned value becomes the mapped native value. </para>
</returns></method>
</method-group>
<constructor specifiers="explicit"><parameter name="name"><paramtype>attribute_name const &amp;</paramtype><description><para>Attribute name </para></description></parameter><parameter name="default_value"><paramtype>mapped_type const &amp;</paramtype><description><para>The default native value that is returned if the conversion cannot be performed </para></description></parameter><description><para>Constructor</para><para>
</para></description></constructor>
</class><class name="basic_direct_mapping"><template>
      <template-type-parameter name="MappedT"/>
      <template-type-parameter name="AttributeValueT"><default>int</default></template-type-parameter>
    </template><inherit access="public">boost::log::sinks::basic_mapping&lt; MappedT &gt;</inherit><purpose>Straightforward mapping. </purpose><description><para>This type of mapping assumes that attribute with a particular name always provides values that map directly onto the native values. The mapping simply returns the extracted attribute value converted to the native value. </para></description><typedef name="attribute_value_type"><purpose>Attribute contained value type. </purpose><type>AttributeValueT</type></typedef>
<typedef name="mapped_type"><purpose>Mapped value type. </purpose><type>base_type::mapped_type</type></typedef>
<method-group name="public member functions">
<method name="operator()" cv="const"><type>mapped_type</type><parameter name="rec"><paramtype>record_view const &amp;</paramtype><description><para>A log record to extract value from </para></description></parameter><description><para>Extraction operator</para><para>

</para></description><returns><para>An extracted attribute value </para>
</returns></method>
</method-group>
<constructor specifiers="explicit"><parameter name="name"><paramtype>attribute_name const &amp;</paramtype><description><para>Attribute name </para></description></parameter><parameter name="default_value"><paramtype>mapped_type const &amp;</paramtype><description><para>The default native value that is returned if the attribute value is not found </para></description></parameter><description><para>Constructor</para><para>
</para></description></constructor>
</class><struct name="basic_mapping"><template>
      <template-type-parameter name="MappedT"/>
    </template><purpose>Base class for attribute mapping function objects. </purpose><typedef name="mapped_type"><purpose>Mapped value type. </purpose><type>MappedT</type></typedef>
<typedef name="result_type"><purpose>Result type. </purpose><type>mapped_type</type></typedef>
</struct></namespace>
</namespace>
</namespace>
</header>
<header name="boost/log/sinks/auto_newline_mode.hpp">
<para><para>Andrey Semashev </para>

<para>23.06.2019</para>

The header contains definition of auto-newline modes. </para><namespace name="boost">
<namespace name="log">
<namespace name="sinks">
<enum name="auto_newline_mode"><enumvalue name="disabled_auto_newline"><purpose>Do not insert automatic trailing newline characters. </purpose></enumvalue><enumvalue name="always_insert"><purpose>Always insert automatic trailing newline characters. </purpose></enumvalue><enumvalue name="insert_if_missing"><purpose>Insert automatic trailing newline characters, if not present already. </purpose></enumvalue><purpose>The enum lists automatic trailing newline modes. </purpose></enum>
</namespace>
</namespace>
</namespace>
</header>
<header name="boost/log/sinks/basic_sink_backend.hpp">
<para><para>Andrey Semashev </para>

<para>04.11.2007</para>

The header contains implementation of base classes for sink backends. </para><namespace name="boost">
<namespace name="log">
<namespace name="sinks">
<struct name="basic_formatted_sink_backend"><template>
      <template-type-parameter name="CharT"/>
      <template-type-parameter name="FrontendRequirementsT"><default><classname alt="boost::log::sinks::synchronized_feeding">synchronized_feeding</classname></default></template-type-parameter>
    </template><inherit access="public">boost::log::sinks::basic_sink_backend&lt; combine_requirements&lt; synchronized_feeding, formatted_records &gt;::type &gt;</inherit><purpose>A base class for a logging sink backend with message formatting support. </purpose><description><para>The <computeroutput><classname alt="boost::log::sinks::basic_formatted_sink_backend">basic_formatted_sink_backend</classname></computeroutput> class template indicates to the frontend that the backend requires logging record formatting.</para><para>The class allows to request encoding conversion in case if the sink backend requires the formatted string in some particular encoding (e.g. if underlying API supports only narrow or wide characters). In order to perform conversion one should specify the desired final character type in the <computeroutput>TargetCharT</computeroutput> template parameter. </para></description><typedef name="char_type"><purpose>Character type. </purpose><type>CharT</type></typedef>
<typedef name="string_type"><purpose>Formatted string type. </purpose><type>std::basic_string&lt; char_type &gt;</type></typedef>
<typedef name="frontend_requirements"><purpose>Frontend requirements. </purpose><type>base_type::frontend_requirements</type></typedef>
</struct><struct name="basic_sink_backend"><template>
      <template-type-parameter name="FrontendRequirementsT"/>
    </template><purpose>Base class for a logging sink backend. </purpose><description><para>The <computeroutput><classname alt="boost::log::sinks::basic_sink_backend">basic_sink_backend</classname></computeroutput> class template defines a number of types that all sink backends are required to define. All sink backends have to derive from the class. </para></description><typedef name="frontend_requirements"><purpose>Frontend requirements tag. </purpose><type>FrontendRequirementsT</type></typedef>
<method-group name="public member functions">
</method-group>
<constructor cv="= default"/>
<constructor cv="= delete"><parameter name=""><paramtype><classname>basic_sink_backend</classname> const &amp;</paramtype></parameter></constructor>
<copy-assignment cv="= delete"><type><classname>basic_sink_backend</classname> &amp;</type><parameter name=""><paramtype><classname>basic_sink_backend</classname> const &amp;</paramtype></parameter></copy-assignment>
</struct></namespace>
</namespace>
</namespace>
</header>
<header name="boost/log/sinks/basic_sink_frontend.hpp">
<para><para>Andrey Semashev </para>

<para>14.07.2009</para>

The header contains implementation of a base class for sink frontends. </para><namespace name="boost">
<namespace name="log">
<namespace name="sinks">
<class name="basic_formatting_sink_frontend"><template>
      <template-type-parameter name="CharT"/>
    </template><inherit access="public">basic_sink_frontend</inherit><purpose>A base class for a logging sink frontend with formatting support. </purpose><struct name="formatting_context"><class name="cleanup_guard"><method-group name="public member functions">
</method-group>
<constructor specifiers="explicit" cv="noexcept"><parameter name="ctx"><paramtype>formatting_context &amp;</paramtype></parameter></constructor>
<destructor/>
<constructor cv="= delete"><parameter name=""><paramtype>cleanup_guard const &amp;</paramtype></parameter></constructor>
<copy-assignment cv="= delete"><type>cleanup_guard &amp;</type><parameter name=""><paramtype>cleanup_guard const &amp;</paramtype></parameter></copy-assignment>
</class><data-member name="m_Version"><type>const unsigned int</type><purpose>Object version. </purpose></data-member>
<data-member name="m_FormattedRecord"><type>string_type</type><purpose>Formatted log record storage. </purpose></data-member>
<data-member name="m_FormattingStream"><type>stream_type</type><purpose>Formatting stream. </purpose></data-member>
<data-member name="m_Formatter"><type>formatter_type</type><purpose>Formatter functor. </purpose></data-member>
<method-group name="public member functions">
</method-group>
<constructor/>
<constructor><parameter name="version"><paramtype>unsigned int</paramtype></parameter><parameter name="loc"><paramtype>std::locale const &amp;</paramtype></parameter><parameter name="formatter"><paramtype>formatter_type const &amp;</paramtype></parameter></constructor>
</struct><typedef name="char_type"><purpose>Character type. </purpose><type>CharT</type></typedef>
<typedef name="string_type"><purpose>Formatted string type. </purpose><type>std::basic_string&lt; char_type &gt;</type></typedef>
<typedef name="formatter_type"><purpose>Formatter function object type. </purpose><type>basic_formatter&lt; char_type &gt;</type></typedef>
<typedef name="stream_type"><purpose>Output stream type. </purpose><type>formatter_type::stream_type</type></typedef>
<method-group name="public member functions">
<method name="set_formatter"><type>void</type><template>
          <template-type-parameter name="FunT"/>
        </template><parameter name="formatter"><paramtype>FunT const &amp;</paramtype></parameter><description><para>The method sets sink-specific formatter function object </para></description></method>
<method name="reset_formatter"><type>void</type><description><para>The method resets the formatter </para></description></method>
<method name="getloc" cv="const"><type>std::locale</type><description><para>The method returns the current locale used for formatting </para></description></method>
<method name="imbue"><type>void</type><parameter name="loc"><paramtype>std::locale const &amp;</paramtype></parameter><description><para>The method sets the locale used for formatting </para></description></method>
</method-group>
<constructor specifiers="explicit"><parameter name="cross_thread"><paramtype>bool</paramtype><description><para>The flag indicates whether the sink passes log records between different threads </para></description></parameter><purpose>Initializing constructor. </purpose><description><para>
</para></description></constructor>
<method-group name="protected member functions">
<method name="formatter"><type>formatter_type &amp;</type><purpose>Returns reference to the formatter. </purpose></method>
<method name="feed_record"><type>void</type><template>
          <template-type-parameter name="BackendMutexT"/>
          <template-type-parameter name="BackendT"/>
        </template><parameter name="rec"><paramtype>record_view const &amp;</paramtype></parameter><parameter name="backend_mutex"><paramtype>BackendMutexT &amp;</paramtype></parameter><parameter name="backend"><paramtype>BackendT &amp;</paramtype></parameter><purpose>Feeds log record to the backend. </purpose></method>
<method name="try_feed_record"><type>bool</type><template>
          <template-type-parameter name="BackendMutexT"/>
          <template-type-parameter name="BackendT"/>
        </template><parameter name="rec"><paramtype>record_view const &amp;</paramtype></parameter><parameter name="backend_mutex"><paramtype>BackendMutexT &amp;</paramtype></parameter><parameter name="backend"><paramtype>BackendT &amp;</paramtype></parameter><purpose>Attempts to feeds log record to the backend, does not block if <emphasis>backend_mutex</emphasis> is locked. </purpose></method>
</method-group>
</class><class name="basic_sink_frontend"><inherit access="public">sink</inherit><purpose>A base class for a logging sink frontend. </purpose><typedef name="exception_handler_type"><purpose>An exception handler type. </purpose><type>base_type::exception_handler_type</type></typedef>
<method-group name="public member functions">
<method name="set_filter"><type>void</type><template>
          <template-type-parameter name="FunT"/>
        </template><parameter name="filter"><paramtype>FunT const &amp;</paramtype></parameter><description><para>The method sets sink-specific filter functional object </para></description></method>
<method name="reset_filter"><type>void</type><description><para>The method resets the filter </para></description></method>
<method name="set_exception_handler"><type>void</type><template>
          <template-type-parameter name="FunT"/>
        </template><parameter name="handler"><paramtype>FunT const &amp;</paramtype></parameter><description><para>The method sets an exception handler function </para></description></method>
<method name="reset_exception_handler"><type>void</type><description><para>The method resets the exception handler function </para></description></method>
<method name="will_consume" specifiers="virtual"><type>bool</type><parameter name="attrs"><paramtype>attribute_value_set const &amp;</paramtype><description><para>A set of attribute values of a logging record </para></description></parameter><description><para>The method returns <computeroutput>true</computeroutput> if no filter is set or the attribute values pass the filter</para><para>
</para></description></method>
</method-group>
<constructor specifiers="explicit"><parameter name="cross_thread"><paramtype>bool</paramtype><description><para>The flag indicates whether the sink passes log records between different threads </para></description></parameter><purpose>Initializing constructor. </purpose><description><para>
</para></description></constructor>
<method-group name="protected member functions">
<method name="frontend_mutex" cv="const"><type>mutex_type &amp;</type><purpose>Returns reference to the frontend mutex. </purpose></method>
<method name="exception_handler"><type>exception_handler_type &amp;</type><purpose>Returns reference to the exception handler. </purpose></method>
<method name="exception_handler" cv="const"><type>exception_handler_type const &amp;</type><purpose>Returns reference to the exception handler. </purpose></method>
<method name="feed_record"><type>void</type><template>
          <template-type-parameter name="BackendMutexT"/>
          <template-type-parameter name="BackendT"/>
        </template><parameter name="rec"><paramtype>record_view const &amp;</paramtype></parameter><parameter name="backend_mutex"><paramtype>BackendMutexT &amp;</paramtype></parameter><parameter name="backend"><paramtype>BackendT &amp;</paramtype></parameter><purpose>Feeds log record to the backend. </purpose></method>
<method name="try_feed_record"><type>bool</type><template>
          <template-type-parameter name="BackendMutexT"/>
          <template-type-parameter name="BackendT"/>
        </template><parameter name="rec"><paramtype>record_view const &amp;</paramtype></parameter><parameter name="backend_mutex"><paramtype>BackendMutexT &amp;</paramtype></parameter><parameter name="backend"><paramtype>BackendT &amp;</paramtype></parameter><purpose>Attempts to feeds log record to the backend, does not block if <emphasis>backend_mutex</emphasis> is locked. </purpose></method>
<method name="flush_backend"><type>void</type><template>
          <template-type-parameter name="BackendMutexT"/>
          <template-type-parameter name="BackendT"/>
        </template><parameter name="backend_mutex"><paramtype>BackendMutexT &amp;</paramtype></parameter><parameter name="backend"><paramtype>BackendT &amp;</paramtype></parameter><purpose>Flushes record buffers in the backend, if one supports it. </purpose></method>
</method-group>
<method-group name="private member functions">
<method name="flush_backend_impl"><type>void</type><template>
          <template-type-parameter name="BackendMutexT"/>
          <template-type-parameter name="BackendT"/>
        </template><parameter name="backend_mutex"><paramtype>BackendMutexT &amp;</paramtype></parameter><parameter name="backend"><paramtype>BackendT &amp;</paramtype></parameter><parameter name=""><paramtype>boost::true_type</paramtype></parameter><purpose>Flushes record buffers in the backend (the actual implementation) </purpose></method>
<method name="flush_backend_impl"><type>void</type><template>
          <template-type-parameter name="BackendMutexT"/>
          <template-type-parameter name="BackendT"/>
        </template><parameter name=""><paramtype>BackendMutexT &amp;</paramtype></parameter><parameter name=""><paramtype>BackendT &amp;</paramtype></parameter><parameter name=""><paramtype>boost::false_type</paramtype></parameter><purpose>Flushes record buffers in the backend (stub for backends that don't support flushing) </purpose></method>
</method-group>
</class></namespace>
</namespace>
</namespace>
</header>
<header name="boost/log/sinks/block_on_overflow.hpp">
<para><para>Andrey Semashev </para>

<para>04.01.2012</para>

The header contains implementation of <computeroutput>block_on_overflow</computeroutput> strategy for handling queue overflows in bounded queues for the asynchronous sink frontend. </para><namespace name="boost">
<namespace name="log">
<namespace name="sinks">
<class name="block_on_overflow"><purpose>Blocking strategy for handling log record queue overflows. </purpose><description><para>This strategy will cause enqueueing threads to block when the log record queue overflows. The blocked threads will be woken as soon as there appears free space in the queue, in the same order they attempted to enqueue records. </para></description></class></namespace>
</namespace>
</namespace>
</header>
<header name="boost/log/sinks/bounded_fifo_queue.hpp">
<para><para>Andrey Semashev </para>

<para>04.01.2012</para>

The header contains implementation of bounded FIFO queueing strategy for the asynchronous sink frontend. </para><namespace name="boost">
<namespace name="log">
<namespace name="sinks">
<class name="bounded_fifo_queue"><template>
      <template-nontype-parameter name="MaxQueueSizeV"><type>std::size_t</type></template-nontype-parameter>
      <template-type-parameter name="OverflowStrategyT"/>
    </template><inherit access="private">OverflowStrategyT</inherit><purpose>Bounded FIFO log record queueing strategy. </purpose><description><para>The <computeroutput><classname alt="boost::log::sinks::bounded_fifo_queue">bounded_fifo_queue</classname></computeroutput> class is intended to be used with the <computeroutput><classname alt="boost::log::sinks::asynchronous_sink">asynchronous_sink</classname></computeroutput> frontend as a log record queueing strategy.</para><para>This strategy describes log record queueing logic. The queue has a limited capacity, upon reaching which the enqueue operation will invoke the overflow handling strategy specified in the <computeroutput>OverflowStrategyT</computeroutput> template parameter to handle the situation. The library provides overflow handling strategies for most common cases: <computeroutput><classname alt="boost::log::sinks::drop_on_overflow">drop_on_overflow</classname></computeroutput> will silently discard the log record, and <computeroutput><classname alt="boost::log::sinks::block_on_overflow">block_on_overflow</classname></computeroutput> will put the enqueueing thread to wait until there is space in the queue.</para><para>The log record queue imposes no ordering over the queued elements aside from the order in which they are enqueued. </para></description><method-group name="protected member functions">
<method name="enqueue"><type>void</type><parameter name="rec"><paramtype>record_view const &amp;</paramtype></parameter><purpose>Enqueues log record to the queue. </purpose></method>
<method name="try_enqueue"><type>bool</type><parameter name="rec"><paramtype>record_view const &amp;</paramtype></parameter><purpose>Attempts to enqueue log record to the queue. </purpose></method>
<method name="try_dequeue_ready"><type>bool</type><parameter name="rec"><paramtype>record_view &amp;</paramtype></parameter><purpose>Attempts to dequeue a log record ready for processing from the queue, does not block if the queue is empty. </purpose></method>
<method name="try_dequeue"><type>bool</type><parameter name="rec"><paramtype>record_view &amp;</paramtype></parameter><purpose>Attempts to dequeue log record from the queue, does not block if the queue is empty. </purpose></method>
<method name="dequeue_ready"><type>bool</type><parameter name="rec"><paramtype>record_view &amp;</paramtype></parameter><purpose>Dequeues log record from the queue, blocks if the queue is empty. </purpose></method>
<method name="interrupt_dequeue"><type>void</type><purpose>Wakes a thread possibly blocked in the <computeroutput>dequeue</computeroutput> method. </purpose></method>
</method-group>
<constructor><purpose>Default constructor. </purpose></constructor>
<constructor specifiers="explicit"><template>
          <template-type-parameter name="ArgsT"/>
        </template><parameter name=""><paramtype>ArgsT const &amp;</paramtype></parameter><purpose>Initializing constructor. </purpose></constructor>
</class></namespace>
</namespace>
</namespace>
</header>
<header name="boost/log/sinks/bounded_ordering_queue.hpp">
<para><para>Andrey Semashev </para>

<para>06.01.2012</para>

The header contains implementation of bounded ordering queueing strategy for the asynchronous sink frontend. </para><namespace name="boost">
<namespace name="log">
<namespace name="sinks">
<class name="bounded_ordering_queue"><template>
      <template-type-parameter name="OrderT"/>
      <template-nontype-parameter name="MaxQueueSizeV"><type>std::size_t</type></template-nontype-parameter>
      <template-type-parameter name="OverflowStrategyT"/>
    </template><inherit access="private">OverflowStrategyT</inherit><purpose>Bounded ordering log record queueing strategy. </purpose><description><para>The <computeroutput><classname alt="boost::log::sinks::bounded_ordering_queue">bounded_ordering_queue</classname></computeroutput> class is intended to be used with the <computeroutput><classname alt="boost::log::sinks::asynchronous_sink">asynchronous_sink</classname></computeroutput> frontend as a log record queueing strategy.</para><para>This strategy provides the following properties to the record queueing mechanism:</para><para><itemizedlist>
<listitem><para>The queue has limited capacity specified by the <computeroutput>MaxQueueSizeV</computeroutput> template parameter. </para>
</listitem>
<listitem><para>Upon reaching the size limit, the queue invokes the overflow handling strategy specified in the <computeroutput>OverflowStrategyT</computeroutput> template parameter to handle the situation. The library provides overflow handling strategies for most common cases: <computeroutput><classname alt="boost::log::sinks::drop_on_overflow">drop_on_overflow</classname></computeroutput> will silently discard the log record, and <computeroutput><classname alt="boost::log::sinks::block_on_overflow">block_on_overflow</classname></computeroutput> will put the enqueueing thread to wait until there is space in the queue. </para>
</listitem>
<listitem><para>The queue has a fixed latency window. This means that each log record put into the queue will normally not be dequeued for a certain period of time. </para>
</listitem>
<listitem><para>The queue performs stable record ordering within the latency window. The ordering predicate can be specified in the <computeroutput>OrderT</computeroutput> template parameter. </para>
</listitem>
</itemizedlist>
</para></description><method-group name="public member functions">
<method name="get_ordering_window" cv="const"><type>posix_time::time_duration</type><description><para>Returns ordering window size specified during initialization </para></description></method>
</method-group>
<method-group name="public static functions">
<method name="get_default_ordering_window" specifiers="static"><type>posix_time::time_duration</type><description><para>Returns default ordering window size. The default window size is specific to the operating system thread scheduling mechanism. </para></description></method>
</method-group>
<method-group name="protected member functions">
<method name="enqueue"><type>void</type><parameter name="rec"><paramtype>record_view const &amp;</paramtype></parameter><purpose>Enqueues log record to the queue. </purpose></method>
<method name="try_enqueue"><type>bool</type><parameter name="rec"><paramtype>record_view const &amp;</paramtype></parameter><purpose>Attempts to enqueue log record to the queue. </purpose></method>
<method name="try_dequeue_ready"><type>bool</type><parameter name="rec"><paramtype>record_view &amp;</paramtype></parameter><purpose>Attempts to dequeue a log record ready for processing from the queue, does not block if the queue is empty. </purpose></method>
<method name="try_dequeue"><type>bool</type><parameter name="rec"><paramtype>record_view &amp;</paramtype></parameter><purpose>Attempts to dequeue log record from the queue, does not block if the queue is empty. </purpose></method>
<method name="dequeue_ready"><type>bool</type><parameter name="rec"><paramtype>record_view &amp;</paramtype></parameter><purpose>Dequeues log record from the queue, blocks if the queue is empty. </purpose></method>
<method name="interrupt_dequeue"><type>void</type><purpose>Wakes a thread possibly blocked in the <computeroutput>dequeue</computeroutput> method. </purpose></method>
</method-group>
<constructor specifiers="explicit"><template>
          <template-type-parameter name="ArgsT"/>
        </template><parameter name="args"><paramtype>ArgsT const &amp;</paramtype></parameter><purpose>Initializing constructor. </purpose></constructor>
</class></namespace>
</namespace>
</namespace>
</header>
<header name="boost/log/sinks/debug_output_backend.hpp">
<para><para>Andrey Semashev </para>

<para>07.11.2008</para>

The header contains a logging sink backend that outputs log records to the debugger. </para><namespace name="boost">
<namespace name="log">
<namespace name="sinks">
<class name="basic_debug_output_backend"><template>
      <template-type-parameter name="CharT"/>
    </template><inherit access="public">basic_formatted_sink_backend&lt; CharT, concurrent_feeding &gt;</inherit><purpose>An implementation of a logging sink backend that outputs to the debugger. </purpose><description><para>The sink uses Windows API in order to write log records as debug messages, if the application process is run under debugger. The sink backend also provides a specific filter that allows to check whether the debugger is available and thus elide unnecessary formatting. </para></description><typedef name="char_type"><purpose>Character type. </purpose><type>base_type::char_type</type></typedef>
<typedef name="string_type"><purpose>String type to be used as a message text holder. </purpose><type>base_type::string_type</type></typedef>
<method-group name="public member functions">
<method name="consume"><type>void</type><parameter name="rec"><paramtype>record_view const &amp;</paramtype></parameter><parameter name="formatted_message"><paramtype>string_type const &amp;</paramtype></parameter><description><para>The method passes the formatted message to debugger </para></description></method>
</method-group>
<constructor><description><para>Constructor. Initializes the sink backend. </para></description></constructor>
<destructor><description><para>Destructor </para></description></destructor>
</class><typedef name="debug_output_backend"><purpose>Convenience typedef for narrow-character logging. </purpose><type><classname>basic_debug_output_backend</classname>&lt; char &gt;</type></typedef>
<typedef name="wdebug_output_backend"><purpose>Convenience typedef for wide-character logging. </purpose><type><classname>basic_debug_output_backend</classname>&lt; wchar_t &gt;</type></typedef>
</namespace>
</namespace>
</namespace>
</header>
<header name="boost/log/sinks/drop_on_overflow.hpp">
<para><para>Andrey Semashev </para>

<para>04.01.2012</para>

The header contains implementation of <computeroutput>drop_on_overflow</computeroutput> strategy for handling queue overflows in bounded queues for the asynchronous sink frontend. </para><namespace name="boost">
<namespace name="log">
<namespace name="sinks">
<class name="drop_on_overflow"><purpose>Log record dropping strategy. </purpose><description><para>This strategy will cause log records to be discarded in case of queue overflow in bounded asynchronous sinks. It should not be used if losing log records is not acceptable. </para></description></class></namespace>
</namespace>
</namespace>
</header>
<header name="boost/log/sinks/event_log_backend.hpp">
<para><para>Andrey Semashev </para>

<para>07.11.2008</para>

The header contains a logging sink backend that uses Windows NT event log API for signaling application events. </para><namespace name="boost">
<namespace name="log">
<namespace name="sinks">
<class name="basic_event_log_backend"><template>
      <template-type-parameter name="CharT"/>
    </template><inherit access="public">basic_sink_backend&lt; synchronized_feeding &gt;</inherit><purpose>An implementation of a logging sink backend that emits events into Windows NT event log. </purpose><description><para>The sink uses Windows NT 5 (Windows 2000) and later event log API to emit events to an event log. The sink acts as an event source. Unlike <computeroutput><classname alt="boost::log::sinks::basic_simple_event_log_backend">basic_simple_event_log_backend</classname></computeroutput>, this sink backend allows users to specify the custom event message file and supports mapping attribute values onto several insertion strings. Although it requires considerably more scaffolding than the simple backend, this allows to support localizable event descriptions.</para><para>Besides the file name of the module with event resources, the backend provides the following customizations: <itemizedlist>
<listitem><para>Remote server UNC address, log name and source name. These parameters have similar meaning to <computeroutput><classname alt="boost::log::sinks::basic_simple_event_log_backend">basic_simple_event_log_backend</classname></computeroutput>. </para>
</listitem>
<listitem><para>Event type and category mappings. These are function object that allow to map attribute values to the according event parameters. One can use mappings in the <computeroutput>event_log</computeroutput> namespace. </para>
</listitem>
<listitem><para>Event composer. This function object extracts event identifier and formats string insertions, that will be used by the API to compose the final event message text. </para>
</listitem>
</itemizedlist>
</para></description><typedef name="char_type"><purpose>Character type. </purpose><type>CharT</type></typedef>
<typedef name="string_type"><purpose>String type. </purpose><type>std::basic_string&lt; char_type &gt;</type></typedef>
<typedef name="insertion_list"><purpose>Type of the composed insertions list. </purpose><type>std::vector&lt; string_type &gt;</type></typedef>
<typedef name="event_type_mapper_type"><purpose>Mapper type for the event type. </purpose><type><emphasis>unspecified</emphasis></type></typedef>
<typedef name="event_category_mapper_type"><purpose>Mapper type for the event category. </purpose><type><emphasis>unspecified</emphasis></type></typedef>
<typedef name="event_composer_type"><purpose>Event composer type. </purpose><type><emphasis>unspecified</emphasis></type></typedef>
<method-group name="public member functions">
<method name="consume"><type>void</type><parameter name="rec"><paramtype>record_view const &amp;</paramtype><description><para>Log record to consume </para></description></parameter><description><para>The method creates an event in the event log</para><para>
</para></description></method>
<method name="set_event_type_mapper"><type>void</type><parameter name="mapper"><paramtype>event_type_mapper_type const &amp;</paramtype></parameter><description><para>The method installs the function object that maps application severity levels to WinAPI event types </para></description></method>
<method name="set_event_category_mapper"><type>void</type><parameter name="mapper"><paramtype>event_category_mapper_type const &amp;</paramtype></parameter><description><para>The method installs the function object that extracts event category from attribute values </para></description></method>
<method name="set_event_composer"><type>void</type><parameter name="composer"><paramtype>event_composer_type const &amp;</paramtype></parameter><description><para>The method installs the function object that extracts event identifier from the attributes and creates insertion strings that will replace placeholders in the event message. </para></description></method>
</method-group>
<constructor specifiers="explicit"><template>
          <template-type-parameter name="T"/>
        </template><parameter name="message_file_name"><paramtype>std::basic_string&lt; T &gt; const &amp;</paramtype></parameter><description><para>Constructor. Registers event source with name based on the application executable file name in the Application log. If such a registration is already present, it is not overridden. </para></description></constructor>
<constructor specifiers="explicit"><parameter name="message_file_name"><paramtype>filesystem::path const &amp;</paramtype></parameter><description><para>Constructor. Registers event source with name based on the application executable file name in the Application log. If such a registration is already present, it is not overridden. </para></description></constructor>
<constructor specifiers="explicit"><template>
          <template-nontype-parameter name="ArgsT"><type>typename...</type></template-nontype-parameter>
        </template><parameter name="args"><paramtype>ArgsT... const &amp;</paramtype><description><para>A set of named parameters. </para></description></parameter><description><para>Constructor. Registers event log source with the specified parameters. The following named parameters are supported:</para><para><itemizedlist>
<listitem><para><computeroutput>message_file</computeroutput> - Specifies the file name that contains resources that describe events and categories. This parameter is mandatory unless <computeroutput>registration</computeroutput> is <computeroutput>never</computeroutput>. </para>
</listitem>
<listitem><para><computeroutput>target</computeroutput> - Specifies an UNC path to the remote server to which log records should be sent to. The local machine will be used to process log records, if not specified. </para>
</listitem>
<listitem><para><computeroutput>log_name</computeroutput> - Specifies the log in which the source should be registered. The result of <computeroutput>get_default_log_name</computeroutput> is used, if the parameter is not specified. </para>
</listitem>
<listitem><para><computeroutput>log_source</computeroutput> - Specifies the source name. The result of <computeroutput>get_default_source_name</computeroutput> is used, if the parameter is not specified. </para>
</listitem>
<listitem><para><computeroutput>registration</computeroutput> - Specifies the event source registration mode in the Windows registry. Can have values of the <computeroutput>registration_mode</computeroutput> enum. Default value: <computeroutput>on_demand</computeroutput>.</para>
</listitem>
</itemizedlist>

</para></description></constructor>
<destructor><description><para>Destructor. Unregisters event source. The log source description is not removed from the Windows registry. </para></description></destructor>
<method-group name="public static functions">
<method name="get_default_log_name" specifiers="static"><type>string_type</type><description><para>
</para></description><returns><para>Default log name: Application </para>
</returns></method>
<method name="get_default_source_name" specifiers="static"><type>string_type</type><description><para>
</para></description><returns><para>Default log source name that is based on the application executable file name and the sink name </para>
</returns></method>
</method-group>
</class><class name="basic_simple_event_log_backend"><template>
      <template-type-parameter name="CharT"/>
    </template><inherit access="public">basic_formatted_sink_backend&lt; CharT, concurrent_feeding &gt;</inherit><purpose>An implementation of a simple logging sink backend that emits events into Windows NT event log. </purpose><description><para>The sink uses Windows NT 5 (Windows 2000) and later event log API to emit events to an event log. The sink acts as an event source in terms of the API, it implements all needed resources and source registration in the Windows registry that is needed for the event delivery.</para><para>The backend performs message text formatting. The composed text is then passed as the first and only string parameter of the event. The resource embedded into the backend describes the event so that the parameter is inserted into the event description text, thus making it visible in the event log.</para><para>The backend allows to customize mapping of application severity levels to the native Windows event types. This allows to write portable code even if OS-specific sinks, such as this one, are used.</para><para><note><para>Since the backend registers itself into Windows registry as the resource file that contains event description, it is important to keep the library binary in a stable place of the filesystem. Otherwise Windows might not be able to load event resources from the library and display events correctly.</para>
</note>
<note><para>It is known that Windows is not able to find event resources in the application executable, which is linked against the static build of the library. Users are advised to use dynamic builds of the library to solve this problem. </para>
</note>
</para></description><typedef name="char_type"><purpose>Character type. </purpose><type>base_type::char_type</type></typedef>
<typedef name="string_type"><purpose>String type to be used as a message text holder. </purpose><type>base_type::string_type</type></typedef>
<typedef name="event_type_mapper_type"><purpose>Mapper type for the event type. </purpose><type><emphasis>unspecified</emphasis></type></typedef>
<method-group name="public member functions">
<method name="set_event_type_mapper"><type>void</type><parameter name="mapper"><paramtype>event_type_mapper_type const &amp;</paramtype></parameter><description><para>The method installs the function object that maps application severity levels to WinAPI event types </para></description></method>
<method name="consume"><type>void</type><parameter name="rec"><paramtype>record_view const &amp;</paramtype></parameter><parameter name="formatted_message"><paramtype>string_type const &amp;</paramtype></parameter><description><para>The method puts the formatted message to the event log </para></description></method>
</method-group>
<constructor><description><para>Default constructor. Registers event source with name based on the application executable file name in the Application log. If such a registration is already present, it is not overridden. </para></description></constructor>
<constructor specifiers="explicit"><template>
          <template-nontype-parameter name="ArgsT"><type>typename...</type></template-nontype-parameter>
        </template><parameter name="args"><paramtype>ArgsT... const &amp;</paramtype><description><para>A set of named parameters. </para></description></parameter><description><para>Constructor. Registers event log source with the specified parameters. The following named parameters are supported:</para><para><itemizedlist>
<listitem><para><computeroutput>target</computeroutput> - Specifies an UNC path to the remote server which log records should be sent to. The local machine will be used to process log records, if not specified. </para>
</listitem>
<listitem><para><computeroutput>log_name</computeroutput> - Specifies the log in which the source should be registered. The result of <computeroutput>get_default_log_name</computeroutput> is used, if the parameter is not specified. </para>
</listitem>
<listitem><para><computeroutput>log_source</computeroutput> - Specifies the source name. The result of <computeroutput>get_default_source_name</computeroutput> is used, if the parameter is not specified. </para>
</listitem>
<listitem><para><computeroutput>registration</computeroutput> - Specifies the event source registration mode in the Windows registry. Can have values of the <computeroutput>registration_mode</computeroutput> enum. Default value: <computeroutput>on_demand</computeroutput>.</para>
</listitem>
</itemizedlist>

</para></description></constructor>
<destructor><description><para>Destructor. Unregisters event source. The log source description is not removed from the Windows registry. </para></description></destructor>
<method-group name="public static functions">
<method name="get_default_log_name" specifiers="static"><type>string_type</type><description><para>
</para></description><returns><para>Default log name: Application </para>
</returns></method>
<method name="get_default_source_name" specifiers="static"><type>string_type</type><description><para>
</para></description><returns><para>Default log source name that is based on the application executable file name and the sink name </para>
</returns></method>
</method-group>
</class><namespace name="event_log">
<class name="basic_event_composer"><template>
      <template-type-parameter name="CharT"/>
    </template><purpose>An event composer. </purpose><description><para>This class is a function object that extracts event identifier from the attribute values set and formats insertion strings for the particular event. Each insertion string is formatted with a distinct formatter, which can be created just like regular sinks formatters.</para><para>Before using, the composer must be initialized with the following information: <itemizedlist>
<listitem><para>Event identifier extraction logic. One can use <computeroutput>basic_direct_event_id_mapping</computeroutput> or <computeroutput>basic_custom_event_id_mapping</computeroutput> classes in order to create such extractor and pass it to the composer constructor. </para>
</listitem>
<listitem><para>Event identifiers and insertion string formatters. The composer provides the following syntax to provide this information:</para>
</listitem>
</itemizedlist>
<programlisting language="c++">event_composer comp;
comp[MY_EVENT_ID1] % formatter1 % ... % formatterN;
comp[MY_EVENT_ID2] % formatter1 % ... % formatterN;
...
</programlisting></para><para>The event identifiers in square brackets are provided by the message compiler generated header (the actual names are specified in the .mc file). The formatters represent the insertion strings that will be used to replace placeholders in event messages, thus the number and the order of the formatters must correspond to the message definition. </para></description><typedef name="char_type"><purpose>Character type. </purpose><type>CharT</type></typedef>
<typedef name="string_type"><purpose>String type to be used as a message text holder. </purpose><type>std::basic_string&lt; char_type &gt;</type></typedef>
<typedef name="event_id_mapper_type"><purpose>Event identifier mapper type. </purpose><type><emphasis>unspecified</emphasis></type></typedef>
<typedef name="formatter_type"><purpose>Type of an insertion composer (a formatter) </purpose><type>basic_formatter&lt; char_type &gt;</type></typedef>
<typedef name="insertion_list"><purpose>Type of the composed insertions list. </purpose><type>std::vector&lt; string_type &gt;</type></typedef>
<method-group name="public member functions">
<method name="swap"><type>void</type><parameter name="that"><paramtype><classname>basic_event_composer</classname> &amp;</paramtype></parameter><description><para>Swaps <computeroutput>*this</computeroutput> and <computeroutput>that</computeroutput> objects. </para></description></method>
<method name="operator[]"><type>event_map_reference</type><parameter name="id"><paramtype>event_id</paramtype><description><para>Event identifier. </para></description></parameter><description><para>Initiates creation of a new event description. The result of the operator can be used to add formatters for insertion strings construction. The returned reference type is implementation detail.</para><para>
</para></description></method>
<method name="operator[]"><type>event_map_reference</type><parameter name="id"><paramtype>int</paramtype><description><para>Event identifier. </para></description></parameter><description><para>Initiates creation of a new event description. The result of the operator can be used to add formatters for insertion strings construction. The returned reference type is implementation detail.</para><para>
</para></description></method>
<method name="operator()" cv="const"><type>event_id</type><parameter name="rec"><paramtype>record_view const &amp;</paramtype><description><para>Log record view </para></description></parameter><parameter name="insertions"><paramtype>insertion_list &amp;</paramtype><description><para>A sequence of formatted insertion strings </para></description></parameter><description><para>Event composition operator. Extracts an event identifier from the attribute values by calling event ID mapper. Then runs all formatters that were registered for the event with the extracted ID. The results of formatting are returned in the <emphasis>insertions</emphasis> parameter.</para><para>

</para></description><returns><para>An event identifier that was extracted from <computeroutput>attributes</computeroutput> </para>
</returns></method>
</method-group>
<constructor specifiers="explicit"><parameter name="id_mapper"><paramtype>event_id_mapper_type const &amp;</paramtype><description><para>An event identifier mapping function that will be used to extract event ID from attribute values </para></description></parameter><description><para>Default constructor. Creates an empty map of events.</para><para>
</para></description></constructor>
<constructor><parameter name="that"><paramtype><classname>basic_event_composer</classname> const &amp;</paramtype></parameter><description><para>Copy constructor. Performs a deep copy of the object. </para></description></constructor>
<destructor><description><para>Destructor </para></description></destructor>
<copy-assignment><type><classname>basic_event_composer</classname> &amp;</type><parameter name="that"><paramtype><classname>basic_event_composer</classname></paramtype></parameter><description><para>Assignment. Provides strong exception guarantee. </para></description></copy-assignment>
</class><class name="custom_event_category_mapping"><template>
      <template-type-parameter name="AttributeValueT"><default>int</default></template-type-parameter>
    </template><inherit access="public">boost::log::sinks::basic_custom_mapping&lt; event_category, int &gt;</inherit><purpose>Customizable event category mapping. </purpose><description><para>The class allows to setup a custom mapping between an attribute and event categories. The mapping should be initialized similarly to the standard <computeroutput>map</computeroutput> container, by using indexing operator and assignment. </para></description><method-group name="public member functions">
</method-group>
<constructor specifiers="explicit"><parameter name="name"><paramtype>attribute_name const &amp;</paramtype><description><para>Attribute name </para></description></parameter><description><para>Constructor</para><para>
</para></description></constructor>
</class><class name="custom_event_id_mapping"><template>
      <template-type-parameter name="AttributeValueT"><default>int</default></template-type-parameter>
    </template><inherit access="public">boost::log::sinks::basic_custom_mapping&lt; event_id, int &gt;</inherit><purpose>Customizable event ID mapping. </purpose><description><para>The class allows to setup a custom mapping between an attribute and event identifiers. The mapping should be initialized similarly to the standard <computeroutput>map</computeroutput> container, by using indexing operator and assignment. </para></description><method-group name="public member functions">
</method-group>
<constructor specifiers="explicit"><parameter name="name"><paramtype>attribute_name const &amp;</paramtype><description><para>Attribute name </para></description></parameter><description><para>Constructor</para><para>
</para></description></constructor>
</class><class name="custom_event_type_mapping"><template>
      <template-type-parameter name="AttributeValueT"><default>int</default></template-type-parameter>
    </template><inherit access="public">boost::log::sinks::basic_custom_mapping&lt; event_type, int &gt;</inherit><purpose>Customizable event type mapping. </purpose><description><para>The class allows to setup a custom mapping between an attribute and native event types. The mapping should be initialized similarly to the standard <computeroutput>map</computeroutput> container, by using indexing operator and assignment. </para></description><method-group name="public member functions">
</method-group>
<constructor specifiers="explicit"><parameter name="name"><paramtype>attribute_name const &amp;</paramtype><description><para>Attribute name </para></description></parameter><description><para>Constructor</para><para>
</para></description></constructor>
</class><class name="direct_event_category_mapping"><template>
      <template-type-parameter name="AttributeValueT"><default>int</default></template-type-parameter>
    </template><inherit access="public">boost::log::sinks::basic_direct_mapping&lt; event_category, int &gt;</inherit><purpose>Straightforward event category mapping. </purpose><description><para>This type of mapping assumes that attribute with a particular name always provides values that map directly onto the event categories. The mapping simply returns the extracted attribute value converted to the event category. </para></description><method-group name="public member functions">
</method-group>
<constructor specifiers="explicit"><parameter name="name"><paramtype>attribute_name const &amp;</paramtype><description><para>Attribute name </para></description></parameter><description><para>Constructor</para><para>
</para></description></constructor>
</class><class name="direct_event_id_mapping"><template>
      <template-type-parameter name="AttributeValueT"><default>int</default></template-type-parameter>
    </template><inherit access="public">boost::log::sinks::basic_direct_mapping&lt; event_id, int &gt;</inherit><purpose>Straightforward event ID mapping. </purpose><description><para>This type of mapping assumes that attribute with a particular name always provides values that map directly onto the event identifiers. The mapping simply returns the extracted attribute value converted to the event ID. </para></description><method-group name="public member functions">
</method-group>
<constructor specifiers="explicit"><parameter name="name"><paramtype>attribute_name const &amp;</paramtype><description><para>Attribute name </para></description></parameter><description><para>Constructor</para><para>
</para></description></constructor>
</class><class name="direct_event_type_mapping"><template>
      <template-type-parameter name="AttributeValueT"><default>int</default></template-type-parameter>
    </template><inherit access="public">boost::log::sinks::basic_direct_mapping&lt; event_type, int &gt;</inherit><purpose>Straightforward event type mapping. </purpose><description><para>This type of mapping assumes that attribute with a particular name always provides values that map directly onto the native event types. The mapping simply returns the extracted attribute value converted to the native event type. </para></description><method-group name="public member functions">
</method-group>
<constructor specifiers="explicit"><parameter name="name"><paramtype>attribute_name const &amp;</paramtype><description><para>Attribute name </para></description></parameter><description><para>Constructor</para><para>
</para></description></constructor>
</class><enum name="registration_mode"><enumvalue name="never"><purpose>Never register event source, even if it's not registered. </purpose></enumvalue><enumvalue name="on_demand"><purpose>Register if the source is not registered yet. </purpose></enumvalue><enumvalue name="forced"><purpose>Register always, event if the source is already registered. </purpose></enumvalue><purpose>Event log source registration modes. </purpose></enum>
<typedef name="event_composer"><purpose>Convenience typedef for narrow-character logging. </purpose><type><classname>basic_event_composer</classname>&lt; char &gt;</type></typedef>
<typedef name="wevent_composer"><purpose>Convenience typedef for wide-character logging. </purpose><type><classname>basic_event_composer</classname>&lt; wchar_t &gt;</type></typedef>



</namespace>
<typedef name="simple_event_log_backend"><purpose>Convenience typedef for narrow-character logging. </purpose><type><classname>basic_simple_event_log_backend</classname>&lt; char &gt;</type></typedef>
<typedef name="event_log_backend"><purpose>Convenience typedef for narrow-character logging. </purpose><type><classname>basic_event_log_backend</classname>&lt; char &gt;</type></typedef>
<typedef name="wsimple_event_log_backend"><purpose>Convenience typedef for wide-character logging. </purpose><type><classname>basic_simple_event_log_backend</classname>&lt; wchar_t &gt;</type></typedef>
<typedef name="wevent_log_backend"><purpose>Convenience typedef for wide-character logging. </purpose><type><classname>basic_event_log_backend</classname>&lt; wchar_t &gt;</type></typedef>
</namespace>
</namespace>
</namespace>
</header>
<header name="boost/log/sinks/event_log_constants.hpp">
<para><para>Andrey Semashev </para>

<para>07.11.2008</para>

The header contains definition of constants related to Windows NT Event Log API. The constants can be used in other places without the event log backend. </para><namespace name="boost">
<namespace name="log">
<namespace name="sinks">
<namespace name="event_log">
<enum name="event_type"><enumvalue name="success"><default>= 0</default><purpose>Equivalent to EVENTLOG_SUCCESS. </purpose></enumvalue><enumvalue name="info"><default>= 4</default><purpose>Equivalent to EVENTLOG_INFORMATION_TYPE. </purpose></enumvalue><enumvalue name="warning"><default>= 2</default><purpose>Equivalent to EVENTLOG_WARNING_TYPE. </purpose></enumvalue><enumvalue name="error"><default>= 1</default><purpose>Equivalent to EVENTLOG_ERROR_TYPE. </purpose></enumvalue><purpose>Windows event types. </purpose></enum>
<typedef name="event_id"><purpose>A tagged integral type that represents event identifier for the Windows API. </purpose><type><emphasis>unspecified</emphasis></type></typedef>
<typedef name="event_category"><purpose>A tagged integral type that represents event category for the Windows API. </purpose><type><emphasis>unspecified</emphasis></type></typedef>
<function name="make_event_id"><type>event_id</type><parameter name="id"><paramtype>unsigned int</paramtype></parameter><description><para>The function constructs event identifier from an integer </para></description></function>
<function name="make_event_category"><type>event_category</type><parameter name="cat"><paramtype>unsigned short</paramtype></parameter><description><para>The function constructs event category from an integer </para></description></function>
<function name="make_event_type"><type>event_type</type><parameter name="lev"><paramtype>unsigned short</paramtype></parameter><description><para>The function constructs log record level from an integer </para></description></function>
</namespace>
</namespace>
</namespace>
</namespace>
</header>
<header name="boost/log/sinks/frontend_requirements.hpp">
<para><para>Andrey Semashev </para>

<para>22.04.2007</para>

The header contains definition of requirement tags that sink backend may declare with regard to frontends. These requirements ensure that a backend will not be used with an incompatible frontend. </para><namespace name="boost">
<namespace name="log">
<namespace name="sinks">
<struct name="combine_requirements"><template>
      <template-nontype-parameter name="RequirementsT"><type>typename...</type></template-nontype-parameter>
    </template><description><para>The metafunction combines multiple requirement tags into one type. The resulting type will satisfy all specified requirements (i.e. <computeroutput><classname alt="boost::log::sinks::has_requirement">has_requirement</classname></computeroutput> metafunction will return positive result). </para></description></struct><struct name="concurrent_feeding"><inherit access="public">synchronized_feeding</inherit><description><para>The sink backend ensures all needed synchronization, it is capable to handle multithreaded calls </para></description></struct><struct name="flushing"><description><para>The sink backend supports flushing </para></description></struct><struct name="formatted_records"><description><para>The sink backend requires the frontend to perform log record formatting before feeding </para></description></struct><struct name="has_requirement"><template>
      <template-type-parameter name="TestedT"/>
      <template-type-parameter name="RequiredT"/>
    </template><inherit access="public">is_base_of&lt; RequiredT, TestedT &gt;</inherit><description><para>A helper metafunction to check if a requirement is satisfied. The <computeroutput>TestedT</computeroutput> template argument should be the type combining one or several requirements and <computeroutput>RequiredT</computeroutput> is the requirement to test against. The metafunction will yield a positive result if <computeroutput>TestedT</computeroutput> supports <computeroutput>RequiredT</computeroutput>. </para></description></struct><struct name="synchronized_feeding"><description><para>The sink backend expects pre-synchronized calls, all needed synchronization is implemented in the frontend (IOW, only one thread is feeding records to the backend concurrently, but it is possible for several threads to write sequentially). Note that if a frontend supports synchronized record feeding, it will also report capable of concurrent record feeding. </para></description></struct></namespace>
</namespace>
</namespace>
<macro name="BOOST_LOG_COMBINE_REQUIREMENTS_LIMIT"><purpose>The macro specifies the maximum number of requirements that can be combined with the <computeroutput>combine_requirements</computeroutput> metafunction. </purpose></macro>
</header>
<header name="boost/log/sinks/sink.hpp">
<para><para>Andrey Semashev </para>

<para>22.04.2007</para>

The header contains an interface declaration for all sinks. This interface is used by the logging core to feed log records to sinks. </para><namespace name="boost">
<namespace name="log">
<namespace name="sinks">
<class name="sink"><purpose>A base class for a logging sink frontend. </purpose><typedef name="exception_handler_type"><purpose>An exception handler type. </purpose><type><emphasis>unspecified</emphasis></type></typedef>
<method-group name="public member functions">
<method name="will_consume" cv="= 0" specifiers="virtual"><type>bool</type><parameter name="attributes"><paramtype>attribute_value_set const &amp;</paramtype><description><para>A set of attribute values of a logging record </para></description></parameter><description><para>The method returns <computeroutput>true</computeroutput> if no filter is set or the attribute values pass the filter</para><para>
</para></description></method>
<method name="consume" cv="= 0" specifiers="virtual"><type>void</type><parameter name="rec"><paramtype>record_view const &amp;</paramtype><description><para>Logging record to consume </para></description></parameter><description><para>The method puts logging record to the sink</para><para>
</para></description></method>
<method name="try_consume" specifiers="virtual"><type>bool</type><parameter name="rec"><paramtype>record_view const &amp;</paramtype><description><para>Logging record to consume </para></description></parameter><description><para>The method attempts to put logging record to the sink. The method may be used by the core in order to determine the most efficient order of sinks to feed records to in case of heavy contention. Sink implementations may implement try/backoff logic in order to improve overall logging throughput.</para><para>

</para></description><returns><para><computeroutput>true</computeroutput>, if the record was consumed, <computeroutput>false</computeroutput>, if not. </para>
</returns></method>
<method name="flush" cv="= 0" specifiers="virtual"><type>void</type><description><para>The method performs flushing of any internal buffers that may hold log records. The method may take considerable time to complete and may block both the calling thread and threads attempting to put new records into the sink while this call is in progress. </para></description></method>
<method name="is_cross_thread" cv="const noexcept"><type>bool</type><description><para>The method indicates that the sink passes log records between different threads. This information is needed by the logging core to detach log records from all thread-specific resources before passing it to the sink. </para></description></method>
</method-group>
<constructor specifiers="explicit"><parameter name="cross_thread"><paramtype>bool</paramtype></parameter><description><para>Default constructor </para></description></constructor>
<destructor><description><para>Virtual destructor </para></description></destructor>
<constructor cv="= delete"><parameter name=""><paramtype><classname>sink</classname> const &amp;</paramtype></parameter></constructor>
<copy-assignment cv="= delete"><type><classname>sink</classname> &amp;</type><parameter name=""><paramtype><classname>sink</classname> const &amp;</paramtype></parameter></copy-assignment>
</class></namespace>
</namespace>
</namespace>
</header>
<header name="boost/log/sinks/sync_frontend.hpp">
<para><para>Andrey Semashev </para>

<para>14.07.2009</para>

The header contains implementation of synchronous sink frontend. </para><namespace name="boost">
<namespace name="log">
<namespace name="sinks">
<class name="synchronous_sink"><template>
      <template-type-parameter name="SinkBackendT"/>
    </template><inherit access="public">basic_sink_frontend</inherit><purpose>Synchronous logging sink frontend. </purpose><description><para>The sink frontend serializes threads before passing logging records to the backend </para></description><typedef name="sink_backend_type"><purpose>Sink implementation type. </purpose><type>SinkBackendT</type></typedef>
<typedef name="locked_backend_ptr"><purpose>A pointer type that locks the backend until it's destroyed. </purpose><type>implementation_defined</type></typedef>
<method-group name="public member functions">
<method name="locked_backend"><type>locked_backend_ptr</type><description><para>Locking accessor to the attached backend </para></description></method>
<method name="consume" specifiers="virtual"><type>void</type><parameter name="rec"><paramtype>record_view const &amp;</paramtype></parameter><description><para>Passes the log record to the backend </para></description></method>
<method name="try_consume" specifiers="virtual"><type>bool</type><parameter name="rec"><paramtype>record_view const &amp;</paramtype></parameter><description><para>The method attempts to pass logging record to the backend </para></description></method>
<method name="flush" specifiers="virtual"><type>void</type><description><para>The method performs flushing of any internal buffers that may hold log records. The method may take considerable time to complete and may block both the calling thread and threads attempting to put new records into the sink while this call is in progress. </para></description></method>
</method-group>
<constructor><description><para>Default constructor. Constructs the sink backend instance. Requires the backend to be default-constructible. </para></description></constructor>
<constructor specifiers="explicit"><parameter name="backend"><paramtype>shared_ptr&lt; sink_backend_type &gt; const &amp;</paramtype><description><para>Pointer to the backend instance</para></description></parameter><description><para>Constructor attaches user-constructed backend instance</para><para>

</para></description><requires><para><emphasis>backend</emphasis> is not <computeroutput>NULL</computeroutput>. </para>
</requires></constructor>
<constructor specifiers="explicit"><template>
          <template-nontype-parameter name="Args"><type>typename...</type></template-nontype-parameter>
        </template><parameter name="args"><paramtype>Args &amp;&amp;...</paramtype></parameter><description><para>Constructor that passes arbitrary named parameters to the interprocess sink backend constructor. Refer to the backend documentation for the list of supported parameters. </para></description></constructor>
</class></namespace>
</namespace>
</namespace>
</header>
<header name="boost/log/sinks/syslog_backend.hpp">
<para><para>Andrey Semashev </para>

<para>08.01.2008</para>

The header contains implementation of a Syslog sink backend along with its setup facilities. </para><namespace name="boost">
<namespace name="log">
<namespace name="sinks">
<class name="syslog_backend"><inherit access="public">basic_formatted_sink_backend&lt; char &gt;</inherit><purpose>An implementation of a syslog sink backend. </purpose><description><para>The backend provides support for the syslog protocol, defined in RFC3164. The backend sends log records to a remote host via UDP. The host name can be specified by calling the <computeroutput>set_target_address</computeroutput> method. By default log records will be sent to localhost:514. The local address can be specified as well, by calling the <computeroutput>set_local_address</computeroutput> method. By default syslog packets will be sent from any local address available.</para><para>It is safe to create several sink backends with the same local addresses - the backends within the process will share the same socket. The same applies to different processes that use the syslog backends to send records from the same socket. However, it is not guaranteed to work if some third party facility is using the socket.</para><para>On systems with native syslog implementation it may be preferable to utilize the POSIX syslog API instead of direct socket management in order to bypass possible security limitations that may be in action. To do so one has to pass the <computeroutput>use_impl = native</computeroutput> to the backend constructor. Note, however, that in that case you will only have one chance to specify syslog facility and process identification string - on the first native syslog backend construction. Other native syslog backends will ignore these parameters. Obviously, the <computeroutput>set_local_address</computeroutput> and <computeroutput>set_target_address</computeroutput> methods have no effect for native backends. Using <computeroutput>use_impl = native</computeroutput> on platforms with no native support for POSIX syslog API will have no effect. </para></description><typedef name="char_type"><purpose>Character type. </purpose><type>base_type::char_type</type></typedef>
<typedef name="string_type"><purpose>String type that is used to pass message test. </purpose><type>base_type::string_type</type></typedef>
<typedef name="severity_mapper_type"><purpose>Syslog severity level mapper type. </purpose><type><emphasis>unspecified</emphasis></type></typedef>
<method-group name="public member functions">
<method name="set_severity_mapper"><type>void</type><parameter name="mapper"><paramtype>severity_mapper_type const &amp;</paramtype></parameter><description><para>The method installs the function object that maps application severity levels to syslog levels </para></description></method>
<method name="set_local_address"><type>void</type><parameter name="addr"><paramtype>std::string const &amp;</paramtype><description><para>The local address </para></description></parameter><parameter name="port"><paramtype>unsigned short</paramtype><default>514</default><description><para>The local port number </para></description></parameter><description><para>The method sets the local host name which log records will be sent from. The host name is resolved to obtain the final IP address.</para><para><note><para>Does not have effect if the backend was constructed to use native syslog API</para>
</note>

</para></description></method>
<method name="set_local_address"><type>void</type><parameter name="addr"><paramtype>boost::asio::ip::address const &amp;</paramtype><description><para>The local address </para></description></parameter><parameter name="port"><paramtype>unsigned short</paramtype><default>514</default><description><para>The local port number </para></description></parameter><description><para>The method sets the local address which log records will be sent from.</para><para><note><para>Does not have effect if the backend was constructed to use native syslog API</para>
</note>

</para></description></method>
<method name="set_target_address"><type>void</type><parameter name="addr"><paramtype>std::string const &amp;</paramtype><description><para>The remote host address </para></description></parameter><parameter name="port"><paramtype>unsigned short</paramtype><default>514</default><description><para>The port number on the remote host </para></description></parameter><description><para>The method sets the remote host name where log records will be sent to. The host name is resolved to obtain the final IP address.</para><para><note><para>Does not have effect if the backend was constructed to use native syslog API</para>
</note>

</para></description></method>
<method name="set_target_address"><type>void</type><parameter name="addr"><paramtype>boost::asio::ip::address const &amp;</paramtype><description><para>The remote host address </para></description></parameter><parameter name="port"><paramtype>unsigned short</paramtype><default>514</default><description><para>The port number on the remote host </para></description></parameter><description><para>The method sets the address of the remote host where log records will be sent to.</para><para><note><para>Does not have effect if the backend was constructed to use native syslog API</para>
</note>

</para></description></method>
<method name="consume"><type>void</type><parameter name="rec"><paramtype>record_view const &amp;</paramtype></parameter><parameter name="formatted_message"><paramtype>string_type const &amp;</paramtype></parameter><description><para>The method passes the formatted message to the syslog API or sends to a syslog server </para></description></method>
</method-group>
<constructor><description><para>Constructor. Creates a UDP socket-based backend with <computeroutput>syslog::user</computeroutput> facility code. IPv4 protocol will be used. </para></description></constructor>
<constructor specifiers="explicit"><template>
          <template-nontype-parameter name="ArgsT"><type>typename...</type></template-nontype-parameter>
        </template><parameter name="args"><paramtype>ArgsT... const &amp;</paramtype></parameter><description><para>Constructor. Creates a sink backend with the specified named parameters. The following named parameters are supported:</para><para><itemizedlist>
<listitem><para><computeroutput>facility</computeroutput> - Specifies the facility code. If not specified, <computeroutput>syslog::user</computeroutput> will be used. </para>
</listitem>
<listitem><para><computeroutput>use_impl</computeroutput> - Specifies the backend implementation. Can be one of: </para>
</listitem>
<listitem><para><computeroutput>native</computeroutput> - Use the native syslog API, if available. If no native API is available, it is equivalent to <computeroutput>udp_socket_based</computeroutput>. </para>
</listitem>
<listitem><para><computeroutput>udp_socket_based</computeroutput> - Use the UDP socket-based implementation, conforming to RFC3164 protocol specification. This is the default. </para>
</listitem>
<listitem><para><computeroutput>ip_version</computeroutput> - Specifies IP protocol version to use, in case if socket-based implementation is used. Can be either <computeroutput>v4</computeroutput> (the default one) or <computeroutput>v6</computeroutput>. </para>
</listitem>
<listitem><para><computeroutput>ident</computeroutput> - Process identification string. This parameter is only supported by native syslog implementation. </para>
</listitem>
</itemizedlist>
</para></description></constructor>
<destructor><description><para>Destructor </para></description></destructor>
</class><namespace name="syslog">
<class name="custom_severity_mapping"><template>
      <template-type-parameter name="AttributeValueT"><default>int</default></template-type-parameter>
    </template><inherit access="public">boost::log::sinks::basic_custom_mapping&lt; level, int &gt;</inherit><purpose>Customizable severity level mapping. </purpose><description><para>The class allows to setup a custom mapping between an attribute and Syslog severity levels. The mapping should be initialized similarly to the standard <computeroutput>map</computeroutput> container, by using indexing operator and assignment. </para></description><method-group name="public member functions">
</method-group>
<constructor specifiers="explicit"><parameter name="name"><paramtype>attribute_name const &amp;</paramtype><description><para>Attribute name </para></description></parameter><description><para>Constructor</para><para>
</para></description></constructor>
</class><class name="direct_severity_mapping"><template>
      <template-type-parameter name="AttributeValueT"><default>int</default></template-type-parameter>
    </template><inherit access="public">boost::log::sinks::basic_direct_mapping&lt; level, int &gt;</inherit><purpose>Straightforward severity level mapping. </purpose><description><para>This type of mapping assumes that attribute with a particular name always provides values that map directly onto the Syslog levels. The mapping simply returns the extracted attribute value converted to the Syslog severity level. </para></description><method-group name="public member functions">
</method-group>
<constructor specifiers="explicit"><parameter name="name"><paramtype>attribute_name const &amp;</paramtype><description><para>Attribute name </para></description></parameter><description><para>Constructor</para><para>
</para></description></constructor>
</class><enum name="impl_types"><enumvalue name="native"><default>= 0</default><purpose>Use native syslog API. </purpose></enumvalue><enumvalue name="udp_socket_based"><default>= 1</default><purpose>Use UDP sockets, according to RFC3164. </purpose></enumvalue><purpose>The enumeration defined the possible implementation types for the syslog backend. </purpose></enum>


</namespace>
<enum name="ip_versions"><enumvalue name="v4"/><enumvalue name="v6"/><purpose>Supported IP protocol versions. </purpose></enum>
</namespace>
</namespace>
</namespace>
</header>
<header name="boost/log/sinks/syslog_constants.hpp">
<para><para>Andrey Semashev </para>

<para>08.01.2008</para>

The header contains definition of constants related to Syslog API. The constants can be used in other places without the Syslog backend. </para><namespace name="boost">
<namespace name="log">
<namespace name="sinks">
<namespace name="syslog">
<enum name="level"><enumvalue name="emergency"><default>= 0</default><purpose>Equivalent to LOG_EMERG in syslog API. </purpose></enumvalue><enumvalue name="alert"><default>= 1</default><purpose>Equivalent to LOG_ALERT in syslog API. </purpose></enumvalue><enumvalue name="critical"><default>= 2</default><purpose>Equivalent to LOG_CRIT in syslog API. </purpose></enumvalue><enumvalue name="error"><default>= 3</default><purpose>Equivalent to LOG_ERROR in syslog API. </purpose></enumvalue><enumvalue name="warning"><default>= 4</default><purpose>Equivalent to LOG_WARNING in syslog API. </purpose></enumvalue><enumvalue name="notice"><default>= 5</default><purpose>Equivalent to LOG_NOTICE in syslog API. </purpose></enumvalue><enumvalue name="info"><default>= 6</default><purpose>Equivalent to LOG_INFO in syslog API. </purpose></enumvalue><enumvalue name="debug"><default>= 7</default><purpose>Equivalent to LOG_DEBUG in syslog API. </purpose></enumvalue><purpose>Syslog record levels. </purpose></enum>
<enum name="facility"><enumvalue name="kernel"><default>= 0 * 8</default><purpose>Kernel messages. </purpose></enumvalue><enumvalue name="user"><default>= 1 * 8</default><purpose>User-level messages. Equivalent to LOG_USER in syslog API. </purpose></enumvalue><enumvalue name="mail"><default>= 2 * 8</default><purpose>Mail system messages. Equivalent to LOG_MAIL in syslog API. </purpose></enumvalue><enumvalue name="daemon"><default>= 3 * 8</default><purpose>System daemons. Equivalent to LOG_DAEMON in syslog API. </purpose></enumvalue><enumvalue name="security0"><default>= 4 * 8</default><purpose>Security/authorization messages. </purpose></enumvalue><enumvalue name="syslogd"><default>= 5 * 8</default><purpose>Messages from the syslogd daemon. Equivalent to LOG_SYSLOG in syslog API. </purpose></enumvalue><enumvalue name="printer"><default>= 6 * 8</default><purpose>Line printer subsystem. Equivalent to LOG_LPR in syslog API. </purpose></enumvalue><enumvalue name="news"><default>= 7 * 8</default><purpose>Network news subsystem. Equivalent to LOG_NEWS in syslog API. </purpose></enumvalue><enumvalue name="uucp"><default>= 8 * 8</default><purpose>Messages from UUCP subsystem. Equivalent to LOG_UUCP in syslog API. </purpose></enumvalue><enumvalue name="clock0"><default>= 9 * 8</default><purpose>Messages from the clock daemon. </purpose></enumvalue><enumvalue name="security1"><default>= 10 * 8</default><purpose>Security/authorization messages. </purpose></enumvalue><enumvalue name="ftp"><default>= 11 * 8</default><purpose>Messages from FTP daemon. </purpose></enumvalue><enumvalue name="ntp"><default>= 12 * 8</default><purpose>Messages from NTP daemon. </purpose></enumvalue><enumvalue name="log_audit"><default>= 13 * 8</default><purpose>Security/authorization messages. </purpose></enumvalue><enumvalue name="log_alert"><default>= 14 * 8</default><purpose>Security/authorization messages. </purpose></enumvalue><enumvalue name="clock1"><default>= 15 * 8</default><purpose>Messages from the clock daemon. </purpose></enumvalue><enumvalue name="local0"><default>= 16 * 8</default><purpose>For local use. Equivalent to LOG_LOCAL0 in syslog API. </purpose></enumvalue><enumvalue name="local1"><default>= 17 * 8</default><purpose>For local use. Equivalent to LOG_LOCAL1 in syslog API. </purpose></enumvalue><enumvalue name="local2"><default>= 18 * 8</default><purpose>For local use. Equivalent to LOG_LOCAL2 in syslog API. </purpose></enumvalue><enumvalue name="local3"><default>= 19 * 8</default><purpose>For local use. Equivalent to LOG_LOCAL3 in syslog API. </purpose></enumvalue><enumvalue name="local4"><default>= 20 * 8</default><purpose>For local use. Equivalent to LOG_LOCAL4 in syslog API. </purpose></enumvalue><enumvalue name="local5"><default>= 21 * 8</default><purpose>For local use. Equivalent to LOG_LOCAL5 in syslog API. </purpose></enumvalue><enumvalue name="local6"><default>= 22 * 8</default><purpose>For local use. Equivalent to LOG_LOCAL6 in syslog API. </purpose></enumvalue><enumvalue name="local7"><default>= 23 * 8</default><purpose>For local use. Equivalent to LOG_LOCAL7 in syslog API. </purpose></enumvalue><purpose>Syslog facility codes. </purpose></enum>
<function name="make_level"><type>level</type><parameter name="lev"><paramtype>int</paramtype></parameter><description><para>The function constructs log record level from an integer </para></description></function>
<function name="make_facility"><type>facility</type><parameter name="fac"><paramtype>int</paramtype></parameter><description><para>The function constructs log source facility from an integer </para></description></function>
</namespace>
</namespace>
</namespace>
</namespace>
</header>
<header name="boost/log/sinks/text_file_backend.hpp">
<para><para>Andrey Semashev </para>

<para>09.06.2009</para>

The header contains implementation of a text file sink backend. </para><namespace name="boost">
<namespace name="log">
<namespace name="sinks">
<class name="text_file_backend"><inherit access="public">basic_formatted_sink_backend&lt; char, combine_requirements&lt; synchronized_feeding, flushing &gt;::type &gt;</inherit><purpose>An implementation of a text file logging sink backend. </purpose><description><para>The sink backend puts formatted log records to a text file. The sink supports file rotation and advanced file control, such as size and file count restriction. </para></description><typedef name="char_type"><purpose>Character type. </purpose><type>base_type::char_type</type></typedef>
<typedef name="string_type"><purpose>String type to be used as a message text holder. </purpose><type>base_type::string_type</type></typedef>
<typedef name="stream_type"><purpose>Stream type. </purpose><type>std::basic_ostream&lt; char_type &gt;</type></typedef>
<typedef name="open_handler_type"><purpose>File open handler. </purpose><type><emphasis>unspecified</emphasis></type></typedef>
<typedef name="close_handler_type"><purpose>File close handler. </purpose><type><emphasis>unspecified</emphasis></type></typedef>
<typedef name="time_based_rotation_predicate"><purpose>Predicate that defines the time-based condition for file rotation. </purpose><type><emphasis>unspecified</emphasis></type></typedef>
<method-group name="public member functions">
<method name="set_file_name_pattern"><type>void</type><template>
          <template-type-parameter name="PathT"/>
        </template><parameter name="pattern"><paramtype>PathT const &amp;</paramtype><description><para>The name pattern for the file being written. </para></description></parameter><description><para>The method sets the active file name wildcard for the files being written. The wildcard supports date and time injection into the file name.</para><para>
</para></description></method>
<method name="set_target_file_name_pattern"><type>void</type><template>
          <template-type-parameter name="PathT"/>
        </template><parameter name="pattern"><paramtype>PathT const &amp;</paramtype><description><para>The name pattern for the file being rotated. </para></description></parameter><description><para>The method sets the target file name wildcard for the files being rotated. The wildcard supports date and time injection into the file name.</para><para>This pattern will be used when the log file is being rotated, to rename the just written log file (which has the name according to the pattern in the <computeroutput>file_name</computeroutput> constructor parameter or set by a call to <computeroutput>set_file_name_pattern</computeroutput>), just before passing the file to the file collector.</para><para>
</para></description></method>
<method name="set_open_mode"><type>void</type><parameter name="mode"><paramtype>std::ios_base::openmode</paramtype><description><para>File open mode </para></description></parameter><description><para>The method sets the file open mode</para><para>
</para></description></method>
<method name="set_file_collector"><type>void</type><parameter name="collector"><paramtype>shared_ptr&lt; <classname>file::collector</classname> &gt; const &amp;</paramtype><description><para>The file collector function object </para></description></parameter><description><para>The method sets the log file collector function. The function is called on file rotation and is being passed the written file name.</para><para>
</para></description></method>
<method name="set_open_handler"><type>void</type><parameter name="handler"><paramtype>open_handler_type const &amp;</paramtype><description><para>The file open handler function object </para></description></parameter><description><para>The method sets file opening handler. The handler will be called every time the backend opens a new temporary file. The handler may write a header to the opened file in order to maintain file validity.</para><para>
</para></description></method>
<method name="set_close_handler"><type>void</type><parameter name="handler"><paramtype>close_handler_type const &amp;</paramtype><description><para>The file close handler function object </para></description></parameter><description><para>The method sets file closing handler. The handler will be called every time the backend closes a temporary file. The handler may write a footer to the opened file in order to maintain file validity.</para><para>
</para></description></method>
<method name="set_rotation_size"><type>void</type><parameter name="size"><paramtype>uintmax_t</paramtype><description><para>The maximum file size, in characters. </para></description></parameter><description><para>The method sets maximum file size. When the size is reached, file rotation is performed.</para><para><note><para>The size does not count any possible character translations that may happen in the underlying API. This may result in greater actual sizes of the written files.</para>
</note>

</para></description></method>
<method name="set_time_based_rotation"><type>void</type><parameter name="predicate"><paramtype>time_based_rotation_predicate const &amp;</paramtype><description><para>The predicate that defines the time-based condition for file rotation. If empty, no time-based rotation will take place. </para></description></parameter><description><para>The method sets the predicate that defines the time-based condition for file rotation.</para><para><note><para>The rotation always occurs on writing a log record, so the rotation is not strictly bound to the specified condition.</para>
</note>

</para></description></method>
<method name="enable_final_rotation"><type>void</type><parameter name="enable"><paramtype>bool</paramtype><description><para>The flag indicates whether the final rotation should be performed. </para></description></parameter><description><para>The method allows to enable or disable log file rotation on sink destruction.</para><para>By default the sink backend will rotate the log file, if it's been written to, on destruction.</para><para>
</para></description></method>
<method name="auto_flush"><type>void</type><parameter name="enable"><paramtype>bool</paramtype><default>true</default><description><para>The flag indicates whether the automatic buffer flush should be performed. </para></description></parameter><description><para>Sets the flag to automatically flush write buffers of the file being written after each log record.</para><para>
</para></description></method>
<method name="set_auto_newline_mode"><type>void</type><parameter name="mode"><paramtype>auto_newline_mode</paramtype><description><para>The trailing newline insertion mode. </para></description></parameter><description><para>Selects whether a trailing newline should be automatically inserted after every log record. See <computeroutput>auto_newline_mode</computeroutput> description for the possible modes of operation.</para><para>
</para></description></method>
<method name="get_current_file_name" cv="const"><type>filesystem::path</type><description><para>
</para></description><returns><para>The name of the currently open log file. If no file is open, returns an empty path. </para>
</returns></method>
<method name="scan_for_files"><type>uintmax_t</type><parameter name="method"><paramtype>file::scan_method</paramtype><default>file::scan_matching</default><description><para>File scanning method </para></description></parameter><parameter name="update_counter"><paramtype>bool</paramtype><default>true</default><description><para>If <computeroutput>true</computeroutput> and <emphasis>method</emphasis> is <computeroutput>scan_matching</computeroutput>, the method attempts to update the internal file counter according to the found files. The counter is unaffected otherwise. </para></description></parameter><description><para>Performs scanning of the target directory for log files that may have been left from previous runs of the application. The found files are considered by the file collector as if they were rotated.</para><para>The file scan can be performed in two ways: either all files in the target directory will be considered as log files, or only those files that satisfy the target file name pattern. See documentation on <computeroutput>sinks::file::collector::scan_for_files</computeroutput> for more information.</para><para>


<note><para>The method essentially delegates to the same-named function of the file collector. </para>
</note>
</para></description><requires><para>File collector and the proper file name pattern have already been set.</para>
</requires><returns><para>The number of files found.</para>
</returns></method>
<method name="consume"><type>void</type><parameter name="rec"><paramtype>record_view const &amp;</paramtype></parameter><parameter name="formatted_message"><paramtype>string_type const &amp;</paramtype></parameter><description><para>The method writes the message to the sink </para></description></method>
<method name="flush"><type>void</type><description><para>The method flushes the currently open log file </para></description></method>
<method name="rotate_file"><type>void</type><description><para>The method rotates the file </para></description></method>
</method-group>
<constructor><description><para>Default constructor. The constructed sink backend uses default values of all the parameters. </para></description></constructor>
<constructor specifiers="explicit"><template>
          <template-nontype-parameter name="ArgsT"><type>typename...</type></template-nontype-parameter>
        </template><parameter name="args"><paramtype>ArgsT... const &amp;</paramtype></parameter><description><para>Constructor. Creates a sink backend with the specified named parameters. The following named parameters are supported:</para><para><itemizedlist>
<listitem><para><computeroutput>file_name</computeroutput> - Specifies the active file name pattern where logs are actually written to. The pattern may contain directory and file name portions, but only the file name may contain placeholders. The backend supports Boost.DateTime placeholders for injecting current time and date into the file name. Also, an additional N placeholder is supported, it will be replaced with an integral increasing file counter. The placeholder may also contain width specification in the printf-compatible form (e.g. %5N). The printed file counter will always be zero-filled. If <computeroutput>file_name</computeroutput> is not specified, pattern "%5N.log" will be used. </para>
</listitem>
<listitem><para><computeroutput>target_file_name</computeroutput> - Specifies the target file name pattern to use to rename the log file on rotation, before passing it to the file collector. The pattern may contain the same placeholders as the <computeroutput>file_name</computeroutput> parameter. By default, no renaming is done, i.e. the written log file keeps its name according to <computeroutput>file_name</computeroutput>. </para>
</listitem>
<listitem><para><computeroutput>open_mode</computeroutput> - File open mode. The mode should be presented in form of mask compatible to <computeroutput>std::ios_base::openmode</computeroutput>. If not specified, <computeroutput>trunc | out</computeroutput> will be used. </para>
</listitem>
<listitem><para><computeroutput>rotation_size</computeroutput> - Specifies the approximate size, in characters written, of the temporary file upon which the file is passed to the file collector. Note the size does not count any possible character conversions that may take place during writing to the file. If not specified, the file won't be rotated upon reaching any size. </para>
</listitem>
<listitem><para><computeroutput>time_based_rotation</computeroutput> - Specifies the predicate for time-based file rotation. No time-based file rotations will be performed, if not specified. </para>
</listitem>
<listitem><para><computeroutput>enable_final_rotation</computeroutput> - Specifies a flag, whether or not perform log file rotation on sink backend destruction. By default, is <computeroutput>true</computeroutput>. </para>
</listitem>
<listitem><para><computeroutput>auto_flush</computeroutput> - Specifies a flag, whether or not to automatically flush the file after each written log record. By default, is <computeroutput>false</computeroutput>. </para>
</listitem>
<listitem><para><computeroutput>auto_newline_mode</computeroutput> - Specifies automatic trailing newline insertion mode. Must be a value of the <computeroutput>auto_newline_mode</computeroutput> enum. By default, is <computeroutput>auto_newline_mode::insert_if_missing</computeroutput>.</para>
</listitem>
</itemizedlist>
<note><para>Read the caution note regarding file name pattern in the <computeroutput>sinks::file::collector::scan_for_files</computeroutput> documentation. </para>
</note>
</para></description></constructor>
<destructor><description><para>Destructor </para></description></destructor>
</class><namespace name="file">
<struct name="collector"><purpose>Base class for file collectors. </purpose><description><para>All file collectors, supported by file sink backends, should inherit this class. </para></description><method-group name="public member functions">
<method name="store_file" cv="= 0" specifiers="virtual"><type>void</type><parameter name="src_path"><paramtype>filesystem::path const &amp;</paramtype><description><para>The name of the file to be stored </para></description></parameter><description><para>The function stores the specified file in the storage. May lead to an older file deletion and a long file moving.</para><para>
</para></description></method>
<method name="is_in_storage" cv="const = 0" specifiers="virtual"><type>bool</type><parameter name="src_path"><paramtype>filesystem::path const &amp;</paramtype><description><para>The path to be checked </para></description></parameter><description><para>The function checks if the specified path refers to an existing file in the storage.</para><para>
</para></description></method>
<method name="scan_for_files" cv="= 0" specifiers="virtual"><type><classname>scan_result</classname></type><parameter name="method"><paramtype>scan_method</paramtype><description><para>The method of scanning. If <computeroutput>no_scan</computeroutput> is specified, the call has no effect. </para></description></parameter><parameter name="pattern"><paramtype>filesystem::path const &amp;</paramtype><default>filesystem::path()</default><description><para>The file name pattern if <emphasis>method</emphasis> is <computeroutput>scan_matching</computeroutput>. Otherwise the parameter is not used. </para></description></parameter><description><para>Scans the target directory for the files that have already been stored. The found files are added to the collector in order to be tracked and erased, if needed.</para><para>The function may scan the directory in two ways: it will either consider every file in the directory a log file, or will only consider files with names that match the specified pattern. The pattern may contain the following placeholders:</para><para><itemizedlist>
<listitem><para>y, Y, m, d - date components, in Boost.DateTime meaning. </para>
</listitem>
<listitem><para>H, M, S, f - time components, in Boost.DateTime meaning. </para>
</listitem>
<listitem><para>N - numeric file counter. May also contain width specification in printf-compatible form (e.g. %5N). The resulting number will always be zero-filled. </para>
</listitem>
<listitem><para>%% - a percent sign</para>
</listitem>
</itemizedlist>
All other placeholders are not supported.</para><para>

<note><para>In case if <emphasis>method</emphasis> is <computeroutput>scan_matching</computeroutput> the effect of this function is highly dependent on the <emphasis>pattern</emphasis> definition. It is recommended to choose patterns with easily distinguished placeholders (i.e. having delimiters between them). Otherwise either some files can be mistakenly found or not found, which in turn may lead to deletion of an unintended file. </para>
</note>
</para></description><returns><para>The result of filesystem scanning. The last file counter is only populated if <emphasis>method</emphasis> is <computeroutput>scan_matching</computeroutput>, the <emphasis>pattern</emphasis> contains N placeholder, and at least one file matching the pattern is found.</para>
</returns></method>
</method-group>
<constructor cv="= default"><description><para>Default constructor </para></description></constructor>
<destructor><description><para>Virtual destructor </para></description></destructor>
<constructor cv="= delete"><parameter name=""><paramtype><classname>collector</classname> const &amp;</paramtype></parameter></constructor>
<copy-assignment cv="= delete"><type><classname>collector</classname> &amp;</type><parameter name=""><paramtype><classname>collector</classname> const &amp;</paramtype></parameter></copy-assignment>
</struct><class name="rotation_at_time_interval"><description><para>The class represents the time interval of log file rotation. The log file will be rotated after the specified time interval has passed. </para></description><typedef name="result_type"><type>bool</type></typedef>
<method-group name="public member functions">
<method name="operator()" cv="const"><type>bool</type><description><para>Checks if it's time to rotate the file </para></description></method>
</method-group>
<constructor specifiers="explicit"><parameter name="interval"><paramtype>posix_time::time_duration const &amp;</paramtype><description><para>The interval of the rotation, should be no less than 1 second </para></description></parameter><description><para>Creates a rotation time interval of the specified duration</para><para>
</para></description></constructor>
</class><class name="rotation_at_time_point"><description><para>The class represents the time point of log file rotation. One can specify one of three types of time point based rotation:</para><para><itemizedlist>
<listitem><para>rotation takes place every day, at the specified time </para>
</listitem>
<listitem><para>rotation takes place on the specified day of every week, at the specified time </para>
</listitem>
<listitem><para>rotation takes place on the specified day of every month, at the specified time</para>
</listitem>
</itemizedlist>
The time points are considered to be local time. </para></description><typedef name="result_type"><type>bool</type></typedef>
<method-group name="public member functions">
<method name="operator()" cv="const"><type>bool</type><description><para>Checks if it's time to rotate the file </para></description></method>
</method-group>
<constructor specifiers="explicit"><parameter name="hour"><paramtype>unsigned char</paramtype><description><para>The rotation hour, should be within 0 and 23 </para></description></parameter><parameter name="minute"><paramtype>unsigned char</paramtype><description><para>The rotation minute, should be within 0 and 59 </para></description></parameter><parameter name="second"><paramtype>unsigned char</paramtype><description><para>The rotation second, should be within 0 and 59 </para></description></parameter><description><para>Creates a rotation time point of every day at the specified time</para><para>
</para></description></constructor>
<constructor specifiers="explicit"><parameter name="wday"><paramtype>date_time::weekdays</paramtype><description><para>The weekday of the rotation </para></description></parameter><parameter name="hour"><paramtype>unsigned char</paramtype><default>0</default><description><para>The rotation hour, should be within 0 and 23 </para></description></parameter><parameter name="minute"><paramtype>unsigned char</paramtype><default>0</default><description><para>The rotation minute, should be within 0 and 59 </para></description></parameter><parameter name="second"><paramtype>unsigned char</paramtype><default>0</default><description><para>The rotation second, should be within 0 and 59 </para></description></parameter><description><para>Creates a rotation time point of each specified weekday at the specified time</para><para>
</para></description></constructor>
<constructor specifiers="explicit"><parameter name="mday"><paramtype>gregorian::greg_day</paramtype><description><para>The monthday of the rotation, should be within 1 and 31 </para></description></parameter><parameter name="hour"><paramtype>unsigned char</paramtype><default>0</default><description><para>The rotation hour, should be within 0 and 23 </para></description></parameter><parameter name="minute"><paramtype>unsigned char</paramtype><default>0</default><description><para>The rotation minute, should be within 0 and 59 </para></description></parameter><parameter name="second"><paramtype>unsigned char</paramtype><default>0</default><description><para>The rotation second, should be within 0 and 59 </para></description></parameter><description><para>Creates a rotation time point of each specified day of month at the specified time</para><para>
</para></description></constructor>
</class><struct name="scan_result"><purpose>The structure contains filesystem scanning results. </purpose><data-member name="found_count"><type>uintmax_t</type><purpose>The number of found files. </purpose></data-member>
<data-member name="last_file_counter"><type>boost::optional&lt; unsigned int &gt;</type><purpose>If populated, the largest file counter that was used in the found file names. </purpose></data-member>
<method-group name="public member functions">
</method-group>
<constructor cv="noexcept"/>
</struct><enum name="scan_method"><enumvalue name="no_scan"><purpose>Don't scan for stored files. </purpose></enumvalue><enumvalue name="scan_matching"><purpose>Scan for files with names matching the specified mask. </purpose></enumvalue><enumvalue name="scan_all"><purpose>Scan for all files in the directory. </purpose></enumvalue><purpose>The enumeration of the stored files scan methods. </purpose></enum>

<function name="make_collector"><type>shared_ptr&lt; <classname>collector</classname> &gt;</type><template>
          <template-nontype-parameter name="ArgsT"><type>typename...</type></template-nontype-parameter>
        </template><parameter name="args"><paramtype>ArgsT... const &amp;</paramtype></parameter><description><para>The function creates a file collector for the specified target directory. Each target directory is managed by a single file collector, so if this function is called several times for the same directory, it will return a reference to the same file collector. It is safe to use the same collector in different sinks, even in a multithreaded application.</para><para>One can specify certain restrictions for the stored files, such as maximum total size or minimum free space left in the target directory. If any of the specified restrictions is not met, the oldest stored file is deleted. If the same collector is requested more than once with different restrictions, the collector will act according to the most strict combination of all specified restrictions.</para><para>The following named parameters are supported:</para><para><itemizedlist>
<listitem><para><computeroutput>target</computeroutput> - Specifies the target directory for the files being stored in. This parameter is mandatory. </para>
</listitem>
<listitem><para><computeroutput>max_size</computeroutput> - Specifies the maximum total size, in bytes, of stored files that the collector will try not to exceed. If the size exceeds this threshold the oldest file(s) is deleted to free space. Note that the threshold may be exceeded if the size of individual files exceed the <computeroutput>max_size</computeroutput> value. The threshold is not maintained, if not specified. </para>
</listitem>
<listitem><para><computeroutput>min_free_space</computeroutput> - Specifies the minimum free space, in bytes, in the target directory that the collector tries to maintain. If the threshold is exceeded, the oldest file(s) is deleted to free space. The threshold is not maintained, if not specified. </para>
</listitem>
<listitem><para><computeroutput>max_files</computeroutput> - Specifies the maximum number of log files stored. If the number of files exceeds this threshold, the oldest file(s) is deleted to free space. The threshhold is not maintained if not specified.</para>
</listitem>
</itemizedlist>

</para></description><returns><para>The file collector. </para>
</returns></function>
</namespace>
</namespace>
</namespace>
</namespace>
</header>
<header name="boost/log/sinks/text_ipc_message_queue_backend.hpp">
<para><para>Lingxi Li </para>

<para>Andrey Semashev </para>

<para>14.10.2015</para>

The header contains implementation of a text interprocess message queue sink backend along with implementation of a supporting interprocess message queue. </para><namespace name="boost">
<namespace name="log">
<namespace name="sinks">
<class name="text_ipc_message_queue_backend"><template>
      <template-type-parameter name="QueueT"/>
    </template><inherit access="public">basic_formatted_sink_backend&lt; char, concurrent_feeding &gt;</inherit><purpose>An implementation of a text interprocess message queue sink backend and a supporting interprocess message queue. </purpose><description><para>The sink backend sends formatted log messages to an interprocess message queue which can be extracted by a viewer process. Methods of this class are not thread-safe, unless otherwise specified. </para></description><typedef name="char_type"><purpose>Character type. </purpose><type>base_type::char_type</type></typedef>
<typedef name="string_type"><purpose>String type to be used as a message text holder. </purpose><type>base_type::string_type</type></typedef>
<typedef name="queue_type"><purpose>Interprocess message queue type. </purpose><type>QueueT</type></typedef>
<method-group name="public member functions">
<method name="message_queue" cv="noexcept"><type>queue_type &amp;</type><description><para>The method returns a reference to the managed <computeroutput>queue_type</computeroutput> object.</para><para>
</para></description><returns><para>A reference to the managed <computeroutput>queue_type</computeroutput> object. </para>
</returns></method>
<method name="message_queue" cv="const noexcept"><type>queue_type const &amp;</type><description><para>The method returns a constant reference to the managed <computeroutput>queue_type</computeroutput> object.</para><para>
</para></description><returns><para>A constant reference to the managed <computeroutput>queue_type</computeroutput> object. </para>
</returns></method>
<method name="is_open" cv="const noexcept"><type>bool</type><description><para>Tests whether the object is associated with any message queue. Only when the backend has an associated message queue, will any message be sent.</para><para>
</para></description><returns><para><computeroutput>true</computeroutput> if the object is associated with a message queue, and <computeroutput>false</computeroutput> otherwise. </para>
</returns></method>
<method name="consume"><type>void</type><parameter name=""><paramtype>record_view const &amp;</paramtype></parameter><parameter name="formatted_message"><paramtype>string_type const &amp;</paramtype></parameter><description><para>The method writes the message to the backend. Concurrent calls to this method are allowed. Therefore, the backend may be used with unlocked frontend. <computeroutput>stop_local()</computeroutput> can be used to have a blocked <computeroutput>consume()</computeroutput> call return and prevent future calls to <computeroutput>consume()</computeroutput> from blocking. </para></description></method>
</method-group>
<constructor cv="noexcept"><description><para>Default constructor. The method constructs the backend using the default-constructed interprocess message queue. The queue may need additional setup in order to be able to send messages. </para></description></constructor>
<constructor specifiers="explicit" cv="noexcept"><parameter name="queue"><paramtype>queue_type &amp;&amp;</paramtype></parameter><description><para>Initializing constructor. The method constructs the backend using the provided interprocess message queue. The constructor moves from the provided queue. </para></description></constructor>
<constructor specifiers="explicit"><template>
          <template-nontype-parameter name="Args"><type>typename...</type></template-nontype-parameter>
        </template><parameter name="args"><paramtype>Args &amp;&amp;...</paramtype></parameter><description><para>Constructor that passes arbitrary named parameters to the interprocess queue constructor. Refer to the queue documentation for the list of supported parameters. </para></description></constructor>
</class></namespace>
</namespace>
</namespace>
</header>
<header name="boost/log/sinks/text_multifile_backend.hpp">
<para><para>Andrey Semashev </para>

<para>09.06.2009</para>

The header contains implementation of a text multi-file sink backend. </para><namespace name="boost">
<namespace name="log">
<namespace name="sinks">
<class name="text_multifile_backend"><inherit access="public">basic_formatted_sink_backend&lt; char &gt;</inherit><purpose>An implementation of a text multiple files logging sink backend. </purpose><description><para>The sink backend puts formatted log records to one of the text files. The particular file is chosen upon each record's attribute values, which allows to distribute records into individual files or to group records related to some entity or process in a separate file. </para></description><typedef name="char_type"><purpose>Character type. </purpose><type>base_type::char_type</type></typedef>
<typedef name="string_type"><purpose>String type to be used as a message text holder. </purpose><type>base_type::string_type</type></typedef>
<typedef name="file_name_composer_type"><purpose>File name composer functor type. </purpose><type><emphasis>unspecified</emphasis></type></typedef>
<method-group name="public member functions">
<method name="set_file_name_composer"><type>void</type><template>
          <template-type-parameter name="ComposerT"/>
        </template><parameter name="composer"><paramtype>ComposerT const &amp;</paramtype><description><para>File name composer functor </para></description></parameter><description><para>The method sets file name composer functional object. Log record formatters are accepted, too.</para><para>
</para></description></method>
<method name="set_auto_newline_mode"><type>void</type><parameter name="mode"><paramtype>auto_newline_mode</paramtype><description><para>The trailing newline insertion mode. </para></description></parameter><description><para>Selects whether a trailing newline should be automatically inserted after every log record. See <computeroutput>auto_newline_mode</computeroutput> description for the possible modes of operation.</para><para>
</para></description></method>
<method name="consume"><type>void</type><parameter name="rec"><paramtype>record_view const &amp;</paramtype></parameter><parameter name="formatted_message"><paramtype>string_type const &amp;</paramtype></parameter><description><para>The method writes the message to the sink </para></description></method>
</method-group>
<constructor><description><para>Default constructor. The constructed sink backend has no file name composer and thus will not write any files. All other parameters are set to their defaults. </para></description></constructor>
<constructor specifiers="explicit"><template>
          <template-nontype-parameter name="ArgsT"><type>typename...</type></template-nontype-parameter>
        </template><parameter name="args"><paramtype>ArgsT... const &amp;</paramtype></parameter><description><para>Constructor. Creates a sink backend with the specified named parameters. The following named parameters are supported:</para><para><itemizedlist>
<listitem><para><computeroutput>auto_newline_mode</computeroutput> - Specifies automatic trailing newline insertion mode. Must be a value of the <computeroutput>auto_newline_mode</computeroutput> enum. By default, is <computeroutput>auto_newline_mode::insert_if_missing</computeroutput>. </para>
</listitem>
</itemizedlist>
</para></description></constructor>
<destructor><description><para>Destructor </para></description></destructor>
</class><namespace name="file">
<class name="file_name_composer_adapter"><template>
      <template-type-parameter name="FormatterT"/>
    </template><description><para>An adapter class that allows to use regular formatters as file name generators. </para></description><typedef name="result_type"><purpose>Functor result type. </purpose><type>filesystem::path</type></typedef>
<typedef name="native_char_type"><purpose>File name character type. </purpose><type>result_type::string_type::value_type</type></typedef>
<typedef name="formatter_type"><purpose>The adopted formatter type. </purpose><type>FormatterT</type></typedef>
<typedef name="stream_type"><purpose>Formatting stream type. </purpose><type>basic_formatting_ostream&lt; native_char_type &gt;</type></typedef>
<method-group name="public member functions">
<method name="operator()" cv="const"><type>result_type</type><parameter name="rec"><paramtype>record_view const &amp;</paramtype></parameter><description><para>The operator generates a file name based on the log record </para></description></method>
</method-group>
<constructor specifiers="explicit"><parameter name="formatter"><paramtype>formatter_type const &amp;</paramtype></parameter><parameter name="loc"><paramtype>std::locale const &amp;</paramtype><default>std::locale()</default></parameter><description><para>Initializing constructor </para></description></constructor>
<constructor><parameter name="that"><paramtype><classname>file_name_composer_adapter</classname> const &amp;</paramtype></parameter><description><para>Copy constructor </para></description></constructor>
<copy-assignment><type><classname>file_name_composer_adapter</classname> &amp;</type><parameter name="that"><paramtype><classname>file_name_composer_adapter</classname> const &amp;</paramtype></parameter><description><para>Assignment </para></description></copy-assignment>
</class><function name="as_file_name_composer"><type><classname>file_name_composer_adapter</classname>&lt; FormatterT &gt;</type><template>
          <template-type-parameter name="FormatterT"/>
        </template><parameter name="fmt"><paramtype>FormatterT const &amp;</paramtype><description><para>The formatter function object to adopt </para></description></parameter><parameter name="loc"><paramtype>std::locale const &amp;</paramtype><default>std::locale()</default><description><para>The locale to use to character code conversion and formatting </para></description></parameter><description><para>The function adopts a log record formatter into a file name generator</para><para>
</para></description></function>

</namespace>
</namespace>
</namespace>
</namespace>
</header>
<header name="boost/log/sinks/text_ostream_backend.hpp">
<para><para>Andrey Semashev </para>

<para>22.04.2007</para>

The header contains implementation of a text output stream sink backend. </para><namespace name="boost">
<namespace name="log">
<namespace name="sinks">
<class name="basic_text_ostream_backend"><template>
      <template-type-parameter name="CharT"/>
    </template><inherit access="public">basic_formatted_sink_backend&lt; CharT, combine_requirements&lt; synchronized_feeding, flushing &gt;::type &gt;</inherit><purpose>An implementation of a text output stream logging sink backend. </purpose><description><para>The sink backend puts formatted log records to one or more text streams. </para></description><typedef name="char_type"><purpose>Character type. </purpose><type>base_type::char_type</type></typedef>
<typedef name="string_type"><purpose>String type to be used as a message text holder. </purpose><type>base_type::string_type</type></typedef>
<typedef name="stream_type"><purpose>Output stream type. </purpose><type>std::basic_ostream&lt; char_type &gt;</type></typedef>
<method-group name="public member functions">
<method name="add_stream"><type>void</type><parameter name="strm"><paramtype>shared_ptr&lt; stream_type &gt; const &amp;</paramtype><description><para>Pointer to the stream. Must not be NULL. </para></description></parameter><description><para>The method adds a new stream to the sink.</para><para>
</para></description></method>
<method name="remove_stream"><type>void</type><parameter name="strm"><paramtype>shared_ptr&lt; stream_type &gt; const &amp;</paramtype><description><para>Pointer to the stream. Must not be NULL. </para></description></parameter><description><para>The method removes a stream from the sink. If the stream is not attached to the sink, the method has no effect.</para><para>
</para></description></method>
<method name="auto_flush"><type>void</type><parameter name="enable"><paramtype>bool</paramtype><default>true</default><description><para>The flag indicates whether the automatic buffer flush should be performed. </para></description></parameter><description><para>Sets the flag to automatically flush buffers of all attached streams after each log record.</para><para>
</para></description></method>
<method name="set_auto_newline_mode"><type>void</type><parameter name="mode"><paramtype>auto_newline_mode</paramtype><description><para>The trailing newline insertion mode. </para></description></parameter><description><para>Selects whether a trailing newline should be automatically inserted after every log record. See <computeroutput>auto_newline_mode</computeroutput> description for the possible modes of operation.</para><para>
</para></description></method>
<method name="consume"><type>void</type><parameter name="rec"><paramtype>record_view const &amp;</paramtype></parameter><parameter name="formatted_message"><paramtype>string_type const &amp;</paramtype></parameter><description><para>The method writes the message to the sink. </para></description></method>
<method name="flush"><type>void</type><description><para>The method flushes all attached streams. </para></description></method>
</method-group>
<constructor><description><para>Constructor. No streams attached to the constructed backend, auto flush feature disabled. </para></description></constructor>
<constructor specifiers="explicit"><template>
          <template-nontype-parameter name="ArgsT"><type>typename...</type></template-nontype-parameter>
        </template><parameter name="args"><paramtype>ArgsT... const &amp;</paramtype></parameter><description><para>Constructor. Creates a sink backend with the specified named parameters. The following named parameters are supported:</para><para><itemizedlist>
<listitem><para><computeroutput>auto_flush</computeroutput> - Specifies a flag, whether or not to automatically flush the attached streams after each written log record. By default, is <computeroutput>false</computeroutput>. </para>
</listitem>
<listitem><para><computeroutput>auto_newline_mode</computeroutput> - Specifies automatic trailing newline insertion mode. Must be a value of the <computeroutput>auto_newline_mode</computeroutput> enum. By default, is <computeroutput>auto_newline_mode::insert_if_missing</computeroutput>. </para>
</listitem>
</itemizedlist>
</para></description></constructor>
<destructor><description><para>Destructor </para></description></destructor>
</class><typedef name="text_ostream_backend"><purpose>Convenience typedef for narrow-character logging. </purpose><type><classname>basic_text_ostream_backend</classname>&lt; char &gt;</type></typedef>
<typedef name="wtext_ostream_backend"><purpose>Convenience typedef for wide-character logging. </purpose><type><classname>basic_text_ostream_backend</classname>&lt; wchar_t &gt;</type></typedef>
</namespace>
</namespace>
</namespace>
</header>
<header name="boost/log/sinks/unbounded_fifo_queue.hpp">
<para><para>Andrey Semashev </para>

<para>24.07.2011</para>

The header contains implementation of unbounded FIFO queueing strategy for the asynchronous sink frontend. </para><namespace name="boost">
<namespace name="log">
<namespace name="sinks">
<class name="unbounded_fifo_queue"><purpose>Unbounded FIFO log record queueing strategy. </purpose><description><para>The <computeroutput><classname alt="boost::log::sinks::unbounded_fifo_queue">unbounded_fifo_queue</classname></computeroutput> class is intended to be used with the <computeroutput><classname alt="boost::log::sinks::asynchronous_sink">asynchronous_sink</classname></computeroutput> frontend as a log record queueing strategy.</para><para>This strategy implements the simplest logic of log record buffering between threads: the queue has no limits and imposes no ordering over the queued elements aside from the order in which they are enqueued. Because of this the queue provides decent performance and scalability, however if sink backends can't consume log records fast enough the queue may grow uncontrollably. When this is an issue, it is recommended to use one of the bounded strategies. </para></description><method-group name="protected member functions">
<method name="enqueue"><type>void</type><parameter name="rec"><paramtype>record_view const &amp;</paramtype></parameter><purpose>Enqueues log record to the queue. </purpose></method>
<method name="try_enqueue"><type>bool</type><parameter name="rec"><paramtype>record_view const &amp;</paramtype></parameter><purpose>Attempts to enqueue log record to the queue. </purpose></method>
<method name="try_dequeue_ready"><type>bool</type><parameter name="rec"><paramtype>record_view &amp;</paramtype></parameter><purpose>Attempts to dequeue a log record ready for processing from the queue, does not block if the queue is empty. </purpose></method>
<method name="try_dequeue"><type>bool</type><parameter name="rec"><paramtype>record_view &amp;</paramtype></parameter><purpose>Attempts to dequeue log record from the queue, does not block if the queue is empty. </purpose></method>
<method name="dequeue_ready"><type>bool</type><parameter name="rec"><paramtype>record_view &amp;</paramtype></parameter><purpose>Dequeues log record from the queue, blocks if the queue is empty. </purpose></method>
<method name="interrupt_dequeue"><type>void</type><purpose>Wakes a thread possibly blocked in the <computeroutput>dequeue</computeroutput> method. </purpose></method>
</method-group>
<constructor><purpose>Default constructor. </purpose></constructor>
<constructor specifiers="explicit"><template>
          <template-type-parameter name="ArgsT"/>
        </template><parameter name=""><paramtype>ArgsT const &amp;</paramtype></parameter><purpose>Initializing constructor. </purpose></constructor>
</class></namespace>
</namespace>
</namespace>
</header>
<header name="boost/log/sinks/unbounded_ordering_queue.hpp">
<para><para>Andrey Semashev </para>

<para>24.07.2011</para>

The header contains implementation of unbounded ordering record queueing strategy for the asynchronous sink frontend. </para><namespace name="boost">
<namespace name="log">
<namespace name="sinks">
<class name="unbounded_ordering_queue"><template>
      <template-type-parameter name="OrderT"/>
    </template><purpose>Unbounded ordering log record queueing strategy. </purpose><description><para>The <computeroutput><classname alt="boost::log::sinks::unbounded_ordering_queue">unbounded_ordering_queue</classname></computeroutput> class is intended to be used with the <computeroutput><classname alt="boost::log::sinks::asynchronous_sink">asynchronous_sink</classname></computeroutput> frontend as a log record queueing strategy.</para><para>This strategy provides the following properties to the record queueing mechanism:</para><para><itemizedlist>
<listitem><para>The queue has no size limits. </para>
</listitem>
<listitem><para>The queue has a fixed latency window. This means that each log record put into the queue will normally not be dequeued for a certain period of time. </para>
</listitem>
<listitem><para>The queue performs stable record ordering within the latency window. The ordering predicate can be specified in the <computeroutput>OrderT</computeroutput> template parameter.</para>
</listitem>
</itemizedlist>
Since this queue has no size limits, it may grow uncontrollably if sink backends dequeue log records not fast enough. When this is an issue, it is recommended to use one of the bounded strategies. </para></description><method-group name="public member functions">
<method name="get_ordering_window" cv="const"><type>posix_time::time_duration</type><description><para>Returns ordering window size specified during initialization </para></description></method>
</method-group>
<method-group name="public static functions">
<method name="get_default_ordering_window" specifiers="static"><type>posix_time::time_duration</type><description><para>Returns default ordering window size. The default window size is specific to the operating system thread scheduling mechanism. </para></description></method>
</method-group>
<method-group name="protected member functions">
<method name="enqueue"><type>void</type><parameter name="rec"><paramtype>record_view const &amp;</paramtype></parameter><purpose>Enqueues log record to the queue. </purpose></method>
<method name="try_enqueue"><type>bool</type><parameter name="rec"><paramtype>record_view const &amp;</paramtype></parameter><purpose>Attempts to enqueue log record to the queue. </purpose></method>
<method name="try_dequeue_ready"><type>bool</type><parameter name="rec"><paramtype>record_view &amp;</paramtype></parameter><purpose>Attempts to dequeue a log record ready for processing from the queue, does not block if no log records are ready to be processed. </purpose></method>
<method name="try_dequeue"><type>bool</type><parameter name="rec"><paramtype>record_view &amp;</paramtype></parameter><purpose>Attempts to dequeue log record from the queue, does not block. </purpose></method>
<method name="dequeue_ready"><type>bool</type><parameter name="rec"><paramtype>record_view &amp;</paramtype></parameter><purpose>Dequeues log record from the queue, blocks if no log records are ready to be processed. </purpose></method>
<method name="interrupt_dequeue"><type>void</type><purpose>Wakes a thread possibly blocked in the <computeroutput>dequeue</computeroutput> method. </purpose></method>
</method-group>
<constructor specifiers="explicit"><template>
          <template-type-parameter name="ArgsT"/>
        </template><parameter name="args"><paramtype>ArgsT const &amp;</paramtype></parameter><purpose>Initializing constructor. </purpose></constructor>
<method-group name="private member functions">
<method name="enqueue_unlocked"><type>void</type><parameter name="rec"><paramtype>record_view const &amp;</paramtype></parameter><purpose>Enqueues a log record. </purpose></method>
</method-group>
</class></namespace>
</namespace>
</namespace>
</header>
<header name="boost/log/sinks/unlocked_frontend.hpp">
<para><para>Andrey Semashev </para>

<para>14.07.2009</para>

The header contains declaration of an unlocked sink frontend. </para><namespace name="boost">
<namespace name="log">
<namespace name="sinks">
<class name="unlocked_sink"><template>
      <template-type-parameter name="SinkBackendT"/>
    </template><inherit access="public">basic_sink_frontend</inherit><purpose>Non-blocking logging sink frontend. </purpose><description><para>The sink frontend does not perform thread synchronization and simply passes logging records to the sink backend. </para></description><typedef name="sink_backend_type"><purpose>Sink implementation type. </purpose><type>SinkBackendT</type></typedef>
<typedef name="locked_backend_ptr"><purpose>Type of pointer to the backend. </purpose><type>shared_ptr&lt; sink_backend_type &gt;</type></typedef>
<method-group name="public member functions">
<method name="locked_backend"><type>locked_backend_ptr</type><description><para>Locking accessor to the attached backend.</para><para><note><para>Does not do any actual locking, provided only for interface consistency with other frontends. </para>
</note>
</para></description></method>
<method name="consume" specifiers="virtual"><type>void</type><parameter name="rec"><paramtype>record_view const &amp;</paramtype></parameter><description><para>Passes the log record to the backend </para></description></method>
<method name="flush" specifiers="virtual"><type>void</type><description><para>The method performs flushing of any internal buffers that may hold log records. The method may take considerable time to complete and may block both the calling thread and threads attempting to put new records into the sink while this call is in progress. </para></description></method>
</method-group>
<constructor><description><para>Default constructor. Constructs the sink backend instance. Requires the backend to be default-constructible. </para></description></constructor>
<constructor specifiers="explicit"><parameter name="backend"><paramtype>shared_ptr&lt; sink_backend_type &gt; const &amp;</paramtype><description><para>Pointer to the backend instance</para></description></parameter><description><para>Constructor attaches user-constructed backend instance</para><para>

</para></description><requires><para><emphasis>backend</emphasis> is not <computeroutput>NULL</computeroutput>. </para>
</requires></constructor>
<constructor specifiers="explicit"><template>
          <template-nontype-parameter name="Args"><type>typename...</type></template-nontype-parameter>
        </template><parameter name="args"><paramtype>Args &amp;&amp;...</paramtype></parameter><description><para>Constructor that passes arbitrary named parameters to the interprocess sink backend constructor. Refer to the backend documentation for the list of supported parameters. </para></description></constructor>
</class></namespace>
</namespace>
</namespace>
</header>
</library-reference>