<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/> <meta http-equiv="X-UA-Compatible" content="IE=9"/> <meta name="generator" content="Doxygen 1.8.3.1"/> <title>log4c: layout.h File Reference</title> <link href="tabs.css" rel="stylesheet" type="text/css"/> <script type="text/javascript" src="jquery.js"></script> <script type="text/javascript" src="dynsections.js"></script> <link href="doxygen.css" rel="stylesheet" type="text/css" /> </head> <body> <div id="top"><!-- do not remove this div, it is closed by doxygen! --> <div id="titlearea"> <table cellspacing="0" cellpadding="0"> <tbody> <tr style="height: 56px;"> <td style="padding-left: 0.5em;"> <div id="projectname">log4c  <span id="projectnumber">1.2.4</span> </div> </td> </tr> </tbody> </table> </div> <!-- end header part --> <!-- Generated by Doxygen 1.8.3.1 --> <div id="navrow1" class="tabs"> <ul class="tablist"> <li><a href="index.html"><span>Main Page</span></a></li> <li><a href="pages.html"><span>Related Pages</span></a></li> <li><a href="annotated.html"><span>Data Structures</span></a></li> <li class="current"><a href="files.html"><span>Files</span></a></li> </ul> </div> <div id="navrow2" class="tabs2"> <ul class="tablist"> <li><a href="files.html"><span>File List</span></a></li> <li><a href="globals.html"><span>Globals</span></a></li> </ul> </div> <div id="nav-path" class="navpath"> <ul> <li class="navelem"><a class="el" href="dir_6ba53b81c010ccbbf4e80737d395d27b.html">log4c</a></li> </ul> </div> </div><!-- top --> <div class="header"> <div class="summary"> <a href="#nested-classes">Data Structures</a> | <a href="#define-members">Macros</a> | <a href="#typedef-members">Typedefs</a> | <a href="#func-members">Functions</a> </div> <div class="headertitle"> <div class="title">layout.h File Reference</div> </div> </div><!--header--> <div class="contents"> <p>Interface for user specific layout format of log4c_logging_event events. <a href="#details">More...</a></p> <div class="textblock"><code>#include <log4c/defs.h></code><br/> <code>#include <<a class="el" href="logging__event_8h_source.html">log4c/logging_event.h</a>></code><br/> <code>#include <stdio.h></code><br/> </div><div class="textblock"><div class="dynheader"> Include dependency graph for layout.h:</div> <div class="dyncontent"> <div class="center"><img src="layout_8h__incl.png" border="0" usemap="#layout_8h" alt=""/></div> <map name="layout_8h" id="layout_8h"> <area shape="rect" id="node5" href="logging__event_8h.html" title="the internal representation of logging events." alt="" coords="34,80,181,107"/><area shape="rect" id="node8" href="buffer_8h.html" title="log4c buffer" alt="" coords="202,155,304,181"/><area shape="rect" id="node13" href="location__info_8h.html" title="The internal representation of caller location information." alt="" coords="37,155,178,181"/></map> </div> </div><div class="textblock"><div class="dynheader"> This graph shows which files directly or indirectly include this file:</div> <div class="dyncontent"> <div class="center"><img src="layout_8h__dep__incl.png" border="0" usemap="#layout_8hdep" alt=""/></div> <map name="layout_8hdep" id="layout_8hdep"> <area shape="rect" id="node3" href="appender_8h.html" title="Implement this interface for your own strategies for printing log statements." alt="" coords="326,80,412,107"/><area shape="rect" id="node15" href="layout__type__basic_8h.html" title="Implement a basic layout." alt="" coords="437,80,576,107"/><area shape="rect" id="node17" href="layout__type__basic__r_8h.html" title="Implement a basic_r layout." alt="" coords="600,80,749,107"/><area shape="rect" id="node19" href="layout__type__dated_8h.html" title="Implement a dated layout." alt="" coords="773,80,912,107"/><area shape="rect" id="node21" href="layout__type__dated__local_8h.html" title="Implement a dated layout with local time." alt="" coords="936,80,1109,107"/><area shape="rect" id="node23" href="layout__type__dated__local__r_8h.html" title="Implement a dated layout (reentrant) with local time." alt="" coords="1133,80,1317,107"/><area shape="rect" id="node25" href="layout__type__dated__r_8h.html" title="Implement a dated_r layout." alt="" coords="1342,80,1492,107"/><area shape="rect" id="node27" href="rollingpolicy_8h.html" title="Log4c rolling policy interface. Defines the interface for managing and providing rolling policies..." alt="" coords="1517,80,1619,107"/><area shape="rect" id="node5" href="appender__type__mmap_8h.html" title="Log4c mmap(2) appender interface." alt="" coords="5,163,165,189"/><area shape="rect" id="node7" href="appender__type__rollingfile_8h.html" title="Log4c rolling file appender interface." alt="" coords="987,163,1163,189"/><area shape="rect" id="node9" href="appender__type__stream_8h.html" title="Log4c stream appender interface." alt="" coords="191,163,356,189"/><area shape="rect" id="node11" href="appender__type__stream2_8h.html" title="Log4c stream2 appender interface." alt="" coords="381,163,552,189"/><area shape="rect" id="node13" href="appender__type__syslog_8h.html" title="Log4c syslog(3) appender interface." alt="" coords="577,163,740,189"/><area shape="rect" id="node30" href="rollingpolicy__type__sizewin_8h.html" title="Log4c rolling file size-win interface. Log4c ships with (and defaults to) the classic size-window rol..." alt="" coords="1507,155,1629,197"/></map> </div> </div> <p><a href="layout_8h_source.html">Go to the source code of this file.</a></p> <table class="memberdecls"> <tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="nested-classes"></a> Data Structures</h2></td></tr> <tr class="memitem:"><td class="memItemLeft" align="right" valign="top">struct  </td><td class="memItemRight" valign="bottom"><a class="el" href="structlog4c__layout__type.html">log4c_layout_type</a></td></tr> <tr class="memdesc:"><td class="mdescLeft"> </td><td class="mdescRight">log4c layout type class <a href="structlog4c__layout__type.html#details">More...</a><br/></td></tr> <tr class="separator:"><td class="memSeparator" colspan="2"> </td></tr> </table><table class="memberdecls"> <tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="define-members"></a> Macros</h2></td></tr> <tr class="memitem:ae06bbfb983d6867dbf0a46be67390117"><td class="memItemLeft" align="right" valign="top">#define </td><td class="memItemRight" valign="bottom"><a class="el" href="layout_8h.html#ae06bbfb983d6867dbf0a46be67390117">log4c_layout_type_define</a>(a_type)</td></tr> <tr class="separator:ae06bbfb983d6867dbf0a46be67390117"><td class="memSeparator" colspan="2"> </td></tr> </table><table class="memberdecls"> <tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="typedef-members"></a> Typedefs</h2></td></tr> <tr class="memitem:ad17352f2c995c28cdf08e4aa2f2c2dfc"><td class="memItemLeft" align="right" valign="top">typedef struct __log4c_layout </td><td class="memItemRight" valign="bottom"><a class="el" href="layout_8h.html#ad17352f2c995c28cdf08e4aa2f2c2dfc">log4c_layout_t</a></td></tr> <tr class="separator:ad17352f2c995c28cdf08e4aa2f2c2dfc"><td class="memSeparator" colspan="2"> </td></tr> <tr class="memitem:a431316295240a82b797142ff3f3badb1"><td class="memItemLeft" align="right" valign="top">typedef struct <a class="el" href="structlog4c__layout__type.html">log4c_layout_type</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="layout_8h.html#a431316295240a82b797142ff3f3badb1">log4c_layout_type_t</a></td></tr> <tr class="memdesc:a431316295240a82b797142ff3f3badb1"><td class="mdescLeft"> </td><td class="mdescRight">log4c layout type class <a href="#a431316295240a82b797142ff3f3badb1">More...</a><br/></td></tr> <tr class="separator:a431316295240a82b797142ff3f3badb1"><td class="memSeparator" colspan="2"> </td></tr> </table><table class="memberdecls"> <tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a> Functions</h2></td></tr> <tr class="memitem:a1b6cd4dad73cca4d4a443c1ca43b0826"><td class="memItemLeft" align="right" valign="top">const <a class="el" href="layout_8h.html#a431316295240a82b797142ff3f3badb1">log4c_layout_type_t</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="layout_8h.html#a1b6cd4dad73cca4d4a443c1ca43b0826">log4c_layout_type_get</a> (const char *a_name)</td></tr> <tr class="separator:a1b6cd4dad73cca4d4a443c1ca43b0826"><td class="memSeparator" colspan="2"> </td></tr> <tr class="memitem:ab9e18ff3dd4e4be8f8790fa27add1120"><td class="memItemLeft" align="right" valign="top">const <a class="el" href="layout_8h.html#a431316295240a82b797142ff3f3badb1">log4c_layout_type_t</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="layout_8h.html#ab9e18ff3dd4e4be8f8790fa27add1120">log4c_layout_type_set</a> (const <a class="el" href="layout_8h.html#a431316295240a82b797142ff3f3badb1">log4c_layout_type_t</a> *a_type)</td></tr> <tr class="separator:ab9e18ff3dd4e4be8f8790fa27add1120"><td class="memSeparator" colspan="2"> </td></tr> <tr class="memitem:a99e3a7eada1fdb875f63f09c9acba156"><td class="memItemLeft" align="right" valign="top"><a class="el" href="layout_8h.html#ad17352f2c995c28cdf08e4aa2f2c2dfc">log4c_layout_t</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="layout_8h.html#a99e3a7eada1fdb875f63f09c9acba156">log4c_layout_get</a> (const char *a_name)</td></tr> <tr class="separator:a99e3a7eada1fdb875f63f09c9acba156"><td class="memSeparator" colspan="2"> </td></tr> <tr class="memitem:a614b826a1a1b889fc1beb717c6fa637f"><td class="memItemLeft" align="right" valign="top"><a class="el" href="layout_8h.html#ad17352f2c995c28cdf08e4aa2f2c2dfc">log4c_layout_t</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="layout_8h.html#a614b826a1a1b889fc1beb717c6fa637f">log4c_layout_new</a> (const char *a_name)</td></tr> <tr class="separator:a614b826a1a1b889fc1beb717c6fa637f"><td class="memSeparator" colspan="2"> </td></tr> <tr class="memitem:a917c1171337d4e1c930fd5318424227b"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="layout_8h.html#a917c1171337d4e1c930fd5318424227b">log4c_layout_delete</a> (<a class="el" href="layout_8h.html#ad17352f2c995c28cdf08e4aa2f2c2dfc">log4c_layout_t</a> *a_layout)</td></tr> <tr class="separator:a917c1171337d4e1c930fd5318424227b"><td class="memSeparator" colspan="2"> </td></tr> <tr class="memitem:a2c137e7363dcbdc91a9e62ae37940126"><td class="memItemLeft" align="right" valign="top">const char * </td><td class="memItemRight" valign="bottom"><a class="el" href="layout_8h.html#a2c137e7363dcbdc91a9e62ae37940126">log4c_layout_get_name</a> (const <a class="el" href="layout_8h.html#ad17352f2c995c28cdf08e4aa2f2c2dfc">log4c_layout_t</a> *a_layout)</td></tr> <tr class="separator:a2c137e7363dcbdc91a9e62ae37940126"><td class="memSeparator" colspan="2"> </td></tr> <tr class="memitem:a9cd0a8ac34c1158303311d6375ec0d4d"><td class="memItemLeft" align="right" valign="top">const <a class="el" href="layout_8h.html#a431316295240a82b797142ff3f3badb1">log4c_layout_type_t</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="layout_8h.html#a9cd0a8ac34c1158303311d6375ec0d4d">log4c_layout_get_type</a> (const <a class="el" href="layout_8h.html#ad17352f2c995c28cdf08e4aa2f2c2dfc">log4c_layout_t</a> *a_layout)</td></tr> <tr class="separator:a9cd0a8ac34c1158303311d6375ec0d4d"><td class="memSeparator" colspan="2"> </td></tr> <tr class="memitem:ade855bc9050d79aea242834e64095846"><td class="memItemLeft" align="right" valign="top">const <a class="el" href="layout_8h.html#a431316295240a82b797142ff3f3badb1">log4c_layout_type_t</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="layout_8h.html#ade855bc9050d79aea242834e64095846">log4c_layout_set_type</a> (<a class="el" href="layout_8h.html#ad17352f2c995c28cdf08e4aa2f2c2dfc">log4c_layout_t</a> *a_layout, const <a class="el" href="layout_8h.html#a431316295240a82b797142ff3f3badb1">log4c_layout_type_t</a> *a_type)</td></tr> <tr class="separator:ade855bc9050d79aea242834e64095846"><td class="memSeparator" colspan="2"> </td></tr> <tr class="memitem:a9d0681fd930c2bcfd38a9422d5417c16"><td class="memItemLeft" align="right" valign="top">void * </td><td class="memItemRight" valign="bottom"><a class="el" href="layout_8h.html#a9d0681fd930c2bcfd38a9422d5417c16">log4c_layout_get_udata</a> (const <a class="el" href="layout_8h.html#ad17352f2c995c28cdf08e4aa2f2c2dfc">log4c_layout_t</a> *a_layout)</td></tr> <tr class="separator:a9d0681fd930c2bcfd38a9422d5417c16"><td class="memSeparator" colspan="2"> </td></tr> <tr class="memitem:a74213d547b5b8e5ae64b60a00b3232da"><td class="memItemLeft" align="right" valign="top">void * </td><td class="memItemRight" valign="bottom"><a class="el" href="layout_8h.html#a74213d547b5b8e5ae64b60a00b3232da">log4c_layout_set_udata</a> (<a class="el" href="layout_8h.html#ad17352f2c995c28cdf08e4aa2f2c2dfc">log4c_layout_t</a> *a_layout, void *a_udata)</td></tr> <tr class="separator:a74213d547b5b8e5ae64b60a00b3232da"><td class="memSeparator" colspan="2"> </td></tr> <tr class="memitem:a1e2d6b00e2a13d316873f031309fe86e"><td class="memItemLeft" align="right" valign="top">const char * </td><td class="memItemRight" valign="bottom"><a class="el" href="layout_8h.html#a1e2d6b00e2a13d316873f031309fe86e">log4c_layout_format</a> (const <a class="el" href="layout_8h.html#ad17352f2c995c28cdf08e4aa2f2c2dfc">log4c_layout_t</a> *a_layout, const <a class="el" href="structlog4c__logging__event__t.html">log4c_logging_event_t</a> *a_event)</td></tr> <tr class="separator:a1e2d6b00e2a13d316873f031309fe86e"><td class="memSeparator" colspan="2"> </td></tr> <tr class="memitem:a3d1da9b54a2dd1e19e18e88c71f633da"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="layout_8h.html#a3d1da9b54a2dd1e19e18e88c71f633da">log4c_layout_print</a> (const <a class="el" href="layout_8h.html#ad17352f2c995c28cdf08e4aa2f2c2dfc">log4c_layout_t</a> *a_layout, FILE *a_stream)</td></tr> <tr class="separator:a3d1da9b54a2dd1e19e18e88c71f633da"><td class="memSeparator" colspan="2"> </td></tr> <tr class="memitem:aa0f7fbb537dfeef3ec51c21bca85c621"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="layout_8h.html#aa0f7fbb537dfeef3ec51c21bca85c621">log4c_layout_types_free</a> (void)</td></tr> <tr class="separator:aa0f7fbb537dfeef3ec51c21bca85c621"><td class="memSeparator" colspan="2"> </td></tr> <tr class="memitem:a4195636c5c3149864cefde10776a4d95"><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="layout_8h.html#a4195636c5c3149864cefde10776a4d95">log4c_layout_types_print</a> (FILE *fp)</td></tr> <tr class="separator:a4195636c5c3149864cefde10776a4d95"><td class="memSeparator" colspan="2"> </td></tr> </table> <a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2> <div class="textblock"><p>Interface for user specific layout format of log4c_logging_event events. </p> <dl class="todo"><dt><b><a class="el" href="todo.html#_todo000004">Todo:</a></b></dt><dd>the layout interface needs a better configuration system depending on the layout type. The udata field is a just a trick.</dd></dl> <dl class="todo"><dt><b><a class="el" href="todo.html#_todo000005">Todo:</a></b></dt><dd>a pattern layout would be welcomed !! </dd></dl> </div><h2 class="groupheader">Macro Definition Documentation</h2> <a class="anchor" id="ae06bbfb983d6867dbf0a46be67390117"></a> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">#define log4c_layout_type_define</td> <td>(</td> <td class="paramtype"> </td> <td class="paramname">a_type</td><td>)</td> <td></td> </tr> </table> </div><div class="memdoc"> <p>Helper macro to define static layout types.</p> <dl class="params"><dt>Parameters</dt><dd> <table class="params"> <tr><td class="paramname">a_type</td><td>the log4c_layout_type_t object to define </td></tr> </table> </dd> </dl> <dl class="section warning"><dt>Warning</dt><dd>needs GCC support: otherwise this macro does nothing </dd></dl> <dl class="deprecated"><dt><b><a class="el" href="deprecated.html#_deprecated000002">Deprecated:</a></b></dt><dd>This macro, and the static initialialization of layouts in general, is deprecated. Use rather the <a class="el" href="layout_8h.html#ab9e18ff3dd4e4be8f8790fa27add1120">log4c_layout_type_set()</a> function to initialize your appenders before calling <a class="el" href="init_8h.html#a8eadc94aed53ee4b6ec8d5115f62caf0">log4c_init()</a> </dd></dl> </div> </div> <h2 class="groupheader">Typedef Documentation</h2> <a class="anchor" id="ad17352f2c995c28cdf08e4aa2f2c2dfc"></a> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">typedef struct __log4c_layout <a class="el" href="layout_8h.html#ad17352f2c995c28cdf08e4aa2f2c2dfc">log4c_layout_t</a></td> </tr> </table> </div><div class="memdoc"> <p>log4c layout class </p> </div> </div> <a class="anchor" id="a431316295240a82b797142ff3f3badb1"></a> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">typedef struct <a class="el" href="structlog4c__layout__type.html">log4c_layout_type</a> <a class="el" href="layout_8h.html#a431316295240a82b797142ff3f3badb1">log4c_layout_type_t</a></td> </tr> </table> </div><div class="memdoc"> <p>log4c layout type class </p> <p>Attributes description:</p> <ul> <li><code>name</code> layout type name </li> <li><code>format</code> </li> </ul> </div> </div> <h2 class="groupheader">Function Documentation</h2> <a class="anchor" id="a917c1171337d4e1c930fd5318424227b"></a> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void log4c_layout_delete </td> <td>(</td> <td class="paramtype"><a class="el" href="layout_8h.html#ad17352f2c995c28cdf08e4aa2f2c2dfc">log4c_layout_t</a> * </td> <td class="paramname"><em>a_layout</em></td><td>)</td> <td></td> </tr> </table> </div><div class="memdoc"> <p>Destructor for layout. </p> </div> </div> <a class="anchor" id="a1e2d6b00e2a13d316873f031309fe86e"></a> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">const char* log4c_layout_format </td> <td>(</td> <td class="paramtype">const <a class="el" href="layout_8h.html#ad17352f2c995c28cdf08e4aa2f2c2dfc">log4c_layout_t</a> * </td> <td class="paramname"><em>a_layout</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">const <a class="el" href="structlog4c__logging__event__t.html">log4c_logging_event_t</a> * </td> <td class="paramname"><em>a_event</em> </td> </tr> <tr> <td></td> <td>)</td> <td></td><td></td> </tr> </table> </div><div class="memdoc"> <p>format a log4c_logging_event events to a string.</p> <dl class="params"><dt>Parameters</dt><dd> <table class="params"> <tr><td class="paramname">a_layout</td><td>the log4c_layout_t object </td></tr> <tr><td class="paramname">a_event</td><td>a logging_event_t object </td></tr> </table> </dd> </dl> <dl class="section return"><dt>Returns</dt><dd>an appendable string. </dd></dl> </div> </div> <a class="anchor" id="a99e3a7eada1fdb875f63f09c9acba156"></a> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname"><a class="el" href="layout_8h.html#ad17352f2c995c28cdf08e4aa2f2c2dfc">log4c_layout_t</a>* log4c_layout_get </td> <td>(</td> <td class="paramtype">const char * </td> <td class="paramname"><em>a_name</em></td><td>)</td> <td></td> </tr> </table> </div><div class="memdoc"> <p>Get a pointer to an existing layout.</p> <dl class="params"><dt>Parameters</dt><dd> <table class="params"> <tr><td class="paramname">a_name</td><td>the name of the layout to return. </td></tr> </table> </dd> </dl> <dl class="section return"><dt>Returns</dt><dd>a pointer to an existing layout, or NULL if no layout with the specfied name exists. </dd></dl> </div> </div> <a class="anchor" id="a2c137e7363dcbdc91a9e62ae37940126"></a> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">const char* log4c_layout_get_name </td> <td>(</td> <td class="paramtype">const <a class="el" href="layout_8h.html#ad17352f2c995c28cdf08e4aa2f2c2dfc">log4c_layout_t</a> * </td> <td class="paramname"><em>a_layout</em></td><td>)</td> <td></td> </tr> </table> </div><div class="memdoc"> <dl class="params"><dt>Parameters</dt><dd> <table class="params"> <tr><td class="paramname">a_layout</td><td>the log4c_layout_t object </td></tr> </table> </dd> </dl> <dl class="section return"><dt>Returns</dt><dd>the layout name </dd></dl> </div> </div> <a class="anchor" id="a9cd0a8ac34c1158303311d6375ec0d4d"></a> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">const <a class="el" href="layout_8h.html#a431316295240a82b797142ff3f3badb1">log4c_layout_type_t</a>* log4c_layout_get_type </td> <td>(</td> <td class="paramtype">const <a class="el" href="layout_8h.html#ad17352f2c995c28cdf08e4aa2f2c2dfc">log4c_layout_t</a> * </td> <td class="paramname"><em>a_layout</em></td><td>)</td> <td></td> </tr> </table> </div><div class="memdoc"> <dl class="params"><dt>Parameters</dt><dd> <table class="params"> <tr><td class="paramname">a_layout</td><td>the log4c_layout_t object </td></tr> </table> </dd> </dl> <dl class="section return"><dt>Returns</dt><dd>a log4c_layout_type_t object </dd></dl> </div> </div> <a class="anchor" id="a9d0681fd930c2bcfd38a9422d5417c16"></a> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void* log4c_layout_get_udata </td> <td>(</td> <td class="paramtype">const <a class="el" href="layout_8h.html#ad17352f2c995c28cdf08e4aa2f2c2dfc">log4c_layout_t</a> * </td> <td class="paramname"><em>a_layout</em></td><td>)</td> <td></td> </tr> </table> </div><div class="memdoc"> <dl class="params"><dt>Parameters</dt><dd> <table class="params"> <tr><td class="paramname">a_layout</td><td>the log4c_layout_t object </td></tr> </table> </dd> </dl> <dl class="section return"><dt>Returns</dt><dd>the layout user data </dd></dl> </div> </div> <a class="anchor" id="a614b826a1a1b889fc1beb717c6fa637f"></a> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname"><a class="el" href="layout_8h.html#ad17352f2c995c28cdf08e4aa2f2c2dfc">log4c_layout_t</a>* log4c_layout_new </td> <td>(</td> <td class="paramtype">const char * </td> <td class="paramname"><em>a_name</em></td><td>)</td> <td></td> </tr> </table> </div><div class="memdoc"> <p>Constructor for layout. </p> </div> </div> <a class="anchor" id="a3d1da9b54a2dd1e19e18e88c71f633da"></a> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void log4c_layout_print </td> <td>(</td> <td class="paramtype">const <a class="el" href="layout_8h.html#ad17352f2c995c28cdf08e4aa2f2c2dfc">log4c_layout_t</a> * </td> <td class="paramname"><em>a_layout</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">FILE * </td> <td class="paramname"><em>a_stream</em> </td> </tr> <tr> <td></td> <td>)</td> <td></td><td></td> </tr> </table> </div><div class="memdoc"> <p>prints the layout on a stream </p> <dl class="params"><dt>Parameters</dt><dd> <table class="params"> <tr><td class="paramname">a_layout</td><td>the log4c_layout_t object </td></tr> <tr><td class="paramname">a_stream</td><td>the stream </td></tr> </table> </dd> </dl> </div> </div> <a class="anchor" id="ade855bc9050d79aea242834e64095846"></a> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">const <a class="el" href="layout_8h.html#a431316295240a82b797142ff3f3badb1">log4c_layout_type_t</a>* log4c_layout_set_type </td> <td>(</td> <td class="paramtype"><a class="el" href="layout_8h.html#ad17352f2c995c28cdf08e4aa2f2c2dfc">log4c_layout_t</a> * </td> <td class="paramname"><em>a_layout</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">const <a class="el" href="layout_8h.html#a431316295240a82b797142ff3f3badb1">log4c_layout_type_t</a> * </td> <td class="paramname"><em>a_type</em> </td> </tr> <tr> <td></td> <td>)</td> <td></td><td></td> </tr> </table> </div><div class="memdoc"> <p>sets the layout type</p> <dl class="params"><dt>Parameters</dt><dd> <table class="params"> <tr><td class="paramname">a_layout</td><td>the log4c_layout_t object </td></tr> <tr><td class="paramname">a_type</td><td>the new layout type </td></tr> </table> </dd> </dl> <dl class="section return"><dt>Returns</dt><dd>the previous layout type </dd></dl> </div> </div> <a class="anchor" id="a74213d547b5b8e5ae64b60a00b3232da"></a> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void* log4c_layout_set_udata </td> <td>(</td> <td class="paramtype"><a class="el" href="layout_8h.html#ad17352f2c995c28cdf08e4aa2f2c2dfc">log4c_layout_t</a> * </td> <td class="paramname"><em>a_layout</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">void * </td> <td class="paramname"><em>a_udata</em> </td> </tr> <tr> <td></td> <td>)</td> <td></td><td></td> </tr> </table> </div><div class="memdoc"> <p>sets the layout user data</p> <dl class="params"><dt>Parameters</dt><dd> <table class="params"> <tr><td class="paramname">a_layout</td><td>the log4c_layout_t object </td></tr> <tr><td class="paramname">a_udata</td><td>the new layout user data </td></tr> </table> </dd> </dl> <dl class="section return"><dt>Returns</dt><dd>the previous layout user data </dd></dl> </div> </div> <a class="anchor" id="a1b6cd4dad73cca4d4a443c1ca43b0826"></a> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">const <a class="el" href="layout_8h.html#a431316295240a82b797142ff3f3badb1">log4c_layout_type_t</a>* log4c_layout_type_get </td> <td>(</td> <td class="paramtype">const char * </td> <td class="paramname"><em>a_name</em></td><td>)</td> <td></td> </tr> </table> </div><div class="memdoc"> <p>Get a pointer to an existing layout type.</p> <dl class="params"><dt>Parameters</dt><dd> <table class="params"> <tr><td class="paramname">a_name</td><td>the name of the layout type to return. </td></tr> </table> </dd> </dl> <dl class="section return"><dt>Returns</dt><dd>a pointer to an existing layout type, or NULL if no layout type with the specified name exists. </dd></dl> </div> </div> <a class="anchor" id="ab9e18ff3dd4e4be8f8790fa27add1120"></a> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">const <a class="el" href="layout_8h.html#a431316295240a82b797142ff3f3badb1">log4c_layout_type_t</a>* log4c_layout_type_set </td> <td>(</td> <td class="paramtype">const <a class="el" href="layout_8h.html#a431316295240a82b797142ff3f3badb1">log4c_layout_type_t</a> * </td> <td class="paramname"><em>a_type</em></td><td>)</td> <td></td> </tr> </table> </div><div class="memdoc"> <p>Use this function to register a layout type with log4c. Once this is done you may refer to this type by name both programatically and in the log4c configuration file.</p> <dl class="params"><dt>Parameters</dt><dd> <table class="params"> <tr><td class="paramname">a_type</td><td>a pointer to the new layout type to set. </td></tr> </table> </dd> </dl> <dl class="section return"><dt>Returns</dt><dd>a pointer to the previous layout type of same name.</dd></dl> <p>Example code fragment: </p> <div class="fragment"><div class="line"><span class="keyword">const</span> <a class="code" href="structlog4c__layout__type.html" title="log4c layout type class">log4c_layout_type_t</a> log4c_layout_type_xml = {</div> <div class="line"> <span class="stringliteral">"s13_xml"</span>,</div> <div class="line"> xml_format,</div> <div class="line">};</div> <div class="line"> </div> <div class="line">log4c_layout_type_set(&log4c_layout_type_xml);</div> </div><!-- fragment --> </div> </div> <a class="anchor" id="aa0f7fbb537dfeef3ec51c21bca85c621"></a> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void log4c_layout_types_free </td> <td>(</td> <td class="paramtype">void </td> <td class="paramname"></td><td>)</td> <td></td> </tr> </table> </div><div class="memdoc"> <p>free all layout types </p> </div> </div> <a class="anchor" id="a4195636c5c3149864cefde10776a4d95"></a> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void log4c_layout_types_print </td> <td>(</td> <td class="paramtype">FILE * </td> <td class="paramname"><em>fp</em></td><td>)</td> <td></td> </tr> </table> </div><div class="memdoc"> <p>prints all the current registered layout types on a stream</p> <dl class="params"><dt>Parameters</dt><dd> <table class="params"> <tr><td class="paramname">fp</td><td>the stream </td></tr> </table> </dd> </dl> </div> </div> </div><!-- contents --> <!-- start footer part --> <hr class="footer"/><address class="footer"><small> Generated by  <a href="http://www.doxygen.org/index.html"> <img class="footer" src="doxygen.png" alt="doxygen"/> </a> 1.8.3.1 </small></address> </body> </html>