etk/namespace_etk__log.html
2014-10-18 09:21:19 +02:00

193 lines
17 KiB
HTML

<!DOCTYPE html>
<html>
<head>
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
<title>etk Library</title>
<link rel="stylesheet" href="base.css">
<link rel="stylesheet" href="menu.css">
</head>
<body>
<div class="navbar navbar-fixed-top">
<div class="container">
<h1><a href="index.html">etk library</a></h1>
<h4><a href="http://github.com/heeroyui/etk/">&nbsp;&nbsp;&nbsp;[ sources ]</a></h4>
<h3>API:</h3> <div id="menu">
<ul class="niveau1">
<li class="sousmenu"><a href="namespace_etk.html">etk</a>
<ul class="niveau2">
<li><a href="namespace_etk__log.html">log</a>
</li>
<li><a href="namespace_etk__color.html">color</a>
</li>
<li><a href="namespace_etk__tool.html">tool</a>
</li>
<li><a href="namespace_etk__archive.html">archive</a>
</li>
<li><a href="namespace_etk__theme.html">theme</a>
</li>
</ul>
</li>
<li><a href="namespace_u32char.html">u32char</a>
</li>
<li><a href="namespace_utf8.html">utf8</a>
</li>
<li><a href="namespace_std.html">std</a>
</li>
</ul>
</div>
<br/><h3>Associate libraries:</h3><div id="menu">
<ul class="niveau1"><li><a href="../ewol/index.html">ewol</a></li>
</ul><ul class="niveau1"><li><a href="../ejson/index.html">ejson</a></li>
</ul><ul class="niveau1"><li><a href="../egami/index.html">egami</a></li>
</ul><ul class="niveau1"><li><a href="../ege/index.html">ege</a></li>
</ul><ul class="niveau1"><li><a href="../esvg/index.html">esvg</a></li>
</ul><ul class="niveau1"><li><a href="../exml/index.html">exml</a></li>
</ul></div>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
</div>
</div>
<div class="container" id="content">
<h1>namespace: etk::log</h1><hr/><h2>Description:</h2>
<br/><br/>
<h2>enum:</h2>
<ul>
<li><a href="enum_etk__log__level.html">level</a></li></ul>
<h2>Synopsis:</h2>
<pre>
<span class="code-type" >int32_t</span> <a class="code-function" href="#5860">registerInstance</a> (<span class="code-storage-keyword">const</span> <a class="code-type" href="http://www.cplusplus.com/reference/string/string/">std::string</a> & <span class="code-argument">_name</span>);<br/> <span class="code-type" >void</span> <a class="code-function" href="#5862">setLevel</a> (<span class="code-storage-keyword">const</span> <a class="code-type" href="http://www.cplusplus.com/reference/string/string/">std::string</a> & <span class="code-argument">_name</span>,<br/> <span class="code-storage-keyword">enum</span> level <span class="code-argument">_level</span>);<br/> <span class="code-type" >void</span> <a class="code-function" href="#5865">setLevel</a> (<span class="code-type" >int32_t</span> <span class="code-argument">_id</span>,<br/> <span class="code-storage-keyword">enum</span> level <span class="code-argument">_level</span>);<br/> <span class="code-type" >void</span> <a class="code-function" href="#5868">setLevel</a> (<span class="code-storage-keyword">enum</span> level <span class="code-argument">_level</span>);<br/> <span class="code-type" >int32_t</span> <a class="code-function" href="#5870">getLevel</a> (<span class="code-type" >int32_t</span> <span class="code-argument">_id</span>);<br/> <a class="code-type" href="http://www.cplusplus.com/reference/vector/vector/">std::vector</a>&lt;std::string&gt; <a class="code-function" href="#5872">getListInstance</a> ();<br/> <span class="code-type" >void</span> <a class="code-function" href="#5873">setColor</a> (<span class="code-type" >bool</span> <span class="code-argument">_status</span>);<br/> <span class="code-type" >void</span> <a class="code-function" href="#5875">setTime</a> (<span class="code-type" >bool</span> <span class="code-argument">_status</span>);<br/> <span class="code-type" >void</span> <a class="code-function" href="#5877">setLine</a> (<span class="code-type" >bool</span> <span class="code-argument">_status</span>);<br/> <span class="code-type" >void</span> <a class="code-function" href="#5879">setFunction</a> (<span class="code-type" >bool</span> <span class="code-argument">_status</span>);<br/> <span class="code-type" >void</span> <a class="code-function" href="#5881">logChar</a> (<span class="code-type" >int32_t</span> <span class="code-argument">_id</span>,<br/> <span class="code-type" >int32_t</span> <span class="code-argument">_level</span>,<br/> <span class="code-type" >int32_t</span> <span class="code-argument">_ligne</span>,<br/> <span class="code-storage-keyword">const</span> <span class="code-type" >char</span>* <span class="code-argument">_className</span>,<br/> <span class="code-storage-keyword">const</span> <span class="code-type" >char</span>* <span class="code-argument">_funcName</span>,<br/> <span class="code-storage-keyword">const</span> <span class="code-type" >char</span>* <span class="code-argument">_log</span>);<br/> <span class="code-type" >void</span> <a class="code-function" href="#5888">logStream</a> (<span class="code-type" >int32_t</span> <span class="code-argument">_id</span>,<br/> <span class="code-type" >int32_t</span> <span class="code-argument">_level</span>,<br/> <span class="code-type" >int32_t</span> <span class="code-argument">_ligne</span>,<br/> <span class="code-storage-keyword">const</span> <span class="code-type" >char</span>* <span class="code-argument">_className</span>,<br/> <span class="code-storage-keyword">const</span> <span class="code-type" >char</span>* <span class="code-argument">_funcName</span>,<br/> <span class="code-storage-keyword">const</span> std::ostream & <span class="code-argument">_log</span>);<br/> <span class="code-type" >void</span> <a class="code-function" href="#5895">logChar1</a> (<span class="code-type" >int32_t</span> <span class="code-argument">_id</span>,<br/> <span class="code-type" >int32_t</span> <span class="code-argument">_level</span>,<br/> <span class="code-storage-keyword">const</span> <span class="code-type" >char</span>* <span class="code-argument">_log</span>);<br/> <span class="code-type" >void</span> <a class="code-function" href="#5899">logStream1</a> (<span class="code-type" >int32_t</span> <span class="code-argument">_id</span>,<br/> <span class="code-type" >int32_t</span> <span class="code-argument">_level</span>,<br/> <span class="code-storage-keyword">const</span> std::ostream & <span class="code-argument">_log</span>);<br/> <span class="code-type" >void</span> <a class="code-function" href="#5903">displayBacktrace</a> (<span class="code-type" >bool</span> <span class="code-argument">_breakAtEnd</span>,<br/> <span class="code-type" >int32_t</span> <span class="code-argument">_removeElement</span>);<br/></pre>
<br/>
<h2>Detail:</h2>
<a id="5860"/><a id="5862"/><h3>registerInstance</h3><pre>
<span class="code-type" >int32_t</span> <span class="code-function">registerInstance</span> (<span class="code-storage-keyword">const</span> <a class="code-type" href="http://www.cplusplus.com/reference/string/string/">std::string</a> & <span class="code-argument">_name</span>);<br/></pre>
Register an element in the log system<br/><ul>
<table class="parameter-list">
<td><b>Parameter [input]:</b></td><td><span class="code-argument">_name</span> </td><td> Name of the module</td></tr>
<tr><td><b>Return: </b></td><td></td><td>reference Id of an instance name</td></tr></table>
</ul>
<br/>
<hr/>
<a id="5865"/><a id="5868"/><h3>setLevel</h3><pre>
<span class="code-type" >void</span> <span class="code-function">setLevel</span> (<span class="code-storage-keyword">const</span> <a class="code-type" href="http://www.cplusplus.com/reference/string/string/">std::string</a> & <span class="code-argument">_name</span>,<br/> <span class="code-storage-keyword">enum</span> level <span class="code-argument">_level</span>);<br/> <span class="code-type" >void</span> <span class="code-function">setLevel</span> (<span class="code-type" >int32_t</span> <span class="code-argument">_id</span>,<br/> <span class="code-storage-keyword">enum</span> level <span class="code-argument">_level</span>);<br/></pre>
Set the log level of a specific instance<br/><ul>
<table class="parameter-list">
<td><b>Parameter [input]:</b></td><td><span class="code-argument">_name</span> </td><td> Name of the intance</td></tr>
<td><b>Parameter [input]:</b></td><td><span class="code-argument">_id</span> </td><td> Id of the intance</td></tr>
<td><b>Parameter [input]:</b></td><td><span class="code-argument">_level</span> </td><td> New level to set on the instance</td></tr>
</table>
</ul>
<br/>
<hr/>
<a id="5870"/><h3>setLevel</h3><pre>
<span class="code-type" >void</span> <span class="code-function">setLevel</span> (<span class="code-storage-keyword">enum</span> level <span class="code-argument">_level</span>);<br/></pre>
Set global debug level<br/><ul>
<table class="parameter-list">
<td><b>Parameter [input]:</b></td><td><span class="code-argument">_level</span> </td><td> New level to set on the instance</td></tr>
</table>
</ul>
<br/>
<hr/>
<a id="5872"/><h3>getLevel</h3><pre>
<span class="code-type" >int32_t</span> <span class="code-function">getLevel</span> (<span class="code-type" >int32_t</span> <span class="code-argument">_id</span>);<br/></pre>
Get the current level of debug for a specific intance<br/><ul>
<table class="parameter-list">
<td><b>Parameter [input]:</b></td><td><span class="code-argument">_id</span> </td><td> Id Of the intance</td></tr>
<tr><td><b>Return: </b></td><td></td><td>the enum casted in an integer ==&gt; generise the API (not dependent of etk)</td></tr></table>
</ul>
<br/>
<hr/>
<a id="5873"/><h3>getListInstance</h3><pre>
<a class="code-type" href="http://www.cplusplus.com/reference/vector/vector/">std::vector</a>&lt;std::string&gt; <span class="code-function">getListInstance</span> ();<br/></pre>
Get list of all intance<br/><ul>
<table class="parameter-list">
<tr><td><b>Return: </b></td><td></td><td>the name list of all intance</td></tr></table>
</ul>
<br/>
<hr/>
<a id="5875"/><h3>setColor</h3><pre>
<span class="code-type" >void</span> <span class="code-function">setColor</span> (<span class="code-type" >bool</span> <span class="code-argument">_status</span>);<br/></pre>
Set Color enable or disable.<br/><ul>
<table class="parameter-list">
<td><b>Parameter [input]:</b></td><td><span class="code-argument">_status</span> </td><td> New value of color.</td></tr>
</table>
</ul>
<br/>
<hr/>
<a id="5877"/><h3>setTime</h3><pre>
<span class="code-type" >void</span> <span class="code-function">setTime</span> (<span class="code-type" >bool</span> <span class="code-argument">_status</span>);<br/></pre>
Set Time display enable or disable.<br/><ul>
<table class="parameter-list">
<td><b>Parameter [input]:</b></td><td><span class="code-argument">_status</span> </td><td> New value.</td></tr>
</table>
</ul>
<br/>
<hr/>
<a id="5879"/><h3>setLine</h3><pre>
<span class="code-type" >void</span> <span class="code-function">setLine</span> (<span class="code-type" >bool</span> <span class="code-argument">_status</span>);<br/></pre>
Set Line display enable or disable.<br/><ul>
<table class="parameter-list">
<td><b>Parameter [input]:</b></td><td><span class="code-argument">_status</span> </td><td> New value.</td></tr>
</table>
</ul>
<br/>
<hr/>
<a id="5881"/><h3>setFunction</h3><pre>
<span class="code-type" >void</span> <span class="code-function">setFunction</span> (<span class="code-type" >bool</span> <span class="code-argument">_status</span>);<br/></pre>
Set Function display enable or disable.<br/><ul>
<table class="parameter-list">
<td><b>Parameter [input]:</b></td><td><span class="code-argument">_status</span> </td><td> New value.</td></tr>
</table>
</ul>
<br/>
<hr/>
<a id="5888"/><a id="5895"/><a id="5899"/><a id="5903"/><h3>logChar</h3><pre>
<span class="code-type" >void</span> <span class="code-function">logChar</span> (<span class="code-type" >int32_t</span> <span class="code-argument">_id</span>,<br/> <span class="code-type" >int32_t</span> <span class="code-argument">_level</span>,<br/> <span class="code-type" >int32_t</span> <span class="code-argument">_ligne</span>,<br/> <span class="code-storage-keyword">const</span> <span class="code-type" >char</span>* <span class="code-argument">_className</span>,<br/> <span class="code-storage-keyword">const</span> <span class="code-type" >char</span>* <span class="code-argument">_funcName</span>,<br/> <span class="code-storage-keyword">const</span> <span class="code-type" >char</span>* <span class="code-argument">_log</span>);<br/> <span class="code-type" >void</span> <span class="code-function">logStream</span> (<span class="code-type" >int32_t</span> <span class="code-argument">_id</span>,<br/> <span class="code-type" >int32_t</span> <span class="code-argument">_level</span>,<br/> <span class="code-type" >int32_t</span> <span class="code-argument">_ligne</span>,<br/> <span class="code-storage-keyword">const</span> <span class="code-type" >char</span>* <span class="code-argument">_className</span>,<br/> <span class="code-storage-keyword">const</span> <span class="code-type" >char</span>* <span class="code-argument">_funcName</span>,<br/> <span class="code-storage-keyword">const</span> std::ostream & <span class="code-argument">_log</span>);<br/> <span class="code-type" >void</span> <span class="code-function">logChar1</span> (<span class="code-type" >int32_t</span> <span class="code-argument">_id</span>,<br/> <span class="code-type" >int32_t</span> <span class="code-argument">_level</span>,<br/> <span class="code-storage-keyword">const</span> <span class="code-type" >char</span>* <span class="code-argument">_log</span>);<br/> <span class="code-type" >void</span> <span class="code-function">logStream1</span> (<span class="code-type" >int32_t</span> <span class="code-argument">_id</span>,<br/> <span class="code-type" >int32_t</span> <span class="code-argument">_level</span>,<br/> <span class="code-storage-keyword">const</span> std::ostream & <span class="code-argument">_log</span>);<br/></pre>
Call log to display<br/><ul>
<table class="parameter-list">
<td><b>Parameter [input]:</b></td><td><span class="code-argument">_id</span> </td><td> Id of the instance type</td></tr>
<td><b>Parameter [input]:</b></td><td><span class="code-argument">_level</span> </td><td> Level debug</td></tr>
<td><b>Parameter [input]:</b></td><td><span class="code-argument">_ligne</span> </td><td> Line of the debug</td></tr>
<td><b>Parameter [input]:</b></td><td><span class="code-argument">_className</span> </td><td> Class name of the debug</td></tr>
<td><b>Parameter [input]:</b></td><td><span class="code-argument">_funcName</span> </td><td> Function name for debug</td></tr>
<td><b>Parameter [input]:</b></td><td><span class="code-argument">_log</span> </td><td> Stream to log</td></tr>
</table>
</ul>
<br/>
<hr/>
<h3>displayBacktrace</h3><pre>
<span class="code-type" >void</span> <span class="code-function">displayBacktrace</span> (<span class="code-type" >bool</span> <span class="code-argument">_breakAtEnd</span>,<br/> <span class="code-type" >int32_t</span> <span class="code-argument">_removeElement</span>);<br/></pre>
Display the current backtrace<br/><ul>
<table class="parameter-list">
<td><b>Parameter [input]:</b></td><td><span class="code-argument">_breakAtEnd</span> </td><td> assert program when backtrace is printed</td></tr>
</table>
</ul>
<br/>
<hr/>
</div>
<script>
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
})(window,document,'script','//www.google-analytics.com/analytics.js','ga');
ga('create', 'UA-46753803-1', 'heeroyui.github.io');
ga('send', 'pageview');
</script>
</body>
</html>